A tiny macOS menu bar app that controls Spotify from a small floating panel — album art, track/artist info, and play/pause/skip buttons. Unlike a normal menu bar dropdown, the panel does not close when you click elsewhere on screen; it stays open until you close it yourself with the × button or click the menu bar icon again.
- macOS 13 or later
- Xcode Command Line Tools (
xcode-select --install) - The [Spotify desktop app] installed and running
cd SpotifyMenuBar
swift build.build/debug/SpotifyMenuBar &A music note icon appears in your menu bar. On first launch, macOS will ask for permission to let the app control Spotify via Automation/AppleScript — click OK. If you miss the prompt or deny it, re-enable it manually at System Settings → Privacy & Security → Automation → SpotifyMenuBar → Spotify.
To stop the app:
pkill -f SpotifyMenuBar-
Click the menu bar icon to open/close the panel. It appears pinned to the top-left of your screen.
-
The panel shows the currently playing track's artwork, title, and artist, with previous/play-pause/next controls.
-
Playback state updates automatically via Spotify's
PlaybackStateChangednotification, so the panel stays in sync even if you skip tracks from Spotify itself.
The app uses AppleScript (NSAppleScript) to send playpause, next track, and
previous track commands to the Spotify app, and to read the current track's name, artist, and
artwork URL. No Spotify account login, API key, or network access to Spotify's servers is
required — it only talks to the local Spotify app.
- This is a debug build run directly from the terminal — it does not launch automatically at
login. If you want that, it would need to be packaged as a proper
.appbundle and added to Login Items. - Built with Swift Package Manager + AppKit/SwiftUI, no external dependencies.
Built by sirJeremyer with Claude Code.