youtube-search
Skill340 starsChanged 8 months agoMITView on GitHub
Search YouTube by keyword and return structured video metadata (title, URL, channel, views, duration, date) via yt-dlp. No API keys. Triggers on: "search youtube", "find youtube videos", "top youtube videos on", "trending videos on", "youtube results for", "yt search", "/yt-search".
13 other projects use a version of this.
Adopted by
Most recently taken up by
- TheVeller/claude-skillstheir own version, first seen Nov 2, 2026
- zedxter/utility-belttheir own version, first seen Nov 1, 2026
- rocosen/flashdata-mcptheir own version, first seen Oct 17, 2026
- ccsang/claude-skillstheir own version, first seen Oct 11, 2026
- Gopyr/gopyr-skills-hubtheir own version, first seen Oct 11, 2026
- artemchuikin/youtube-skillstheir own version, first seen Oct 11, 2026
Used with
Projects with it also use youtube-transcript.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
dandacompanySkillyoutube-transcript
Extract YouTube video transcripts/subtitles using yt-dlp. Handles rate limiting, auto-generated captions, multiple languages, and VTT parsing.
Also in 4 projects that use this
Other versions13 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 13
- ZeroPointRepo/youtube-skills★ 972same name
- artemchuikin/youtube-skills★ 273same name
- AISA-skills/social-media-skills★ 4same name
- audibleblink/skills★ 4same name
- TheVeller/claude-skills★ 4same name
- zedxter/utility-belt★ 4same name
- valtterimelkko/agent-workflow-skills★ 2same name
- baofeng-tech/agent-skills-so★ 0same name
- ccsang/claude-skills★ 0same name
- Gopyr/gopyr-skills-hub★ 0same name
3 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository94 other files it gives its agents.
- AGENTS.mdAGENTS.md
- adr-writerSkill
- agent-builderSkill
- animateSkill
- api-docs-generatorSkill
- appraiseSkill
- architecture-diagramSkill
- architecture-reviewerSkill
- arxiv-figuresSkill
- arxiv-packageSkill
- arxiv-preflightSkill
- benchmark-runnerSkill
- changelog-composerSkill
- chart-claritySkill
- citation-auditSkill
- codebase-advisorSkill
- code-refinerSkill
- competitive-analyzerSkill
- concept-to-imageSkill
- debug-investigatorSkill
- decision-mapSkill
- dependency-auditSkill
- devils-advocateSkill
- domain-modelingSkill
- engineering-retroSkill
- env-validatorSkill
- estimate-calibratorSkill
- feasibility-assessorSkill
- figure-rhetoricSkill
- figure-table-qualitySkill
- filesystemSkill
- githubSkill
- gpu-optimizerSkill
- handoffSkill
- html-presentationSkill
- html-videoSkill
- humanizeSkill
- idea-validatorSkill
- immuneSkill
- intakeSkill
- kg-builderSkill
- launch-videoSkill
- learning-workspaceSkill
- lightpanda-browserSkill
- linkedin-post-styleSkill
- literature-reviewSkill
- manuscript-provenanceSkill
- manuscript-reviewSkill
- manuscript-typographySkill
- market-analyzerSkill
- marp-slidesSkill
- mcp-to-skillSkill
- md-to-pdfSkill
- migration-risk-analyzerSkill
- milestone-runnerSkill
- module-deepeningSkill
- notebooklmSkill
- package-evaluatorSkill
- package-optimizerSkill
- paper-to-skillSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
1 rule. 0 are common, 0 are distinctive, and 1 is very specific to this project.
0
Common
Most of the 12 edited versions we read keep these.
0
Distinctive
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 13
Search YouTube by keyword and return structured video metadata — title, URL, channel, views, duration, upload date.
“Common” is measured: kept by at least 6 in 10 of the 12 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
YouTube Search
Search YouTube by keyword and return structured video metadata — title, URL,
channel, views, duration, upload date. Uses yt-dlp for scraping with no API
keys or OAuth required.
Prerequisites
uv tool install yt-dlpVerify:
yt-dlp --versionUsage
Basic Search
yt-dlp "ytsearch10:claude code skills" --dump-json --flat-playlist --no-warnings 2>/dev/null \
| jq -r '[.title, .url, .channel, .view_count, .duration_string, .upload_date] | @tsv'ytsearch10:— search YouTube, return 10 results (adjust number as needed)--dump-json— output metadata as JSON--flat-playlist— don't download, just list--no-warnings— suppress non-error output
Structured JSON Output
yt-dlp "ytsearch5:claude code mcp servers" \
--dump-json --flat-playlist --no-warnings 2>/dev/null \
| jq '{
title: .title,
url: .url,
channel: .channel,
views: .view_count,
duration: .duration_string,
upload_date: .upload_date,
description: (.description // "" | .[0:200])
}'Search with Sorting
yt-dlp does not support server-side sort. To sort by views or date, capture all results and sort client-side:
# Sort by view count (descending)
yt-dlp "ytsearch20:AI agents 2026" \
--dump-json --flat-playlist --no-warnings 2>/dev/null \
| jq -s 'sort_by(-.view_count) | .[:10][] | {title, url, channel, views: .view_count}'# Sort by upload date (newest first)
yt-dlp "ytsearch20:claude code tutorial" \
--dump-json --flat-playlist --no-warnings 2>/dev/null \
| jq -s 'sort_by(-.upload_date) | .[:10][] | {title, url, channel, upload_date}'Search Result Count
The number after ytsearch controls how many results to fetch:
| Pattern | Results |
ytsearch5:query | 5 results |
ytsearch10:query | 10 results (default recommendation) |
ytsearch20:query | 20 results |
ytsearch50:query | 50 results (slow, may hit rate limits) |
Recommendation: Fetch 15-20 results, then filter/sort client-side to the top N the user wants. This provides enough data for meaningful sorting without being excessive.
Workflow
User provides search query
|
v
+---------------------+
| Step 0: Deps check |
+----------+----------+
v
+---------------------+
| Step 1: Search |
| (yt-dlp ytsearch) |
+----------+----------+
v
+---------------------+
| Step 2: Parse JSON |
| (jq formatting) |
+----------+----------+
v
+---------------------+
| Step 3: Present |
| results to user |
+---------------------+Step 1: Execute Search
yt-dlp "ytsearch${COUNT}:${QUERY}" \
--dump-json --flat-playlist --no-warnings 2>/dev/nullStep 2: Parse and Format
Extract relevant fields with jq. The full metadata object from yt-dlp contains
many fields; the useful subset for search results:
| Field | Description |
.title | Video title |
.url | Full YouTube URL |
.channel | Channel name |
.view_count | Total views (integer) |
.duration_string | Duration as H:MM:SS or MM:SS |
.upload_date | Upload date as YYYYMMDD |
.description | Video description (can be long — truncate) |
.like_count | Likes (may be null) |
.comment_count | Comments (may be null) |
Step 3: Present Results
Format as a markdown table for the user:
yt-dlp "ytsearch10:${QUERY}" \
--dump-json --flat-playlist --no-warnings 2>/dev/null \
| jq -s 'sort_by(-.view_count) | .[] | "| \(.title[:60]) | \(.channel) | \(.view_count) | \(.duration_string) | \(.upload_date) |"' -rPrefix with a header row:
| Title | Channel | Views | Duration | Date |
|-------|---------|-------|----------|------|Advanced Patterns
Filter by Duration
# Only videos longer than 10 minutes (600 seconds)
yt-dlp "ytsearch20:deep dive AI agents" \
--dump-json --flat-playlist --no-warnings 2>/dev/null \
| jq -s '[.[] | select(.duration >= 600)] | sort_by(-.view_count) | .[:10][]'Filter by Recency
# Only videos from the last 30 days
CUTOFF=$(date -v-30d +%Y%m%d 2>/dev/null || date -d "30 days ago" +%Y%m%d)
yt-dlp "ytsearch20:claude code" \
--dump-json --flat-playlist --no-warnings 2>/dev/null \
| jq -s --arg cutoff "$CUTOFF" '[.[] | select(.upload_date >= $cutoff)] | sort_by(-.view_count) | .[]'Channel-Specific Search
# Search within a specific channel
yt-dlp "ytsearch10:skills site:youtube.com/c/ChannelName" \
--dump-json --flat-playlist --no-warnings 2>/dev/nullOr use the channel URL directly:
yt-dlp "https://www.youtube.com/@ChannelName/search?query=skills" \
--dump-json --flat-playlist --no-warnings 2>/dev/nullExtract URLs Only (for Piping)
# Get just URLs for feeding into other tools (watch, notebooklm)
yt-dlp "ytsearch10:claude code MCP" \
--dump-json --flat-playlist --no-warnings 2>/dev/null \
| jq -r '.url'Composability
This skill produces URLs and metadata that feed into other skills:
- watch: Pass URLs for transcript concepts, timestamped visual evidence, and question-driven video analysis
- notebooklm: Pass URLs as sources via
notebooklm source add "URL"
Example pipeline (manual steps, not automated):
/yt-search— discover 10 relevant videos- User reviews and selects videos
- Feed selected URLs into
notebooklm source addorwatch
Error Handling
| Error | Cause | Resolution |
| No results | Query too specific or misspelled | Broaden the search terms |
| Empty JSON | yt-dlp rate limited by YouTube | Wait a few minutes, retry |
yt-dlp: command not found | Not installed | uv tool install yt-dlp |
| Partial results | Some videos geo-blocked or private | Normal behavior; results are best-effort |
| Timeout | Network or YouTube slowness | Reduce result count or retry |
Limitations
- No server-side sorting: YouTube search results come in relevance order. Sorting by views or date requires fetching extra results and sorting client-side.
- Rate limiting: Aggressive scraping (50+ results, rapid repeated searches) may trigger YouTube rate limits. Space requests apart.
- Metadata completeness: Some fields (
.like_count,.comment_count) may be null for certain videos. Always handle nulls in jq filters. - No authentication: Uses public YouTube data only. Age-restricted or private videos are excluded from results.
- Search relevance: YouTube's search algorithm determines initial ordering. Results may not match exact expectations.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

