Skip to content
waveplatePublic

About

spotifm is a personal web radio streamer powered by your spotify library

Topics

Resources

Stars

65 stars

Watchers

4 watching

Forks

Repository files navigation

spotifm (3.3.2)

spotifm

spotifm is a personal web radio streamer powered by your spotify library

tldr? check out the demo

Live Demo

Note

a spotify premium subscription is required to use spotifm

features

  • standalone web radio
    • no longer requiring co-deployment with icecast and ices
  • flexible audio pipeline
    • user-definable gstreamer pipelines for encoding, muxing, audio processing, buffering, and output behaviour
  • timed lyrics
    • retrieves timed lyrics from spotify when possible, with LRCLIB as fallback
  • rest and websocket apis
    • playback control, search, playlist management, lyrics, telemetry, authorization & scopes
  • cool web player
    • aesthetically pleasing web player with milkdrop visualizer + realistic NTSC & VHS webgl shaders, live telemetry, song search and playback control. highly configurable
  • reference player
  • bots

quick start

1) install spotifm

one-liner

Note

curl -fsSL https://raw.githubusercontent.com/waveplate/spotifm/v3.3.2/install.sh | bash -s -- --version 3.3.2

this will install:

  • /usr/local/bin/spotifm (static musl binary)
  • $XDG_DATA_HOME/spotifm/player or /usr/local/share/spotifm/player (web player files)

once installed, start with

spotifm

other options

docker
docker run -d \
  -p 3333:3333 \
  -p 3443:3443 \
  -v ${HOME}/.local/share/spotifm:/root/.local/share/spotifm \
  --name spotifm \
  waveplate/spotifm:3.3.2

or with docker-compose:

git clone https://github.com/waveplate/spotifm
cd spotifm
SPOTIFM_IMAGE=waveplate/spotifm:3.3.2 docker compose up -d spotifm
run without docker

see the build guide, then start with

./target/release/spotifm

2) visit /oauth endpoint

visit the /oauth endpoint, e.g., http://127.0.0.1:3333/oauth

this endpoint will automatically redirect you to spotify's oauth authorization portal and generally guide you through the authorization process

3) listen to some music

Important

the web player uses a service worker and an audio worklet to play and inspect the audio stream so that lyrics and visualizations remain synchronized

browsers restrict these features to secure contexts: HTTPS, or HTTP on a loopback address such as 127.0.0.1. this is why spotifm starts an HTTPS listener in addition to HTTP

in addition to this, certain capabilities like autoplaying audio (without explicit interaction from the user) requires HTTPS regardless of whether it's running locally or not

tl;dr: just use HTTPS

using the web player

using the /listen endpoint

play a track


documentation


About

spotifm is a personal web radio streamer powered by your spotify library

Topics

Resources

Stars

65 stars

Watchers

4 watching

Forks

Releases

Packages

Used by

Contributors

Languages