spotify-mcp

by @varunneal

Spotify MCP Server

Control Spotify playback, queue tracks, search catalogs, and build or update playlists directly from Claude Desktop or Cursor over local `stdio`. Written in Python on top of `spotipy` (`varunneal/spotify-mcp`), it authenticates via a Spotify Developer OAuth app and runs through `uv` or `uvx`.

Design & Creative615pythonMIT

Server facts

spotify-mcp

GitHub stars

615

Last commit

Mar 11, 2026

Runtime

python

License

MIT

Project

Author
varunneal
License
MIT

Tech

Runtime
python
Transports
stdio
Remote access
No
Authentication
Spotify Developer OAuth (SPOTIFY_CLIENT_ID, SPOTIFY_CLIENT_SECRET, SPOTIFY_REDIRECT_URI)

Activity

GitHub stars
615
Last commit
Data as of

Tags

  • llm integration
  • music assistant
  • spotify

Overview

Music listeners looking to connect `spotify mcp` with Claude Desktop or Cursor can bridge natural-language prompts to the Spotify Web API using `varunneal/spotify-mcp`, an MIT-licensed Python server built on `spotipy`. Once linked over local `stdio`, AI assistants can start, pause, or skip playback, search tracks, albums, artists, and playlists, inspect metadata, manipulate the active queue, and create or update playlists. Setup requires a Spotify Premium account and a registered app on `developer.spotify.com` configured with an explicit loopback HTTP redirect URI such as `http://127.0.0.1:8080/callback`, supplying `SPOTIFY_CLIENT_ID`, `SPOTIFY_CLIENT_SECRET`, and `SPOTIFY_REDIRECT_URI` inside your client's `mcpServers` block.

The repository documents ephemeral `uvx` execution directly from GitHub on Python 3.12, as well as cloning the project locally and starting it through `uv` (`>=0.54`). Because ephemeral `uvx` launches re-open the Spotify OAuth redirect URI on every tool invocation, cloning locally and pointing `uv --directory` at your checkout is strongly preferred for daily listening. Keep important caveats in mind before adopting it: the README carries a March 2026 notice marking the repository as inactive (most pull requests will not be merged), and Spotify previously deprecated several recommendation API endpoints, leaving playback, search, queue, and playlist operations as the core feature set.

Install & configure

Requirements

  • Spotify Premium subscription (required by Spotify's developer playback API)
  • Spotify Developer app (`SPOTIFY_CLIENT_ID`, `SPOTIFY_CLIENT_SECRET`) with an HTTP loopback `SPOTIFY_REDIRECT_URI` (e.g., `http://127.0.0.1:8080/callback`)
  • Python 3.12 and `uv` (`>=0.54`) installed locally
Documented launch / install command
git clone https://github.com/varunneal/spotify-mcp.git

Add `spotify-mcp` to `claude_desktop_config.json` or Cursor MCP config via `uvx --python 3.12 --from git+https://github.com/varunneal/spotify-mcp spotify-mcp` for quick testing, or clone locally (`git clone https://github.com/varunneal/spotify-mcp.git`) and run `uv --directory /path/to/spotify-mcp run spotify-mcp` to prevent repeated browser OAuth prompts. Debug with `npx @modelcontextprotocol/inspector`.

Config file · macOS: ~/Library/Application Support/Claude/claude_desktop_config.json

Windows: %APPDATA%\Claude\claude_desktop_config.json

Use Settings → Developer → Edit Config when available. Do not assume a Linux configuration path; check the client documentation for your platform. Remote servers use the app’s connector flow when supported, not the local stdio file shown here. Merge this example with existing settings; do not overwrite unrelated servers.

Claude Desktop configuration
{
  "mcpServers": {
    "spotify": {
      "command": "uvx",
      "args": [
        "--python",
        "3.12",
        "--from",
        "git+https://github.com/varunneal/spotify-mcp",
        "spotify-mcp"
      ],
      "env": {
        "SPOTIFY_CLIENT_ID": "YOUR_CLIENT_ID",
        "SPOTIFY_CLIENT_SECRET": "YOUR_CLIENT_SECRET",
        "SPOTIFY_REDIRECT_URI": "http://127.0.0.1:8080/callback"
      }
    }
  }
}

Read the Claude Desktop setup guide

Config file · Project: .cursor/mcp.json

User: ~/.cursor/mcp.json

The project path is relative to the workspace root. The tilde denotes your user home directory. Use Cursor’s MCP settings to confirm which configuration and scope your installed version is reading. Merge this example with existing settings; do not overwrite unrelated servers.

Cursor configuration
{
  "mcpServers": {
    "spotify": {
      "command": "uvx",
      "args": [
        "--python",
        "3.12",
        "--from",
        "git+https://github.com/varunneal/spotify-mcp",
        "spotify-mcp"
      ],
      "env": {
        "SPOTIFY_CLIENT_ID": "YOUR_CLIENT_ID",
        "SPOTIFY_CLIENT_SECRET": "YOUR_CLIENT_SECRET",
        "SPOTIFY_REDIRECT_URI": "http://127.0.0.1:8080/callback"
      }
    }
  }
}

Read the Cursor setup guide

Config file · Workspace: .vscode/mcp.json

For user scope, use the “MCP: Open User Configuration” command if available. Do not guess a user configuration path across operating systems, profiles, containers, or remote workspaces; check the client documentation. Merge this example with existing settings; do not overwrite unrelated servers.

VS Code configuration
{
  "servers": {
    "spotify": {
      "type": "stdio",
      "command": "uvx",
      "args": [
        "--python",
        "3.12",
        "--from",
        "git+https://github.com/varunneal/spotify-mcp",
        "spotify-mcp"
      ],
      "env": {
        "SPOTIFY_CLIENT_ID": "YOUR_CLIENT_ID",
        "SPOTIFY_CLIENT_SECRET": "YOUR_CLIENT_SECRET",
        "SPOTIFY_REDIRECT_URI": "http://127.0.0.1:8080/callback"
      }
    }
  }
}

Read the VS Code setup guide

Config file · macOS/Linux: ~/.codeium/windsurf/mcp_config.json

Windows: %USERPROFILE%\.codeium\windsurf\mcp_config.json

Open the MCP configuration through Windsurf’s settings when possible to confirm the active file. Paths can differ in managed or future releases; check the client documentation if this location is not present. Merge this example with existing settings; do not overwrite unrelated servers.

Windsurf configuration
{
  "mcpServers": {
    "spotify": {
      "command": "uvx",
      "args": [
        "--python",
        "3.12",
        "--from",
        "git+https://github.com/varunneal/spotify-mcp",
        "spotify-mcp"
      ],
      "env": {
        "SPOTIFY_CLIENT_ID": "YOUR_CLIENT_ID",
        "SPOTIFY_CLIENT_SECRET": "YOUR_CLIENT_SECRET",
        "SPOTIFY_REDIRECT_URI": "http://127.0.0.1:8080/callback"
      }
    }
  }
}

Read the Windsurf setup guide

Config file · Project scope: .mcp.json at the repository root

The project file uses mcpServers. For user scope, use claude mcp add --scope user rather than assuming .mcp.json in your home directory is the user configuration. Check the client documentation for managed settings and storage details. Merge this example with existing settings; do not overwrite unrelated servers.

Claude Code configuration
{
  "mcpServers": {
    "spotify": {
      "type": "stdio",
      "command": "uvx",
      "args": [
        "--python",
        "3.12",
        "--from",
        "git+https://github.com/varunneal/spotify-mcp",
        "spotify-mcp"
      ],
      "env": {
        "SPOTIFY_CLIENT_ID": "YOUR_CLIENT_ID",
        "SPOTIFY_CLIENT_SECRET": "YOUR_CLIENT_SECRET",
        "SPOTIFY_REDIRECT_URI": "http://127.0.0.1:8080/callback"
      }
    }
  }
}

Read the Claude Code setup guide

Examples are translated from the published configuration. Supply your own credentials and verify requirements in the upstream README. Remote connectors are shown only where a supported configuration format is known.

Use cases

  • Start, pause, skip tracks, and reorder the active Spotify playback queue from Claude Desktop during coding or writing sessions.
  • Search tracks, albums, artists, and playlists conversationally to assemble and update custom themed playlists.
  • Inspect metadata for currently searched tracks, albums, and artists without leaving Cursor or your MCP client.

Strengths

  • Simple Python setup powered by `spotipy` and `uv` without external proxy infrastructure.
  • Covers core daily Spotify actions: playback control, catalog search, metadata lookup, queue management, and playlist creation/editing.
  • Emits diagnostic logs to `stderr` (captured in `~/Library/Logs/Claude` on macOS) and supports MCP Inspector debugging.

Limitations

  • Explicitly marked as an inactive project as of March 2026, with most pull requests no longer merged.
  • Requires a paid Spotify Premium subscription and manual Spotify Developer Dashboard app creation with an explicit HTTP loopback redirect URI.
  • Running via `uvx` opens the Spotify redirect URI on every tool call, making a local `git clone` necessary for smooth usage; Spotify also deprecated recommendation APIs.

spotify-mcp setup notes

  • Check SPOTIFY_CLIENT_ID, SPOTIFY_CLIENT_SECRET, SPOTIFY_REDIRECT_URI in the spotify-mcp configuration if startup or authentication fails.
  • spotify-mcp's stdio example needs a client that launches local processes.

Frequently asked questions

Create an app in the Spotify Developer Dashboard with an HTTP loopback redirect URI like `http://127.0.0.1:8080/callback`, then add a `spotify` server block to `claude_desktop_config.json` or Cursor's MCP config with `SPOTIFY_CLIENT_ID`, `SPOTIFY_CLIENT_SECRET`, and `SPOTIFY_REDIRECT_URI`. Restart your MCP client to complete authorization.

Related MCP servers