A modern, minimalist Spotify module for MagicMirror² that displays your currently playing music with smooth animations and extensive customization options.
Modern Design
- Multiple display modes (minimalist, detailed, compact, cover-only)
- Smooth progress bar animations
- Dynamic color extraction from album art
- Glass morphism and blur effects
Highly Customizable
- 4 built-in themes (dark, light, auto, glass)
- Custom accent colors
- Adjustable font sizes and text lengths
- Progress bar customization
Advanced Features
- Real-time playback controls (requires Spotify Premium)
- Touch/gesture support
- Low power mode for better performance
- Album art caching
- Automatic token refresh
- Static DOM updates for better performance
Security First
- Compliant with Spotify's latest security requirements
- Uses secure redirect URIs (127.0.0.1)
- Automatic token management
- No third-party services required
| Minimalist | Detailed | Compact | Cover Only |
|---|---|---|---|
![]() |
![]() |
![]() |
![]() |
- MagicMirror² version 2.15.0 or higher
- Node.js version 14.0.0 or higher
- Spotify account (free or premium)
- Spotify App credentials
cd ~/MagicMirror/modules
git clone https://github.com/rxf-sys/MMM-POSpotify.git
cd MMM-POSpotifynpm install- Go to Spotify Developer Dashboard
- Click "Create an App"
- Fill in the app details:
- App Name: MagicMirror Spotify
- App Description: Spotify module for MagicMirror
- After creation, note your Client ID and Client Secret
- Click "Edit Settings" and add the redirect URI:
http://127.0.0.1:8100/callback - Save the settings
cd ~/MagicMirror/modules/MMM-POSpotify
node auth-server.js YOUR_CLIENT_ID YOUR_CLIENT_SECRETThen open your browser and go to http://127.0.0.1:8100
- Add the module to your config with just the Client ID and Secret
- Start MagicMirror
- Open
http://127.0.0.1:8100in your browser - Click "Connect with Spotify" and authorize
Add the following to your ~/MagicMirror/config/config.js:
{
module: "MMM-POSpotify",
position: "top_right",
config: {
clientID: "YOUR_CLIENT_ID",
clientSecret: "YOUR_CLIENT_SECRET",
accessToken: "YOUR_ACCESS_TOKEN", // From authorization
refreshToken: "YOUR_REFRESH_TOKEN", // From authorization
displayType: "minimalist", // minimalist, detailed, compact, coverOnly
showAlbumArt: true,
albumArtSize: 200,
showProgressBar: true,
theme: "dark" // dark, light, glass, auto
}
}| Option | Description | Type | Default |
|---|---|---|---|
clientID |
Required - Your Spotify App Client ID | string |
"" |
clientSecret |
Required - Your Spotify App Client Secret | string |
"" |
accessToken |
Required - Access token from authorization | string |
"" |
refreshToken |
Required - Refresh token from authorization | string |
"" |
| Display Options | |||
displayType |
Display style: minimalist, detailed, compact, coverOnly |
string |
"minimalist" |
updateInterval |
API update interval in milliseconds | number |
5000 |
animationSpeed |
Animation speed in milliseconds | number |
500 |
showAlbumArt |
Show album cover art | boolean |
true |
albumArtSize |
Album art size in pixels | number |
200 |
showProgressBar |
Show playback progress bar | boolean |
true |
progressBarHeight |
Progress bar height in pixels | number |
3 |
showDeviceIcon |
Show playback device icon | boolean |
true |
showSpotifyLogo |
Show Spotify logo when not playing | boolean |
true |
logoSize |
Spotify logo size in pixels | number |
30 |
| Theming | |||
theme |
Theme style: dark, light, glass, auto |
string |
"dark" |
accentColor |
Custom accent color (hex) | string |
"#1DB954" |
useAlbumColors |
Extract colors from album art | boolean |
false |
backgroundBlur |
Apply blur effect to background | boolean |
true |
| Text Options | |||
showArtistFirst |
Show artist name before song title | boolean |
false |
maxTitleLength |
Maximum title length before truncation | number |
30 |
maxArtistLength |
Maximum artist length before truncation | number |
25 |
scrollLongText |
Enable scrolling for long text | boolean |
true |
fontSize |
Font size: small, medium, large |
string |
"medium" |
| Advanced Features | |||
showPlaybackControls |
Show play/pause/skip buttons (Premium required) | boolean |
false |
enableNotifications |
Send notifications to other modules | boolean |
true |
enableGestures |
Enable touch gesture support | boolean |
false |
fadeWhenInactive |
Fade module when music stops | boolean |
true |
inactivityTimeout |
Time before fading in milliseconds | number |
30000 |
| Performance | |||
lowPowerMode |
Reduce update frequency | boolean |
false |
cacheAlbumArt |
Cache album covers | boolean |
true |
Clean layout with album art, title, artist, and progress bar side by side.
Vertical layout with larger album art, full album information, time display, and optional playback controls.
Single-line horizontal layout ideal for small spaces.
Full album art with overlay text, perfect for a visual focus.
The module sends the following notifications when enableNotifications is true:
| Notification | Payload | Description |
|---|---|---|
SPOTIFY_UPDATE |
{title, artist, album, albumArt, progress, duration, isPlaying, device} |
Current playback information |
The module responds to these notifications:
| Notification | Payload | Description |
|---|---|---|
SPOTIFY_PLAY |
none | Resume playback |
SPOTIFY_PAUSE |
none | Pause playback |
SPOTIFY_NEXT |
none | Skip to next track |
SPOTIFY_PREVIOUS |
none | Skip to previous track |
SPOTIFY_VOLUME_UP |
number (optional) |
Increase volume |
SPOTIFY_VOLUME_DOWN |
number (optional) |
Decrease volume |
- Ensure Spotify is actively playing on a device
- Check that your tokens are valid by visiting
http://127.0.0.1:8100/status - Verify your Spotify app has the correct redirect URI
- Delete
.spotify-tokens.jsonin the module directory - Re-run the authorization process
- Make sure both
accessTokenANDrefreshTokenare in your config
- Ensure you're using the latest version of the module
- Check that
updateIntervalis not set too high (5000ms recommended) - Verify your system has sufficient resources
Check the MagicMirror logs:
pm2 logs MagicMirrorTo update the module to the latest version:
cd ~/MagicMirror/modules/MMM-POSpotify
git pull
npm installContributions are welcome! Please feel free to submit a Pull Request.
- Fork the repository
- Create your feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add some AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
- MagicMirror² by Michael Teeuw
- Spotify Web API
- spotify-web-api-node
- GitHub: @rxf-sys




