Spotify MCP Server
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Spotify MCP Serverplay some relaxing jazz"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Spotify MCP Server
An MCP (Model Context Protocol) server that connects Claude to Spotify. It exposes 21 tools that let Claude control playback, manage playlists, fetch lyrics, and recommend music - all through natural language.
Blog post: https://samit.bearblog.dev/mcp-servers/ Video demo: https://youtu.be/BExl8jhthoE
How it works
MCP is a protocol that lets AI assistants call external tools. This server registers Spotify actions as MCP tools, so when you ask Claude Desktop something like "play some chill music," it can directly call the Spotify API on your behalf.
You (natural language) -> Claude Desktop -> MCP Server -> Spotify APIRelated MCP server: Spotify MCP Server
Prerequisites
Python 3.13+
uv (package manager)
A Spotify Developer account with a registered app
A Genius API key (for lyrics)
Setup
1. Clone and install dependencies
git clone https://github.com/yourusername/spotify-mcp.git
cd spotify-mcp
uv sync2. Configure environment variables
cp .env.example .envEdit .env with your credentials:
SPOTIFY_CLIENT_IDandSPOTIFY_CLIENT_SECRETfrom your Spotify Developer DashboardSPOTIFY_REDIRECT_URI- your redirect URI (use ngrok since Spotify doesn't support localhost)GENIUS_API_KEYfrom the Genius API
3. Set up the redirect URI
Spotify doesn't support localhost as a redirect URI. Use ngrok to tunnel:
ngrok http 3000Copy the ngrok URL and add it as a redirect URI in your Spotify Developer Dashboard app settings. Set it as SPOTIFY_REDIRECT_URI in your .env.
4. Configure Claude Desktop
Open Claude Desktop settings and edit claude_desktop_config.json:
{
"mcpServers": {
"spotify": {
"command": "<path-to-uv>",
"args": [
"--directory",
"<path-to-spotify-mcp>",
"run",
"server.py"
],
"env": {
"SPOTIFY_CLIENT_ID": "your_client_id",
"SPOTIFY_CLIENT_SECRET": "your_client_secret",
"SPOTIFY_REDIRECT_URI": "your_redirect_uri",
"GENIUS_API_KEY": "your_genius_api_key"
}
}
}
}Replace <path-to-uv> with the output of which uv and <path-to-spotify-mcp> with the project directory.
5. Start the server
uv run server.pyRestart Claude Desktop. You should see the Spotify MCP tools available.
Features
Playback Controls
Play, pause, skip tracks
Shuffle and repeat modes
Play a full album by name
Queue songs by name
Playlist Management
Create playlists by genre, mood, or custom song list
Add songs to existing playlists by name
Delete playlists by name
List all playlists with links
Fetch playlist contents
Lyrics and Info
Get lyrics for any song (via Genius API)
Get lyrics for the currently playing song
Show current track metadata
Discovery
Recommend songs based on listening history
List recently played artists
Find albums by artist
List liked songs
Development
# Run tests
uv run pytest
# Lint
uv run ruff check .
# Format
uv run ruff format .License
MIT
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Latest Blog Posts
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/samitmohan/spotify-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server