YouTube scraper and API: videos, transcripts and comments without an API key
The YouTube Data API is free, official and small: 10,000 units a day, a search costs 100 of them, transcripts are not offered at all. Everything on a public video page is visible without an account, and that is what a scraper reads. This page shows what you get per video, how transcripts and comments work, where the limits are, and what it costs.
Data API versus scraper
| YouTube Data API v3 | Scraper | |
|---|---|---|
| Setup | Google Cloud project, API key, OAuth for some calls | a keyword or a URL |
| Quota | 10,000 units a day; search = 100 units, video = 1, comment thread page = 1 | none, pay per row |
| Transcripts | not available (captions download needs the owner's OAuth) | yes, any public video with captions |
| Comments | yes, 100 per page | yes, top or newest |
| Likes, tags, category | yes | yes |
| Subscriber and comment counts | yes | yes, as YouTube shows them (rounded) |
| Channel record (country, joined date, links) | partly (no links) | yes |
| Best for | an app that acts on behalf of users, small volumes | research, monitoring, datasets, AI pipelines |
The scraper
The YouTube Scraper on Apify takes search queries, channel URLs, playlist URLs or video URLs and returns one row per video. Transcripts and comments are options on the same run. A row carries:
- Video:
id,url,title,durationSeconds,viewCount,likeCount,publishedAt(date and time),category,description,keywords,thumbnailUrl,isShort,isLive. - Channel:
channelName,channelId,channelUrl,subscriberCount;commentCountwith the counts option. - Transcript:
transcriptas timed segments{start, duration, text},transcriptTextas one string,transcriptLanguage. - Comments: separate rows with
text,author,authorChannelId,likeCount,replyCount,publishedTextand thevideoIdthey belong to; replies as rows under their comment withparentId. - Channel record (option): one row per channel with
description,country,joinedAt, all-timeviewCount,videoCount,subscriberCount,handleand externallinks.
Speed: about 100 videos with details in 10-60 seconds depending on the source; listing only, several hundred a minute.
Calling it from code
curl -X POST "https://api.apify.com/v2/acts/alfalfa~youtube-scraper/run-sync-get-dataset-items?token=$APIFY_TOKEN" \
-H 'Content-Type: application/json' \
-d '{"searchQueries":["python tutorial"],"sortBy":"views","uploadDate":"month","maxVideos":50,"transcript":true}'
Longer jobs: start the run, poll it, read the dataset when it finishes. Schedules, webhooks and the n8n, Make and Zapier nodes work as for any Apify Actor; the API overview shows the pattern.
Things to know before you trust the numbers
- Search is what a visitor sees. About 20 videos per page, rarely more than 500-600 results for one query, US English settings. Split by upload date for more.
- Channels and playlists go deep. A channel's videos tab or its uploads playlist pages through the whole history, thousands of videos.
- Rounded counts. Views and likes are exact; subscriber and comment counts are what YouTube displays ("21.2M", "2.4M").
- Transcripts need captions. Manual or auto-generated; live streams have none while live. Multi-hour videos produce tens of thousands of segments.
- Comment replies come on request, up to a number per comment, and count towards the per-video comment limit.
Uses that pay for themselves
- AI and research. Transcripts of a whole channel or a topic as plain text for summaries, RAG or translation.
- Monitoring. Every new video on a keyword this week, with views and likes, into a sheet; a competitor's channel every Monday.
- Comment analysis. Top or newest comments of a launch video or a podcast with likes and authors, for sentiment and feedback mining.
- Content planning. The most viewed videos of a niche this month, their length, tags and titles.
Questions people ask
Is this allowed?
The scraper reads public pages without logging in and stores nothing but the results in your dataset. Respect YouTube's terms and the uploader's copyright when you reuse content, and personal data laws for comment authors.
Why is it this cheap?
A video's details are a few kilobytes and the scraper runs in a few megabytes of memory, so platform costs per thousand videos are cents. Transcripts are bigger, hence their own small price.
Does it download videos?
No. Metadata, transcripts and comments only.