# YouTube Research MCP

Pulls the part of a YouTube video your agent needs, with a timestamp and a link to that exact second. Useful when you want evidence, not a whole transcript.

- MCP server · `type=mcp` · Claude Code, Codex, Cursor, GitHub Copilot, Windsurf (Devin Desktop), Cline, Zed, Gemini CLI · ★ 27
- Author: coyaSONG
- License: MIT · policy=link-only · description only; the file stays with the author
- Source: https://github.com/coyaSONG/youtube-mcp-server
- Updated: 2026-10-21
- HTML: https://affpapa.org/en/nevibecode/mcp/youtube-research-mcp

## What it does

Give it a video link and it returns caption segments tagged with timestamps and canonical URLs that jump straight to the quoted moment. Plain links, short links, Shorts, embed, live and bare video IDs all work. A transcript search tool sends back a matching stretch plus nearby context, so the model does not read the whole caption track. Timestamps come from the caption segments themselves rather than from the model.

Transcript research runs without any key. You need Node.js 22 or newer. Setting `YOUTUBE_API_KEY` for the YouTube Data API v3 turns on `full` mode: search, comments, video and channel statistics, trends and side-by-side comparisons. Skip the key and every Data API tool answers with an explicit key-required error, so add it up front if you plan to use analytics.

Local setup is stdio over `npx`. There is also a Streamable HTTP transport at `/mcp` with a public `/health` endpoint. Do not put a full-mode server on the open internet: anyone without a token can burn through your YouTube API quota. Remote deployments want a bearer token, and browser origins are refused unless listed as exact `http://` or `https://` entries in `CORS_ORIGIN` — wildcards get rejected.

## Requirements
- Needs: Node.js (commands run via npx)
- Environment variables: `YOUTUBE_API_KEY` — keys and tokens: ask the human for the values, never commit them or put them in shared files.

## Install

### Claude Code (native platform)

**Platform CLI**
```bash
claude mcp add youtube-research -e YOUTUBE_API_KEY=<YOUTUBE_API_KEY> -- npx -y @coyasong/youtube-mcp-server
```
Replace <…> with your own values

### Codex

**Platform CLI**
```bash
codex mcp add youtube-research-mcp --env YOUTUBE_API_KEY=<YOUTUBE_API_KEY> -- npx -y @coyasong/youtube-mcp-server
```
Replace <…> with your own values

### Cursor

**Config file**
File `.cursor/mcp.json`:
```json
{
    "mcpServers": {
        "youtube-research-mcp": {
            "command": "npx",
            "args": [
                "-y",
                "@coyasong/youtube-mcp-server"
            ],
            "env": {
                "YOUTUBE_API_KEY": "<YOUTUBE_API_KEY>"
            }
        }
    }
}
```
Replace <…> with your own values

### GitHub Copilot

**Config file**
File `.vscode/mcp.json`:
```json
{
    "servers": {
        "youtube-research-mcp": {
            "type": "stdio",
            "command": "npx",
            "args": [
                "-y",
                "@coyasong/youtube-mcp-server"
            ],
            "env": {
                "YOUTUBE_API_KEY": "<YOUTUBE_API_KEY>"
            }
        }
    }
}
```
Replace <…> with your own values

### Gemini CLI

**Platform CLI**
```bash
gemini mcp add -e YOUTUBE_API_KEY=<YOUTUBE_API_KEY> youtube-research-mcp npx -y @coyasong/youtube-mcp-server
```
Replace <…> with your own values

## When to use it
- quote a video passage with its timestamp and source link
- locate the one part of a long transcript that covers a topic
- pull comments and channel stats through the YouTube API
- compare several videos by their numbers and trends
- feed YouTube research to an agent without flooding its context

## Example prompts
- Use research-video to find what this talk says about evaluation and cite the exact moments: `https://www.youtube.com/watch?v=VIDEO_ID`
- Grab the comments and stats for this video, then tell me which claims come up most
- Compare these two channels across their recent uploads and list where the numbers differ

## Similar
- [REA](https://affpapa.org/en/nevibecode/mcp/rea.md) — MCP server · ★ 386989
- [GitHub](https://affpapa.org/en/nevibecode/mcp/github.md) — MCP server · ★ 33918
- [Netdata](https://affpapa.org/en/nevibecode/mcp/netdata.md) — MCP server · ★ 81115
- [browser-use](https://affpapa.org/en/nevibecode/mcp/browser-use.md) — MCP server · ★ 119160
- [Codebase Memory](https://affpapa.org/en/nevibecode/mcp/codebase-memory.md) — MCP server · ★ 47392
- [mcp-server](https://affpapa.org/en/nevibecode/mcp/mcp-server.md) — MCP server · ★ 43872

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
