spotify-mcp
spotify-mcp
is an MCP Server enabling AI models like Claude to interact directly with Spotify. Control playback, search music, and manage your queue seamlessly through your AI assistant.

spotify-mcp Solution Overview
spotify-mcp
is an MCP Server designed to seamlessly connect AI models, such as Claude, with your Spotify account. Built using Python and the spotipy-dev
library, it empowers your AI to interact directly with Spotify. Key features include controlling playback (start, pause, skip), searching for tracks, albums, artists, and playlists, retrieving detailed information, and managing the playback queue. This server acts as a standardized bridge, translating MCP requests from your AI client into Spotify actions, requiring a Spotify Premium account and API keys for setup. The core value lies in enabling natural language control over Spotify via your AI, simplifying integration for developers by abstracting the underlying Spotify API complexities behind the MCP standard. Integration involves configuring the server path and credentials within your MCP client, allowing the client to execute the server locally.
spotify-mcp Key Capabilities
Real-time Spotify Playback Control
This core feature enables AI models, acting as MCP clients, to directly manipulate the user's Spotify playback state in real-time. Leveraging the spotipy-dev
library, spotify-mcp
translates standardized MCP requests into specific Spotify Web API calls for actions such as starting playback (optionally with a specific context like an album or playlist), pausing the currently playing track, and skipping to the next track in the queue or context. For the AI model, this provides a powerful capability to respond directly to user commands related to music control, transforming the AI into an interactive music assistant. Developers integrating AI with Spotify benefit by avoiding the complexity of direct Spotify API authentication and state management; spotify-mcp
handles the interaction flow. A typical use case involves a user saying to their AI assistant, "Pause the music," which triggers the AI client to send a pause command through spotify-mcp
to the user's active Spotify device. This seamless integration requires a Spotify Premium account due to Spotify API limitations and relies on the secure client-server architecture of MCP for command transmission.
Integrated Spotify Content Search
spotify-mcp
empowers AI models with the ability to perform comprehensive searches across Spotify's extensive music catalog. It allows searching for specific tracks, albums, artists, and playlists based on queries provided by the AI client, often derived from natural language user requests. The MCP server receives the search parameters, utilizes the spotipy-dev
library to interact with the Spotify Search API endpoint, and then formats the results (e.g., a list of tracks with their artists and IDs) before sending them back to the AI model via the MCP connection. This significantly enhances the AI's utility as a music discovery and selection tool, allowing users to simply ask, "Find the latest album by Kendrick Lamar" or "Search for relaxing instrumental playlists." For developers, this feature abstracts the intricacies of formulating Spotify search queries and parsing the responses. The unique advantage within the MCP ecosystem is providing a standardized interface for diverse AI models to access Spotify's search functionality without needing bespoke integrations. Note: Current implementation might not support pagination for extensive results, as indicated in future development plans.
Spotify Metadata Access
This feature allows AI models to retrieve detailed information about specific items within the Spotify ecosystem, such as tracks, albums, artists, or playlists. When an AI needs context beyond just a name or ID – for example, track duration, album release date, artist genres, or playlist descriptions – it can request this metadata through spotify-mcp
. The server takes the identifier (like a Spotify URI or ID) provided in the MCP request, uses spotipy-dev
to query the relevant Spotify API endpoints (e.g., Get Track, Get Album), and returns the structured metadata back to the AI client. This capability enables the AI to provide richer, more informative responses to user queries like, "How long is this song?" or "What other albums does this artist have?". It solves the problem for developers of needing to make separate, authenticated calls to various Spotify API endpoints for information retrieval. Within the MCP framework, it standardizes access to Spotify's rich metadata, allowing any compatible AI client to easily fetch and utilize this information to enhance user interaction and provide deeper musical context.
Dynamic Playback Queue Management
spotify-mcp
provides AI models with the functionality to manage the user's Spotify playback queue dynamically. This primarily involves adding specified tracks or potentially albums to the end of the current queue. The AI client sends an MCP request containing the identifier(s) of the item(s) to be added. The spotify-mcp
server then interacts with the Spotify API, facilitated by spotipy-dev
, to execute the "add to queue" command for the user's active playback session. This feature directly addresses the user need for hands-free control over upcoming music, enabling scenarios where a user might ask their AI assistant, "Add 'Bohemian Rhapsody' to the queue." For developers, it offers a simplified method to integrate queue manipulation into their AI applications without handling the underlying API calls. While the current implementation focuses on adding items, future enhancements could potentially include viewing or clearing the queue, further strengthening the AI's role as a comprehensive music controller within the MCP ecosystem. This functionality, like playback control, typically requires a Spotify Premium subscription.