Rafael Cavalcanti

Linux enthusiast and human being.

github email
The motivation for PiFi Radio
Aug 10, 2018
4 minutes read

PiFi Radio is a MPD web client focused on playing radio streamings. As I recently open sourced it, I’ll try to explain what made me write it.

The need

I started this project in early 2017. At that time, I wanted to setup a Raspberry Pi for my parents to listen to internet radio and control it with ease.

That Pi also served other purposes, so installing an audio dedicated distro, such as Volumio, wasn’t an option. I installed MPD on top of Raspbian and looked for a client. I needed:

  • A straight-forward user interface that wouldn’t confuse them. Few taps to the desired actions and little room to mistakes.
  • It should, at least, present a list of stations from which to pick, and allow to control the volume and stop the current playback.
  • The administrator should have the ability to set a list of streams and make it available to all users.
  • The client should be usable at least from iOS and Android phones, but ideally everywhere.
  • It should be in their native language.

What I found at that time was the following.

Available MPD clients at the time

There were many great MPD clients available on Android, desktop and web. The “forgotten” platform was iOS, for which there was only one (paid) app on the AppStore. Not a big of an issue, as I could still set up a web client for those devices.

However, I couldn’t find any client that treated radios with care. The majority of them privileged the music library, with streaming as a hacky, second class citizen (as you’ll see PiFi is the opposite).

On the next paragraphs, I’ll talk about the user experience I had testing them.

The user experience for radio listening

How do we listen to radio on most clients? Well, to have a list of radio streams you usually have to create a playlist on the server and add the stations to it.

Some desktop clients have lists fetched from web services such as Soma FM, TuneIn, Shoutcast, etc. However, to save a radio as a bookmark you still have to add it to a playlist. The exception are some desktop apps that have some sort of local bookmarks. This didn’t do it for me because: a) I wanted a single list for all users; b) desktop wasn’t the priority.

So, we are back to playlists. To choose a radio, the user has to find this playlist on the app and then tap the desired streaming. This had many problems for me.

First of all, equating a list of radios to a playlist can be confusing to some users. Also, it has some unexpected behaviours. For example, if the user selects a station with a broken URL, MPD will start to play the next radio. So the user is confused: he asked for one station, but other one is playing. He will probably tap again and won’t understand why this continues to happen.

Other problem is that you usually can’t set a friendly name to the stream. The playlist is presented to the user as a series of URLs or some badly formatted info that the station broadcasted. That info can be the radio name (hopefully), but more often than not it is a song that was previously playing.

So, when choosing the radio playlist, the user is presented to a list consisting of (possibly giant and frightening) URLs, random song names and, when he is lucky, badly formatted station names. The same lack of clarity happens when the user open the app to check what station is currently playing.

I also didn’t like that the playlists are editable by the users. This makes sense for song playlists, but for radios, I don’t expect them to mess with streaming URLs. I wanted editing to be reserved to the backend, avoiding possible problems.

One more issue is that, being those clients focused on the library, someone who browses them just to play radio finds the interface far from straight-forward, actually rather confusing.

Moreover, many MPD clients are packed with features related to the music library. The result is tons of options that radio listeners don’t care about, distracting and filling the screen.

This could be very frustrating to those users, specially because the same clients lack some basic behaviours that you expect from a radio app. My parents would have to memorize steps just to play a station. Not good.

Finally, few of the clients were translated to the language I needed. This could be remediable, but at this point it didn’t matter anymore.


The bottom line is that, while there are tons of great MPD clients, you won’t have a nice experience if you use them to what are not designed. Most of them are focused on the music library, and I couldn’t find any who took streaming very seriously.

It was then obvious to me that I should create my own solution to my problem. I decided to code a simple web app and called it PiFi Radio. You can see how it went on my Github.

Back to posts

comments powered by Disqus