Skip to main content

YouTube Scraper API

Search YouTube, pull full video and Shorts detail, fetch comments and replies, export transcripts (SRT/VTT/plain text), enumerate a channel’s videos, shorts, streams, playlists, and community posts, and retrieve trending feeds, hashtags, and playlists — from the world’s largest video platform. The API handles authentication, anti-bot bypass, and region routing automatically.

Key Features

Widest Coverage

39 endpoints — videos, Shorts, channels, playlists, comments, transcripts, trending, hashtags, community posts, and music search.

Transcripts & Captions

The /v1/youtube/videos/{id}/transcript endpoint returns timed segments plus ready-to-use SRT, VTT, and full-text exports.

Anti-Bot Bypass

Automatic session management, Chrome TLS impersonation, and fingerprint rotation to avoid blocks.

Rich Video Data

Views, likes, chapters, heatmap (most-replayed), keywords, hashtags, live details, and streaming formats.

Region & Language

Target any content region with gl and any UI language with hl for accurate, localized results.

SDK Support

First-class support via the ScrapeBadger Node.js and Python SDKs.

Regions & Languages

YouTube results are localized by content region and UI language. Two query parameters control this on most endpoints:
If omitted, gl defaults to US and hl defaults to en. Use the free /v1/youtube/regions and /v1/youtube/languages reference endpoints to fetch the full list of valid codes programmatically.

Pagination

YouTube list endpoints do not use page numbers. Every paginated response includes a continuation token; pass it back as the continuation query parameter to fetch the next page. When continuation is null, you have reached the end.

Quick Start

Endpoints

Search & Discovery

Videos & Shorts

Channels

Playlists

Community & Reference

Credit Costs

Authentication

All requests require your API key in the X-API-Key header:

Anti-Bot Handling

YouTube protects its data with IP-reputation scoring, TLS/HTTP-2 fingerprinting, bot-guard challenges, and PO-token requirements on media. ScrapeBadger clears these automatically using Chrome TLS impersonation on sessions matched to the target region. You never need to manage proxies, sessions, or tokens.
For accurate, localized results, requests are routed through proxies in the gl region. This is handled automatically. Some fields (such as dislike_count and direct media urls) are restricted by YouTube platform-wide and may be null.

Next Steps

Search YouTube

Full API reference for searching videos, channels, and playlists

Get Video Detail

Fetch full metadata for a single video