YouTube Data API

How to search YouTube videos programmatically

TL;DR

The YouTube Data API’s search.list endpoint lets you search YouTube programmatically, but it costs 100 quota units per call (only 100 searches/day on the default quota). You can filter by type, date, region, and order. BrightBean’s /search endpoint provides enriched results with competition scores, content gap indicators, and performance metrics.

How to search YouTube videos programmatically

The search.list endpoint is the primary way to search YouTube via API. You can specify a query, filter by video type, set geographic regions, and sort by relevance, date, view count, or rating.

A basic search returns video IDs, titles, descriptions, channel names, and thumbnail URLs. To get full statistics (view count, likes, comments), you need a follow-up videos.list call with the returned video IDs. This two-step process is standard but doubles your API calls.

Key parameters include q (search query), type (video, channel, or playlist), publishedAfter/publishedBefore (date range), regionCode, videoDuration (short, medium, long), and order (relevance, date, viewCount, rating).

The biggest limitation is quota cost. At 100 units per search call, you can only make 100 searches per day with the default 10,000 unit quota. For applications that need to monitor multiple keywords or niches, this runs out fast.

Another limitation: search results are ranked by YouTube’s algorithm, which favors established channels. There’s no way to filter for “low competition” topics or find content gaps through the native search endpoint.

How BrightBean helps

BrightBean’s /search endpoint wraps YouTube search with competitive intelligence, returning enriched results that help you evaluate opportunities.

GET /search?query=meal+prep+for+beginners&niche=cooking

{
  "query": "meal prep for beginners",
  "results": [
    {
      "title": "Meal Prep for the Week Under $30",
      "views": 1200000,
      "channel_subscribers": 450000,
      "competition_score": 0.68,
      "content_gap_signal": false
    }
  ],
  "gap_analysis": {
    "query_demand": "high",
    "supply_saturation": 0.72,
    "opportunity_rating": "moderate"
  }
}

Key takeaways

  • search.list is the main YouTube search endpoint, costing 100 quota units per call
  • You need a separate videos.list call to get full video statistics
  • Filter by type, date, region, duration, and sort order
  • The default quota limits you to ~100 searches per day
  • BrightBean enriches search results with competition scores and content gap signals

Get structured YouTube intelligence

BrightBean delivers content gaps, title scores, thumbnail analysis, and hook classification via API and MCP server.

Get early access →