Guide
terminal-radio supports macOS and Linux; Windows works through WSL. It requires Python 3.12 or later and mpv, which plays the audio.
Installation
The quickest route installs uv and radio, then tells you how to install mpv when it is missing:
curl -LsSf https://raw.githubusercontent.com/yueswater/terminal-radio/main/install.sh | sh |
Or install mpv first and choose a Python tool manager yourself:
# macOS |
Run radio to open the terminal interface.
Updating
Radio checks for a new release at most once a day. Installs managed by uv tool or pipx can update from the interface, or you can run:
uv tool upgrade radiotui-tw |
Set RADIO_CHECK_FOR_UPDATES=0 to disable update checks entirely.
Start listening
radio # open the terminal interface |
When the interface is already open, commands from another terminal control that same player instead of starting a second audio stream.
Keyboard controls
| Key | Action |
|---|---|
← → |
Change tabs |
↑ ↓ j k |
Move the cursor |
enter |
Play or apply the selected item |
space |
Pause or resume |
s |
Stop playback |
f |
Add or remove a favourite |
+ - |
Change volume |
m |
Mute or unmute |
t |
Switch theme |
w |
Switch English and Traditional Chinese |
/ |
Search stations |
e i |
Export or import settings |
? |
Open the complete shortcut guide |
q |
Fade out and quit |
Find a station
The interface, CLI and HTTP API share one query language:
radio stations "genre:news region:taipei" |
Filters are genre:, region:, lang:, network: and band:. Different fields narrow results; repeating one field widens them. Plain text searches frequencies, names and descriptions.
Interface features
- Favourites persist between launches; press
fon a station. - History and statistics track listening, pauses and interruptions, then chart stations, times and a 14-day trend.
- Track log keeps titles announced by stations that publish programme metadata.
- Backup streams move through a station’s fallback addresses if its primary stream fails.
- Sleep timer supports 15, 30, 60 or any custom duration from 1–1440 minutes.
- Station checks distinguish online, slow and offline streams.
- Themes and languages switch with
tandw, or from Settings. - Custom stations add, edit or delete your own HTTP or HTTPS streams from Settings.
Export and import
Press e to export a .radio.config file and i to import one. It carries favourites, volume, mute, theme, language, autoplay, reconnect, station checks, animations and custom stations. It does not overwrite listening history.
HTTP API
radio api |
The service defaults to http://127.0.0.1:8000; interactive API documentation is at http://127.0.0.1:8000/docs. Player state, station search, playback, volume, mute and sleep timers all have endpoints.
Uninstall
uv tool uninstall radiotui-tw |
See the GitHub README for every environment variable, configuration format and contributor workflow.