YouTube for AI Agents
This MCP server gives an AI agent a full YouTube toolkit — search, read transcripts and metadata, browse channels/playlists, download media, and cut clips — with no API key required.
youtube_search— find videos, channels, or playlists; filter by upload date (today/week/month/year), duration (short/medium/long), and sort by relevance, date, views, or rating.youtube_get_transcript— pull a video's transcript with timestamps, in a chosen language, optionally limited to a time range (startTime/endTime) or segment cap; output as full text, segments, or both.youtube_get_video_info— get metadata (title, channel, views, likes, duration, description, chapters, tags) at brief, standard, or full detail.youtube_get_channel_info— channel name, handle, description, subscriber count, country.youtube_get_channel_videos— list a channel's uploads sorted newest, most popular, or oldest (up to 500).youtube_get_playlist— playlist metadata plus its videos with positions.youtube_download— save a video (MP4) or audio (M4A/other) locally, with quality and format selection; long videos needforce.youtube_clip— cut one or more timestamped clips from a video (seconds, MM:SS, or HH:MM:SS), fast keyframe cuts or frame-accurate re-encoding, with labels; auto-builds a per-video highlight reel.youtube_highlight_reel— stitch existing clip files from multiple videos into a single ordered reel.
(README also mentions frame-grabbing and comment-reading tools, but those aren't in this schema.)
Provides tools for searching videos, watching and summarizing, browsing channels and playlists, fetching transcripts, downloading video/audio, cutting clips, and building highlight reels from YouTube.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@YouTube for AI Agents find me the best video on meditation techniques"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
YouTube for AI Agents
Your AI agent watches YouTube so you don't have to
Ask "what's the best video on…?" and your agent finds it, watches it, and tells you what matters. Paste a two-hour podcast and get the highlights with timestamps. Read the comments, see what's on screen, cut clips and build reels, all from chat.
No API key, no account. Works in Claude Code, Codex, Cursor, OpenCode and Gemini CLI.
Quick Start · Try it · Other agents · Troubleshooting
Demo

Click the image to watch the one-minute walkthrough.
Related MCP server: ytb-tools
Quick Start
You need Node.js 22 or newer. Check with node --version.
Easiest: ask your agent. Paste this into Claude Code, Codex, Cursor or any coding agent:
Install the YouTube for AI Agents plugin for me, following
https://github.com/JCodesMore/youtube-for-ai-agents#quick-start.
Make sure Node.js 22 or newer is installed first. When it's in,
run its doctor check and tell me if I need to restart.Or install it yourself in Claude Code:
claude plugin install youtube --marketplace JCodesMore/jcodesmore-pluginsInside a Claude Code session the same thing is two commands:
/plugin marketplace add JCodesMore/jcodesmore-plugins
/plugin install youtube@jcodesmore-pluginsRestart Claude Code, and start asking.
Try it
"Watch this and give me the recipe: https://youtu.be/…"
"Find me five highly rated videos on Roman history and tell me which to watch first."
"What are this channel's best uploads? Watch the top three and compare them."
"Pull the actionable takeaways from this 90-minute interview, with timestamps."
"What's the code on screen at 12:30?"
"What do the comments say about this review?"
"Cut 2:15 to 2:45 from this video."
"Make a one-minute highlight reel of the best moments from these three talks."
What's inside
Tool | What it does |
| Find videos, channels or playlists, with date, length and sort filters |
| Read what was said, with timestamps, in the spoken language or translated |
| Title, channel, views, description, chapters and tags |
| See what's on screen at given moments |
| Read the top or newest comments |
| A channel's details |
| A channel's newest, most popular or oldest uploads |
| A playlist's videos |
| Save a video (MP4) or its audio (M4A) |
| Cut moments by timestamp, downloading only those parts, and join them into a reel |
| Join clips from different videos into one reel |
Every tool takes a YouTube link as you'd paste it (watch, youtu.be, Shorts, live, embed) or a bare ID.
In Claude Code you also get the youtube skill, which teaches the agent to research and watch well; the video-watcher agent, which watches videos in parallel for bigger research; and /youtube:setup, which checks everything works and handles sign-in and settings.
Downloads and clips use yt-dlp and ffmpeg. If they aren't on your computer, the plugin fetches official builds the first time you need them.
Other agents
The tools are an MCP server, so any MCP client can use them. Full guides: Codex · Cursor · OpenCode · Gemini CLI · Claude Code
codex mcp add youtube -- npx -y @jcodesmore/youtube-for-ai-agentsgemini extensions install https://github.com/JCodesMore/youtube-for-ai-agentsAdd this server to the client's MCP settings:
{
"mcpServers": {
"youtube": {
"command": "npx",
"args": ["-y", "@jcodesmore/youtube-for-ai-agents"]
}
}
}Signing in (optional)
Everything works without an account. Signing in helps when YouTube rate-limits your network (common on VPNs and cloud machines), unlocks age-restricted videos, and makes search reflect your own history. In Claude Code run /youtube:setup; anywhere else run:
npx @jcodesmore/youtube-for-ai-agents loginA separate browser window opens with its own profile. Sign in to Google there, and the window closes itself once the sign-in is saved. Your sign-in stays on your computer in ~/.youtube-for-ai-agents; logout removes it.
Troubleshooting
Run the built-in check. It tests search, video details and a transcript from your computer, and says what to fix:
npx @jcodesmore/youtube-for-ai-agents doctorThe server didn't start, which almost always means Node.js is missing or too old. Install Node.js 22+ from nodejs.org, then fully restart your agent. In Claude Code, /mcp shows whether youtube is connected.
YouTube limits transcript requests per network, more on VPN and cloud IPs. It clears within an hour or so. Signing in usually avoids it, and transcripts you've read are cached for a week. You can also route traffic through a proxy (needs Node.js 22.19 or newer):
npx @jcodesmore/youtube-for-ai-agents config set network.proxy http://user:pass@host:portnpx @jcodesmore/youtube-for-ai-agents config # show every setting
npx @jcodesmore/youtube-for-ai-agents config set transcript.defaultLanguage en
npx @jcodesmore/youtube-for-ai-agents config set download.maxAudioDurationMinutes 300 # podcasts up to 5 h without asking
npx @jcodesmore/youtube-for-ai-agents config resetSettings, sign-in, cached transcripts and the downloaded yt-dlp and ffmpeg live in ~/.youtube-for-ai-agents. Set YOUTUBE_AI_AGENTS_HOME to move it, and YOUTUBE_AI_AGENTS_DEBUG=1 for detailed logs.
Still stuck? Ask in Discord or open an issue with the doctor output.
Community
Discord for help and show-and-tell · Issues for bugs and ideas · Contributing · More plugins
YouTube.js, an InnerTube client that needs no API key
License
Apache License 2.0. © 2026 JCodesMore
Not affiliated with, endorsed by, or associated with YouTube or Google. Download only what you have the right to, and respect creators' rights and YouTube's terms.
Available Tools
9 toolsyoutube_clipA
Extract one or more clips from a YouTube video by timestamp. Downloads the source video once at 720p, then cuts each clip. Each clip needs startTime and endTime (seconds, MM:SS, or HH:MM:SS) and an optional label for the filename. Uses fast keyframe-aligned cuts by default — do NOT set accurate: true unless the user explicitly asks for frame-perfect precision (it re-encodes and is much slower). Keep clips tight — 5-10 seconds each, capturing one key moment per clip. When 2+ clips are provided, automatically produces a per-video highlight reel alongside individual clips.
Inputs: clips (required), videoId (required), force, quality, +3 more.
youtube_downloadA
Download a YouTube video or audio track to a local file. Defaults to 720p quality. Supports quality selection (720p/1080p/best/etc.), download type (video+audio/audio/video), and format. Videos over 30 minutes trigger a confirmation prompt — use force: true to bypass. For video+audio, automatically downloads and muxes separate streams.
Inputs: videoId (required), type, force, format, +2 more.
youtube_get_channel_infoARead-only
Get metadata for a YouTube channel — name, handle, description, subscriber count, country, and more. Accepts @handle, full URL, or channel ID.
Inputs: channelId (required).
youtube_get_channel_videosARead-only
List videos from a YouTube channel. Accepts @handle, full URL, or channel ID. Returns videos sorted by newest, popular, or oldest.
Inputs: channelUrl (required), sort, limit.
youtube_get_playlistBRead-only
Get a YouTube playlist's metadata and its videos. Returns title, description, channel, video count, and the list of videos with their positions.
Inputs: playlistId (required), limit.
youtube_get_transcriptARead-only
Get the transcript of a YouTube video. Control output size with: "format" — "text" (fullText only, smallest), "segments" (timestamps only), or "both" (default). Use "startTime"/"endTime" (seconds) to grab a specific section (pairs well with chapter timestamps from youtube_get_video_info). Use "maxSegments" to cap output for previewing long videos.
Inputs: videoId (required), format, endTime, language, +2 more.
youtube_get_video_infoARead-only
Get metadata for a YouTube video. Use "detail" to control response size: "brief" (key stats only — title, channel, views, likes, duration), "standard" (default — most fields, truncated description, chapter count), or "full" (everything including full description, chapters, tags, thumbnail).
Inputs: videoId (required), detail.
youtube_highlight_reelA
Combine existing clip files into a single highlight reel. Pass file paths from previous youtube_clip results in your desired playback order. Use this after clipping multiple videos to create one combined reel across all sources. The order of the clips array determines playback order — arrange clips for narrative flow before calling.
Inputs: clips (required), label, outputDir.
youtube_searchARead-only
Search YouTube for videos, channels, or playlists. Supports filtering by upload date (today/week/month/year), duration (short/medium/long), and sorting (relevance/date/views/rating). Returns results with metadata including title, channel, views, duration, and whether results are personalized.
Inputs: query (required), type, limit, sortBy, +2 more.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 9 tools
Each tool targets a distinct resource and action: search, channel/video/playlist metadata retrieval, transcript extraction, video download, clip extraction, and highlight reel assembly. The only potential overlap is between youtube_clip and youtube_download, but clip is explicitly for extracting short segments while download fetches the full source. Descriptions make boundaries clear.
All tools use the youtube_ prefix and follow a predictable verb_noun pattern (get_channel_videos, get_video_info, get_transcript, search, download, clip). The only minor deviation is youtube_highlight_reel, which is a noun phrase, but it clearly implies a create action and fits the overall schema.
Nine tools are well-scoped for an agent consuming YouTube content, with no redundant or trivial entries. Each tool earns its place by covering a distinct step in the research, retrieval, or editing workflow.
The surface covers search, metadata, transcripts, downloads, clipping, highlight reels, playlists, and channels—core workflows for AI agents. Minor gaps exist, such as no direct tool to list all playlists for a channel or to retrieve comments/live stream info, but agents can work around these for most tasks.
Maintenance
Related MCP Connectors
YouTube for AI agents: transcripts, comments, video stats, channel monitor, Shorts captions.
YouTube transcripts, search, channel/playlist listings and upload tracking for AI agents.
Search YouTube videos, read transcripts and get public video information in your AI assistant.
YouTube transcripts, search, channels, playlists and bulk transcript jobs for AI agents. 14 tools.
Related MCP Servers
- AlicenseNot gradedqualityCmaintenanceEnables AI agents to fetch transcripts, metadata, and download videos/audio from YouTube without API keys.34MIT
- AlicenseAqualityDmaintenanceEnables AI assistants to search YouTube, fetch transcripts, and get AI summaries of videos without API keys.38 npmMIT
- AlicenseAqualityBmaintenanceAllows AI agents to fetch, search, and summarize YouTube video transcripts without an API key, including chapter summaries.4MIT
- AlicenseAqualityCmaintenanceEnables AI agents to search videos, retrieve metadata and transcripts, pinpoint exact moments via hybrid semantic search, and conduct multi-video research with timestamp deep links—all without YouTube API keys.51MIT