YouTube Music MCP

The YouTube Music MCP acts as a bridge between AI assistants and a vast library of songs, allowing users to control their listening experience directly through chat interfaces like Cursor or Claude Desktop. By simply asking the AI to find a specific song or play a track, the tool handles the process of navigating the music platform. This makes it easy to soundtrack a coding session or a research task without ever needing to leave the workspace or manually switch applications. On a more technical level, this server exposes two primary tools: `searchTrack` and `playTrack`. The search functionality enables the AI to query YouTube Music by track name and retrieve relevant metadata, while the play tool automates the process of identifying a song and opening it immediately in the system's default browser. To ensure reliable performance, the MCP communicates directly with the official Google YouTube API, providing the LLM with accurate, real-time data from the platform's database. For developers and power users, this MCP is a practical example of how the Model Context Protocol can extend an LLM’s reach into external web services. Integration is designed to be low-friction, requiring only a Google API key and a brief configuration in a JSON settings file. By leveraging `npx` for execution, the tool avoids the need for a complex local build process, allowing developers to quickly grant their AI agents the power to interact with streaming media and automate browser-based playback.

Category: Browser & Web Automation

Tags: google-api, media, music, streaming, youtube

Visit YouTube Music MCP

How to install and configure YouTube Music MCP

1. Installation 1. Get a YouTube API Key: Obtain a valid Google YouTube API Key from the Google Cloud Console. 2. No Manual Install Required: This MCP is typically run directly using npx and does not require local installation or building unless you intend to modify the source code.

2. Configuration Add the following configuration to your MCP settings file (e.g., Cursor's .cursor/mcp.json or the Claude Desktop configuration file): json { "mcpServers": { "youtube-music-mcp": { "command": "npx", "args": ["-y", "@instructa/mcp-youtube-music"], "env": { "YOUTUBE_API_KEY": "<INSERT_API_KEY_HERE>" } } } }

3. Available Tools * searchTrack: Search for tracks on YouTube Music by name. * playTrack: Play tracks directly by searching and opening them in your default browser.

4. Example Prompts While specific prompt strings were not provided in the source, the following usage is supported by the available tools: * "Search for [track name] on YouTube Music." * "Play [track name] on YouTube Music."

What you can do with YouTube Music MCP

Use Case 1: Maintaining "Flow State" During Deep Work Problem: Developers often lose their concentration (flow state) when they have to leave their IDE (like Cursor) to switch to a browser, navigate to YouTube Music, and search for a specific song or "Deep Focus" playlist. Solution: This MCP allows the user to stay within their coding environment. By using a natural language command to the AI assistant, the music can be found and triggered without the developer ever touching their mouse or switching tabs. Example: While refactoring a complex function in Cursor, the user types: "Play some Lofi hip hop tracks for focus." The AI uses searchTrack and playTrack to immediately open the music in the background.

Use Case 2: Quick Access to Coding Podcasts or Audio Tutorials Problem: Sometimes a developer needs to reference a specific talk or a tech podcast episode (available on YouTube Music) while reviewing code, but searching for the exact title in a cluttered browser can be distracting. Select: The searchTrack tool can be used by the AI to pinpoint a specific episode or track based on partial titles or keywords provided by the user, ensuring they get the right content quickly. Example: A user tells Claude Desktop: "Find the latest 'Syntax FM' podcast episode about React and play it." The AI searches for the track and opens the correct link instantly.

Use Case 3: Personalized Task-Based Soundtracks Problem: Different coding tasks require different "vibes" (e.g., intense music for bug hunting, calm music for documentation). Manually curating this as tasks change is a minor but frequent friction point. Solution: Users can integrate music playback into their workflow prompts. The AI assistant can be instructed to play specific genres or artists based on the phase of the project the developer is currently in. Example: A developer tells their assistant: "I’ve finished the logic; now I need to write the README. Find and play 'Weightless' by Marconi Union to help me wind down while I document this."

Use Case 4: Audio Verification for Content Creators Problem: Developers building music-related apps or curators who use AI to manage lists of tracks need a quick way to verify if a track exists or is the "correct" version without performing manual searches. Solution: The AI can use the searchTrack tool to verify the existence of a song and provide the user with a direct link or…

Key facts

  • Browser & Web Automation, Design, Media & Creative
  • google-api, media, music, streaming, youtube

Part of MCP Servers

Related MCP servers

  • MCP JSON — A collection of servers for file system operations, Google search, web automation, and executing terminal commands.
  • MCP MD2PDF Server — Convert Markdown documents to PDF with support for Mermaid diagrams.
  • MCP Media Processing Server — A server for media processing, offering powerful video and image manipulation using FFmpeg and ImageMagick.
  • MCP Music Analysis — Analyze audio from local files, YouTube, or direct links using librosa.
  • MCP OCR Server — An MCP server for Optical Character Recognition (OCR) using the Tesseract engine.
  • MCP NPX Fetch — Fetch and transform web content into various formats like HTML, JSON, Markdown, or Plain Text.
  • AI Tools
  • Categories
  • Industries
  • CLI Coding Agents
  • MCP Servers
  • MCP Categories