Skip to main content
Glama

Youtube MCP Server

Youtube MCP server

About

The server is a bridge between the Youtube API and the AI assistants and is based on the Model Context Protocol.

What is MCP?

The Model Context Protocol (MCP) is a system that lets AI apps, like Claude Desktop, connect to external tools and data sources. It gives a clear and safe way for AI assistants to work with local services and APIs while keeping the user in control.

What does this server do?

  • Download closed captions for the given video

Practical use cases

  • Create a summary of the video

Prerequisites

Installation

uv tool install git+https://github.com/sparfenyuk/mcp-youtube

Note

If you have already installed the server, you can update it using uv tool upgrade --reinstall command.

Note

If you want to delete the server, use the uv tool uninstall mcp-youtube command.

Configuration

Claude Desktop Configuration

Configure Claude Desktop to recognize the Youtube MCP server.

  1. Open the Claude Desktop configuration file:
    • in MacOS, the configuration file is located at ~/Library/Application Support/Claude/claude_desktop_config.json
    • in Windows, the configuration file is located at %APPDATA%\Claude\claude_desktop_config.json

    Note: You can also find claude_desktop_config.json inside the settings of Claude Desktop app

  2. Add the server configuration
    { "mcpServers": { "mcp-youtube": { "command": "mcp-youtube", } } } }

Development

Getting started

  1. Clone the repository
  2. Install the dependencies
    uv sync
  3. Run the server
    uv run mcp-youtube --help

Tools can be added to the src/mcp_youtube/tools.py file.

How to add a new tool:

  1. Create a new class that inherits from ToolArgs
    class NewTool(ToolArgs): """Description of the new tool.""" pass
    Attributes of the class will be used as arguments for the tool. The class docstring will be used as the tool description.
  2. Implement the tool_runner function for the new class
    @tool_runner.register async def new_tool(args: NewTool) -> t.Sequence[TextContent | ImageContent | EmbeddedResource]: pass
    The function should return a sequence of TextContent, ImageContent or EmbeddedResource. The function should be async and accept a single argument of the new class.
  3. Done! Restart the client and the new tool should be available.

Validation can accomplished either through Claude Desktop or by running the tool directly.

Debugging the server in the Inspector

The MCP inspector is a tool that helps to debug the server using fancy UI. To run it, use the following command:

npx @modelcontextprotocol/inspector uv run mcp-youtube

Troubleshooting

Message 'Could not connect to MCP server mcp-youtube'

If you see the message 'Could not connect to MCP server mcp-youtube' in Claude Desktop, it means that the server configuration is incorrect.

Try the following:

  • Use the full path to the mcp-youtube binary in the configuration file
Deploy Server
A
security – no known vulnerabilities
A
license - permissive license
A
quality - confirmed to work

hybrid server

The server is able to function both locally and remotely, depending on the configuration or use case.

连接 YouTube API 和 AI 助手,通过下载和处理隐藏字幕来实现视频分析,从而创建 YouTube 视频摘要。

  1. 关于
    1. 什么是 MCP?
      1. 这个服务器是做什么的?
        1. 实际用例
          1. 先决条件
            1. 安装
              1. 配置
                1. Claude桌面配置
              2. 发展
                1. 入门
                2. 在检查器中调试服务器
              3. 故障排除
                1. 消息“无法连接到 MCP 服务器 mcp-youtube”

              Related MCP Servers

              • -
                security
                F
                license
                -
                quality
                Enables AI language models to interact with YouTube content through a standardized interface, providing tools for retrieving video information, transcripts, channel analytics, and trend analysis.
                Last updated -
                724
                47
              • -
                security
                F
                license
                -
                quality
                Enables AI systems to download and analyze YouTube video comments through 4 specialized tools without requiring API keys, supporting engagement analysis, comment search, and statistics gathering.
                Last updated -
              • -
                security
                A
                license
                -
                quality
                Turn YouTube, TikTok, X videos and websites into structured data. Skip the hassle of video transcription and data scraping. Our APIs help you build better software and AI products faster.
                Last updated -
                13
                11
                MIT License
              • -
                security
                A
                license
                -
                quality
                Enables AI models like Claude to easily access and utilize subtitle data from YouTube videos by extracting transcripts from video URLs with support for multiple languages.
                Last updated -
                1
                MIT License
                • Apple

              View all related MCP servers

              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/sparfenyuk/mcp-youtube'

              If you have feedback or need assistance with the MCP directory API, please join our Discord server