– Listening to Radio the Easy Way

Update: 0.5 is available. is a little script that makes it very easy to listen to radio under Linux (and maybe other OSs too) with mplayer. All you need to do is to call with the name of the station you want to listen to. For example: Radio Paradise
or BBC3
To read more about go to the first post discussing

What’s New

Here are some of the things that have changed in compared to the previous release (0.3). On the usability side, I’ve dropped the need to put quotation marks around station names containing spaces. So while in previous version of to listen for “Radio Tel Aviv” you had to run "Radio Tel Aviv"
In the new version you can just call Radio Tel Aviv
This doesn’t seem a big change but it makes it a lot easier to listen to radio stations with spaces in their names, and listening to radio in a user-friendly way is what is all about.

Another great feature is the ability to add new stations to on a specific user basis or in a system-wide basis via configuration files. looks for /etc/radiopy.conf and ~/.radiopy and parse them for new stations or for overriding existing stations. The system-wide /etc/radiopy.conf/ overrides the default settings in itself, and ~/.radiopy can override the system-wide configuration. The syntax for adding new station is

[station name]
home: station homepage
stream: station's stream location

So if one wants for example to add the BBC3 radio station (although it already in the known station list) one would add the following snippet to ~/.radiopy (or to /etc/radiopy.conf if one wants to add it system-wide):


The credit for the idea to use configuration file and the basic implementation of parsing them using the ConfigParser module goes to Fernando Rendón.

In addition to the above, I’ve added 24 new radio stations including all of RadioIO stations, Beethoven (classic music), Radio Paradise and Onda Cero (some Spanish radio).

A full list of changes between versions is included the the file CHANGES inside the tar archive.


You can download from here.


The installation process remained the same. Just download the tar archive., extract it and copy to somewhere in your PATH, e.g. to /usr/bin or /usr/local/bin. From the command line you can run the following commands from the directory in which you saved the tar archive in order to install the script:

tar -zxvf radiopy-0.4.tar.gz
cd radiopy
cp /usr/bin/

Bugs and Suggestions

If you find a bug in the script please leave a comment bellow. If you have any suggestion or a radio station you would like me to add to the default station list, comment bellow, preferably add the station’s stream url.

9 thoughts on “ – Listening to Radio the Easy Way”

  1. Ran, You’re the best.
    I’ve learned python, and I wanted to write a script like this. But you’re ahead of me.
    This is just great.


  2. Hi.. how to use this program? sorry im new for this language…

    is it can run in windows?

    what i should i do to run it? copy downloaded files to python???

    please help me….

  3. Everything works fine except when I add stations to /etc/radiopy.conf.

    The new stations don’t show up when I do a –list

    And they don’t play. They seem to detect the location and stream but hang (until the next song) at the ICY Info line

    Here is an example of one two I added:


    [Folk Alley]

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.