# Autostart web radio after stopped airplay

**URL:** <https://discourse.mopidy.com/t/autostart-web-radio-after-stopped-airplay/153>\
**Category:** Pi MusicBox (archive)\
**Created:** [September 4, 2014, 9:22am UTC](https://discourse.mopidy.com/t/autostart-web-radio-after-stopped-airplay/153 "2014-09-04T09:22:28Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![martinsch](https://avatars.discourse-cdn.com/v4/letter/m/e95f7d/32.png) [@martinsch](https://discourse.mopidy.com/u/martinsch)\
**Post date:** [September 4, 2014, 9:22am UTC](https://discourse.mopidy.com/t/autostart-web-radio-after-stopped-airplay/153/1 "2014-09-04T09:22:28Z")

</div>

Hi,

I was wondering if there is a way to automatically start web radio after stopped airplay playback?

---

<div class="post-metadata">

**Author:** ![kingosticks](https://avatars.discourse-cdn.com/v4/letter/k/858c86/32.png) [@kingosticks](https://discourse.mopidy.com/u/kingosticks)\
**Post date:** [September 4, 2014, 2:18pm UTC](https://discourse.mopidy.com/t/autostart-web-radio-after-stopped-airplay/153/2 "2014-09-04T14:18:48Z")

</div>

I’ve never used the airplay feature but shairport accepts `-E, --on-stop` arguments that ‘run a shell command when playback ends’. Perhaps you could set this (in `etc/init.d/shairport`) to something like “mpc add [http://my/stream.mp3;](http://my/stream.mp3;) mpc play” ? Hopefully shairport only fires this shell command when playback actually stops, rather than between every song, else you might end up with choppy audio. Good luck.

---

<div class="post-metadata">

**Author:** ![Roy\_Maihoefer](https://avatars.discourse-cdn.com/v4/letter/r/7ab992/32.png) [@Roy\_Maihoefer](https://discourse.mopidy.com/u/Roy_Maihoefer)\
**Post date:** [July 24, 2015, 12:02pm UTC](https://discourse.mopidy.com/t/autostart-web-radio-after-stopped-airplay/153/3 "2015-07-24T12:02:34Z")

</div>

Hi, this point is why I moved to Volumio, it does restart the last source which played before AirPlay after quitting AirPlay. This was very important for me. i wonder, why this little feature was not implemented into PI MusicBox, which I would have actually preferred to Volumio.

---

<div class="post-metadata">

**Author:** ![jodal](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.mopidy.com/jodal/32/2564_2.png) [@jodal](https://discourse.mopidy.com/u/jodal)\
**Post date:** [February 19, 2026, 11:47am UTC](https://discourse.mopidy.com/t/autostart-web-radio-after-stopped-airplay/153/4 "2026-02-19T11:47:40Z")

</div>


