Site scraper

YouTube Scraper: Public YouTube Pages via API

HTTP $0.50JS rendering $2.00 per 1,000 results or your own scraper from $1.95/GB

ProxyField's pick for a YouTube scraper depends on size: up to about 470 channels of 500 videos a day, the official Data API does the job at about 21 quota units per channel; beyond that, run yt-dlp on ProxyField residential proxies at $2.95/GB for 1 GB, from $1.95/GB, starting with the Easy Trial: 1 GB for $2.95. ProxyField's Web Scraping API is designed to fetch public YouTube pages for $0.50 per 1,000 successful results over plain HTTP, from $0.20 at volume, or $2.00 with JS rendering; it is in development, so contact sales to start.

Web Scraping API per 1,000 successful results
Web Scraping API prices per 1,000 successful results
FetchEntryVolume, from
HTTP$0.50$0.20
JS rendering$2.00$1.00

Billed on successful results only.

Your own scraper on residential proxies
from $1.95/GB Easy Trial: 1 GB for $2.95
gate.proxyfield.io:7000

YouTube's Terms of Service bar automated access except as YouTube allows, and the official YouTube Data API has its own terms and a daily quota. Proxies do not raise the API quota, and they do not make automated access permitted. For an app that must stay within YouTube's rules, the first choice is the API, with more quota requested through YouTube's quota and compliance audit; scraping public pages is the alternative, and you answer for following YouTube's terms.

Data

Which route for which job

JobRouteWhy
A few channels or videos, within 10,000 quota units a dayYouTube Data APINo charge within the quota; official JSON fields
Every video and view count for hundreds of channels, dailyyt-dlp flat listing on residential proxies, a new IP per channelOne request per page of a channel's tab; $2.95/GB for 1 GB, from $1.95/GB
All comments on one videoyt-dlp --write-comments on a sticky sessionOne IP for the whole comment section; 20 minutes by default, ttl up to 36 h
Comments across many videos every dayyt-dlp with one session per videoSpreads requests over many IPs
Thousands of pages a day without running scrapersProxyField Web Scraping API (Contact sales)165,000 pages a month cost $82.50 at $0.50 per 1,000
No code at allA hosted no-code YouTube scraper from a scraping marketplaceEasiest start; check its price per 1,000 videos, whether it has a new-videos-only mode and a date cut-off, whether views are exact, and its terms

Three routes compared in detail

ItemYouTube Data APIyt-dlp or your scripts on ProxyField residential proxiesProxyField Web Scraping API
AccessGoogle Cloud project and API keyProxyField account; access opens once the payment is confirmedContact sales (the API is in development)
Limit10,000 quota units a day by defaultYour request rate; one IP per request or a sticky session20 concurrent requests per account
CostNo charge within the quota$2.95/GB for 1 GB, from $1.95/GB$0.50 per 1,000 pages (HTTP), from $0.20; $2.00 with JS rendering, from $1.00
OutputJSON fieldsyt-dlp's JSON, CSV you writeThe public page, with its embedded JSON
CommentscommentThreads.list, 1 unit per page of up to 100 threads--write-comments: every comment and replyRendered page with scrolling, parsed by you
Every video of a channeluploads playlist, 1 unit per 50 videos--flat-playlist on the channel's /videos tabThe /videos tab and its continuation requests
Search100 units per searchyt-dlp ytsearch or the results pageOne result per results page

Scrape all comments on a YouTube video without the Data API quota

On the Data API, all comments on a video cost 1 quota unit per page of 100 top-level threads (about 500 units for 50,000 threads), plus 1 unit per page of replies for each thread whose replies are cut short. To spend no quota at all, run yt-dlp on the video through a proxy: it pages through every comment thread and its replies and writes them to the video's JSON file, with no API key. Each comment comes with its ID, parent, author, text, like count, timestamp and the pinned and hearted flags.

Read moreShow less
Shell
PROXY="http://<login>-country-us-session-c0mments1-ttl-1800:<password>@gate.proxyfield.io:7000"
# every comment and reply, newest first, no video download
yt-dlp --proxy "$PROXY" --skip-download --write-info-json --write-comments \
  --extractor-args "youtube:comment_sort=new" \
  -o "%(id)s" "https://www.youtube.com/watch?v=VIDEO_ID"

comment_sort=top gives YouTube's top order instead (new is yt-dlp's default). To stop early, add max_comments after a semicolon: --extractor-args "youtube:comment_sort=new;max_comments=1000" stops after 1,000 comments. Its value is a comma-separated list of up to five limits, in the order comments, parents, replies, replies per thread and depth, each all by default; 1000,all,100 takes at most 1,000 comments with at most 100 replies in total (yt-dlp README, "EXTRACTOR ARGUMENTS"). Then turn the JSON into a CSV:

Python
import csv, json, sys

video_id = sys.argv[1]
info = json.load(open(f"{video_id}.info.json", encoding="utf-8"))
comments = info.get("comments") or []
with open(f"{video_id}-comments.csv", "w", newline="", encoding="utf-8") as f:
    w = csv.writer(f)
    w.writerow(["id", "parent", "author", "likes", "pinned", "hearted", "timestamp", "text"])
    for c in comments:
        w.writerow([c.get("id"), c.get("parent"), c.get("author"), c.get("like_count"),
                    c.get("is_pinned"), c.get("is_favorited"), c.get("timestamp"), c.get("text")])
print(len(comments), "comments")

parent is root for a top-level comment and the parent's ID for a reply.

Which session to use. Page through one video's comments on a sticky IP (the -session-<id>-ttl-1800 part above keeps one IP for 30 minutes), and give each video its own session or rotate per video when you collect many. Without ttl, a sticky session lasts 20 minutes; the maximum is 36 h.

Threads and replies: the two routes side by side.

ItemData APIyt-dlp --write-comments
Top-level commentscommentThreads.list with part=snippet,replies, maxResults=100 and the previous page's pageToken: 1 unit per page of up to 100 threadsevery thread, no API key
Repliesa thread returns only some of its replies; the rest need comments.list with parentId set to the thread's ID: 1 more unit per page of up to 100 repliesevery reply in the same pass (parent holds the thread's ID)
Resume after a stopfrom the last pageToken, if you cached itrun again; the whole video is read again
Limit10,000 units a day by defaultyour request rate on the proxy
Costno charge within the quotaproxy traffic: $2.95/GB in a 1–9 GB purchase, $2.79 from 10 GB, $2.49 from 100 GB, $1.95 from 1,000 GB

What a daily comment job costs in quota. For videos with about 50,000 top-level threads each, before any extra reply pages:

Videos a dayData API unitsFits the default 10,000 a day?Route
1about 500yes, 5% of itData API
20about 10,000the whole quota, with nothing left for repliesData API at the limit
100about 50,000no, 5 times the quotamore quota through YouTube's compliance audit, or yt-dlp on residential proxies

On the yt-dlp route the cost is the traffic you use: run one large video on the Easy Trial (1 GB for $2.95), read the GB it used in the dashboard's real-time usage stats, and multiply by your video count and the tier price above. Comment pages are JSON with no video, so the traffic stays small next to a video download.

Cache Data API pages and resume from the last pageToken instead of starting over. If your app must stay on the API, ask for more quota through YouTube's quota and compliance audit.

The errors you will meet (the Data API's from its error reference):

WhereWhat you seeWhat it meansWhat to do
Data API, any callHTTP 403, reason quotaExceeded: "The request cannot be completed because you have exceeded your quota."the project's daily units are used upstop for the day and resume from the cached pageToken, request more quota, or switch to yt-dlp
Data API, commentThreads.listHTTP 403, reason commentsDisabled: "The video identified by the videoId parameter has disabled comments."the video has comments turned offskip the video; no route returns its comments
yt-dlpan error line ending in HTTP Error 429: Too Many RequestsYouTube is slowing this IPpause, lower the rate and give each video its own session (what a 429 means)

With the Web Scraping API (in development, Contact sales), a rendered page that scrolls the comment section (render: true with an infinite_scroll action, up to 50 scrolls) is one result at $2.00 per 1,000, from $1.00; how many comments one page holds depends on the video.

Every video and its view count from a list of channels

The pick: for a list of channels, use the Data API's uploads playlist up to about 470 channels of 500 videos a day (about 21 quota units each, 1 + 10 + 10); beyond that, or when you re-read hundreds of channels every day, use yt-dlp's flat listing on residential proxies. Both scripts below read the same channels.txt (one channel URL per line, such as https://www.youtube.com/@YouTube) and write a CSV.

Read moreShow less
ItemData API uploads playlistyt-dlp flat listing on residential proxies
Cost per 500-video channelabout 21 quota unitstraffic for one request per page of the /videos tab
Daily ceilingabout 470 such channels in 10,000 unitsyour request rate
View countsexact (statistics.viewCount)from the channel page; a second pass gives exact counts
Needsa Google Cloud project and API keya ProxyField account, from 1 GB for $2.95

Route 1: the Data API, in Python

  1. channels.list with forHandle and part=contentDetails returns the channel's uploads playlist (contentDetails.relatedPlaylists.uploads): 1 unit.

  2. playlistItems.list pages through that playlist, up to 50 videos per page: 1 unit per page.

  3. videos.list with part=snippet,statistics takes the video IDs in groups of 50 and returns statistics.viewCount: 1 unit per call.

Python
# YT_API_KEY=<your key> python3 channels_api.py
import csv, os, requests

API, KEY, units = "https://www.googleapis.com/youtube/v3/", os.environ["YT_API_KEY"], 0

def call(method, **params):
    global units
    units += 1                     # channels, playlistItems and videos .list cost 1 unit each
    r = requests.get(API + method, params={**params, "key": KEY}, timeout=30)
    r.raise_for_status()
    return r.json()

with open("videos.csv", "w", newline="", encoding="utf-8") as f:
    w = csv.writer(f)
    w.writerow(["channel", "video_id", "published", "views", "likes", "comments", "title"])
    for url in [l.strip() for l in open("channels.txt") if l.strip()]:
        handle = url.rstrip("/").rsplit("/", 1)[-1]                 # "@YouTube"
        found = call("channels", part="contentDetails", forHandle=handle).get("items") or []
        if not found:
            print("not found:", url)
            continue
        uploads = found[0]["contentDetails"]["relatedPlaylists"]["uploads"]
        ids, token = [], None
        while True:
            page = call("playlistItems", part="contentDetails", playlistId=uploads, maxResults=50,
                        **({"pageToken": token} if token else {}))
            ids += [i["contentDetails"]["videoId"] for i in page["items"]]
            token = page.get("nextPageToken")
            if not token:
                break
        for i in range(0, len(ids), 50):
            for v in call("videos", part="snippet,statistics", id=",".join(ids[i:i + 50]))["items"]:
                s = v["statistics"]
                w.writerow([url, v["id"], v["snippet"]["publishedAt"], s.get("viewCount"),
                            s.get("likeCount"), s.get("commentCount"), v["snippet"]["title"]])
print("quota units used:", units)  # about 21 for a 500-video channel

Avoid search.list for this: it costs 100 units per call and is not built to list a whole channel. A channel that hides its like count returns no likeCount, so that cell stays empty.

Route 2: yt-dlp on residential proxies

Loop over your channels with yt-dlp's flat listing: one request per page of each channel's /videos tab, not one per video. Each output line is the channel URL, the video ID, the view count and the title.

Shell
PROXY="http://<login>-country-us:<password>@gate.proxyfield.io:7000"
# channels.txt: one channel URL per line, e.g. https://www.youtube.com/@YouTube
while read -r url; do
  yt-dlp --proxy "$PROXY" --flat-playlist \
    --print "$url %(id)s %(view_count)s %(title)s" "$url/videos" >> videos.txt
done < channels.txt

The flat listing takes views from the channel page, and an entry can come back as NA (live and upcoming videos, for example). For exact counts, run a second pass that opens each video page: yt-dlp --proxy "$PROXY" --skip-download --print "%(id)s %(view_count)s %(like_count)s %(upload_date)s" --batch-file ids.txt.

The same job in Python, writing a CSV:

Python
import csv
from yt_dlp import YoutubeDL

opts = {"proxy": "http://<login>-country-us:<password>@gate.proxyfield.io:7000",
        "extract_flat": True, "quiet": True}
channels = [line.strip() for line in open("channels.txt") if line.strip()]
with YoutubeDL(opts) as ydl, open("videos.csv", "w", newline="", encoding="utf-8") as f:
    w = csv.writer(f)
    w.writerow(["channel", "video_id", "views", "title"])
    for url in channels:
        tab = ydl.extract_info(url.rstrip("/") + "/videos", download=False)
        for v in tab.get("entries") or []:
            w.writerow([url, v.get("id"), v.get("view_count"), v.get("title")])  # views can be empty in flat mode

What each column holds, by route:

ColumnData API scriptyt-dlp flat listing
channelthe channel URL from channels.txtthe same
video_idfrom the uploads playlistfrom the /videos tab
viewsexact statistics.viewCountthe count shown on the channel page; empty (NA in --print) for live and upcoming videos
titlesnippet.titlethe title on the tab
published, likes, commentsyes (likes empty when the channel hides them)not in flat mode; a second pass per video adds them

What videos.csv looks like (the values are illustrative):

channel,video_id,views,title
https://www.youtube.com/@YouTube,VIDEO_ID_1,1834467,First video title
https://www.youtube.com/@YouTube,VIDEO_ID_2,,Live stream title

Daily runs: only the new videos

The /videos tab lists the newest videos first, so a daily run reads only the top 30 entries of each channel (playlist_items, the Python name of yt-dlp's -I 1:30) and keeps a file of the IDs it has already seen:

Python
# run once a day; appends only videos not seen before to new-videos.csv
import csv, datetime, os
from yt_dlp import YoutubeDL

opts = {"proxy": "http://<login>-country-us:<password>@gate.proxyfield.io:7000",
        "extract_flat": True, "playlist_items": "1:30", "quiet": True}
seen = set(open("seen.txt").read().split()) if os.path.exists("seen.txt") else set()
today = datetime.date.today().isoformat()
with YoutubeDL(opts) as ydl, open("new-videos.csv", "a", newline="", encoding="utf-8") as f, \
        open("seen.txt", "a") as log:
    w = csv.writer(f)
    for url in [l.strip() for l in open("channels.txt") if l.strip()]:
        for v in ydl.extract_info(url.rstrip("/") + "/videos", download=False).get("entries") or []:
            if v["id"] not in seen:
                seen.add(v["id"])
                log.write(v["id"] + "\n")
                w.writerow([today, url, v["id"], v.get("view_count"), v.get("title")])

The first run records every channel's latest 30 videos; each later run adds only what was uploaded since. The same idea on the Data API: read only the first page of each uploads playlist (1 unit per channel) and skip the IDs you have.

Limits of both routes:

  • Live and upcoming videos come back with no view count (an empty cell, or NA in yt-dlp's --print).
  • Private, deleted and members-only videos do not appear.
  • View counts are snapshots of the moment you read them; store the date with each run if you track growth.
  • Shorts and live streams sit on the channel's /shorts and /streams tabs for yt-dlp; list them the same way.

Sizing on ProxyField. Tracking 500 channels and 5,000 videos once a day is 165,000 pages a month: $82.50 on the Web Scraping API (in development, Contact sales) at $0.50 per 1,000, or $33 at the $0.20 volume price, which applies from 10,000 results in one purchase. With yt-dlp on residential proxies you pay per GB instead, from $1.95/GB, and a flat listing needs one request per page of a channel's tab, not one per video.

Do it yourself

Do you need proxies to scrape YouTube at scale?

Usually no for the Data API, yes for scraping pages at scale. The Data API runs from your own server, and what limits it is 10,000 quota units a day by default, not your IP; proxies do not raise that quota. Scraping the pages is different: YouTube slows or challenges clients that send many requests from one IP, and yt-dlp then reports errors such as HTTP 429 (what a 429 means).

When you need proxies, with the Data API's own unit costs:

Daily jobData API unitsWithin the default 10,000?Proxies needed?
Every video and view count of 470 channels of 500 videosabout 9,870 (21 each)yesno: use the Data API
The same for 1,000 such channelsabout 21,000noyes, for yt-dlp on residential proxies, or ask for more quota
All comments on 20 videos of 50,000 threadsabout 10,000 (500 each)at the limitno, if nothing else uses the quota that day
All comments on 100 such videosabout 50,000noyes, for yt-dlp on residential proxies, or ask for more quota
100 keyword searches10,000 (100 each)at the limitonly beyond 100 a day, for the results pages
Read moreShow less

On the proxy route, rotate residential IPs across videos and channels, use a sticky session to page through one video or one channel, pause between requests and keep to public pages. The username decides which:

JobUsername on gate.proxyfield.io:7000What it does
All comments on one video<login>-country-us-session-vid0001-ttl-1800one IP for 30 minutes while yt-dlp pages through the comments
Comments on many videosa new -session-<id> per video, e.g. -session-vid0002each video on its own IP
A list of channels (flat listing)<login>-country-usa new IP on every request
One long channel tab<login>-country-us-session-ch0042one IP for the whole tab, 20 minutes by default

Sticky sessions run from 30 s to 36 h (ttl 30–129,600); an IP idle for 120 s gets a new IP. ProxyField residential proxies cost $2.95/GB for 1 GB and fall to $1.95/GB from 1,000 GB; the pool has 412M+ residential IPs in 195+ countries, with targeting by country, region (state) and city.

If your app must stay on the API: YouTube's developer policies govern every app that uses the Data API, and more quota is requested through YouTube's quota and compliance audit. Proxies do not replace that request.

YouTube data you can collect

YouTube pages carry most of their data as JSON inside the HTML (the ytInitialData object), so a plain HTTP fetch returns more than the visible text. The Web Scraping API fetches any URL and returns the page; your code reads the fields. ProxyField sells no separate YouTube API with pre-parsed fields.

YouTube pageWhat the public page shows
Channel (/@name, /videos, /about)Channel name, handle, subscriber count, video count, description, links, the latest videos
Video (/watch?v=)Title, description, views, likes, publish date, duration, chapters, tags, the first comments
Search resultsVideo, channel and playlist results for a keyword, with views and dates
PlaylistEvery video in the list with title, channel and duration
ShortsTitle, views and channel of each short

The /about page holds the description, the links the creator lists and the join date. The business-email button on that page needs a signed-in account, which is out of scope: ProxyField's acceptable use policy forbids accessing data behind logins you are not entitled to. Captions and auto-generated transcripts are separate files that yt-dlp fetches with --write-auto-subs.

How a Web Scraping API request works

You send a YouTube URL, such as https://www.youtube.com/@YouTube/videos, and the Web Scraping API returns the page, over plain HTTP or with JS rendering. The API's design: a POST to https://api.proxyfield.io/v1/scrape with your API key in an Authorization: Bearer <api_key> header and a JSON body with url, render (false for plain HTTP, true for JS rendering), country and output (html, markdown, text or json). country sets the exit IP's country as a two-letter code such as de, so search results come as viewers there see them; it accepts the proxy pool's 195+ countries. Parameter reference: API documentation.

Shell
# The request the Web Scraping API takes (access through Contact sales)
curl https://api.proxyfield.io/v1/scrape \
  -H "Authorization: Bearer <api_key>" \
  -H "Content-Type: application/json" \
  -d '{"url": "https://www.youtube.com/@YouTube/videos", "render": false, "country": "us", "output": "json"}'

Example response (shortened; content is the page's HTML, with the ytInitialData JSON inside):

JSON
{
  "metadata": {"id": "req_b1697753a9918502", "api": "web_scrape", "status": "success", "billed": true},
  "status_code": 200,
  "final_url": "https://www.youtube.com/@YouTube/videos",
  "content_type": "text/html; charset=utf-8",
  "content": "<!DOCTYPE html><html lang=\"en\">…var ytInitialData = {…};…</html>"
}
Pricing

Pricing: $0.50 per 1,000 pages, from $0.20

A channel or video page counts as one result. The volume price starts at 10,000 successful results in one purchase.

You pay only for successful results. Billed: a page YouTube answered with a 2xx status; a target's 404 or 410, and a sign-in page the site serves with a 200 status, also count as billed results. Not billed: blocked requests, timeouts, errors on our side and our internal retries. Every response says whether it was billed. For availability, contact sales through the sales team on our 24/7 live chat.

Payment and balance for the API: the same crypto balance as proxies, which never expires; there is no subscription or monthly fee. Residential proxies: no subscription, the traffic never expires, and all purchases are final. All prices: pricing.

Through the sales team on our 24/7 live chat

Route
Route, Entry price, At volume
RouteEntry priceAt volume
Web Scraping API, plain HTTP$0.50 per 1,000 successful resultsfrom $0.20
Web Scraping API, JS rendering$2.00 per 1,000 successful resultsfrom $1.00
yt-dlp or your own scripts on residential proxies$2.95/GB (Easy Trial: 1 GB)from $1.95/GB at 1,000+ GB

Proxy settings for yt-dlp and your scripts

yt-dlp takes a proxy with --proxy; ProxyField runs HTTP, HTTPS and SOCKS5 on gate.proxyfield.io:7000 with the same login. The username takes optional parts after your login: -country-<cc>, -region-<region>, -city-<city>, -session-<id> and -ttl-<seconds> (30 to 129,600 seconds, 20 minutes by default), as in <login>-country-us-region-new_york-city-new_york-session-he9f2qga-ttl-600. Without a session, every request gets a new IP. For browser automation, see Playwright or Puppeteer.

Shell
# English auto-generated transcript through a German IP
yt-dlp --proxy "http://<login>-country-de:<password>@gate.proxyfield.io:7000" \
  --skip-download --write-auto-subs --sub-langs en "https://www.youtube.com/watch?v=VIDEO_ID"

Metadata and comments are light; downloading video files uses far more traffic and is not what this page is about.

Use cases

What teams use YouTube data for

  • Creator and influencer research: subscribers, upload rate and views per video.
  • Competitor channel tracking for brands and media teams.
  • Comment and sentiment analysis on product reviews and launches.
  • Search and topic research: which videos rank for a keyword in a country.
  • Transcripts for research, summaries and accessibility work on content you may use.

Faking views, likes or comments is forbidden under ProxyField's acceptable use policy.

More scrapers

More scrapers

FAQ

YouTube Scraper FAQ

24/7 support by live chat, including help with setup and integration.

Do I need proxies to scrape YouTube comments and channel data at scale?

ProxyField residential proxies, from $1.95/GB, are needed only past the Data API's limits: proxies do not raise its quota of 10,000 units a day, so up to about 470 channels of 500 videos or 20 videos of 50,000 comment threads a day you need none. Beyond that, scraping the pages with yt-dlp needs residential proxies, because YouTube slows clients that send many requests from one IP; the first 1 GB costs $2.95. Use a sticky session (-session-<id>-ttl-1800) for one video's comments and a new IP per channel for channel lists.

How do I scrape all the comments on a YouTube video without burning through the YouTube Data API quota?

About 500 of your 10,000 daily Data API units cover a video with 50,000 top-level threads (commentThreads.list, 1 unit per page of up to 100), plus 1 unit per page of replies for threads whose replies are cut short; when the units run out the API answers 403 quotaExceeded. To use no quota, run yt-dlp --skip-download --write-info-json --write-comments on the video through a sticky proxy session: it pages through every comment and reply with no API key, you pay for proxy traffic from $1.95/GB ($2.95 for the first 1 GB), and a short Python script turns the JSON into a CSV.

What's the best YouTube scraper for pulling every video and its view counts from a list of channels?

ProxyField's pick depends on volume: up to about 470 channels of 500 videos a day, the Data API's uploads playlist, about 21 quota units per channel, with exact view counts and no charge within 10,000 units a day (the Python script is on this page). Beyond that, yt-dlp's flat listing of each channel's /videos tab on ProxyField residential proxies, from $1.95/GB (1 GB for $2.95 to start), into a CSV of channel, video ID, views and title, reading only the newest 30 videos on daily runs. If you want no code at all, a hosted no-code scraper from a scraping marketplace is the easiest start: check its price per 1,000 videos, its new-videos-only mode and its terms.

How does a YouTube scraper API work?

You send a YouTube URL, the API fetches the page and returns it, and your code reads the fields from the page's embedded JSON. ProxyField's Web Scraping API is billed on successful results only.

How much does it cost to scrape YouTube?

With the Web Scraping API, $0.50 per 1,000 successful results over plain HTTP, from $0.20 at volume; 165,000 channel and video pages a month cost $82.50 at the entry price. With your own scripts, you pay for residential traffic from $1.95/GB, and metadata pages are light.

How do I scrape YouTube comments?

Run yt-dlp --skip-download --write-info-json --write-comments on the video URL through a proxy: the comments land in the video's JSON file. Comments load in their own requests after the video, so a plain page fetch shows only the first ones.

How do I scrape a YouTube channel's videos?

Run yt-dlp with --flat-playlist on the channel's /videos tab to list every upload, or fetch the tab and follow its continuation requests. The /about page adds the description, links and join date.

How do I scrape YouTube videos?

Fetch each /watch?v= page and read the title, views, likes, publish date, duration and description from the embedded JSON, or let yt-dlp return them with --dump-json. Collect metadata; downloading the video files is a different job and uses far more traffic.

How do I scrape YouTube search results?

Fetch youtube.com/results?search_query= with your keyword and read the video, channel and playlist results from the page. Results change by country, so send the request from the country you are researching.

What data can you scrape from YouTube?

Public channel stats, video titles, views, likes, publish dates, durations, descriptions, tags, comments, transcripts, playlists and search results. Data that needs a signed-in account is out of scope.

Show 14 more questionsShow fewer questions

Does YouTube have an official API, and can you scrape without it?

Yes: the YouTube Data API returns videos, channels and comments with a Google Cloud API key, within 10,000 quota units a day by default. Without it, a scraper or yt-dlp reads the public pages.

Do I need an account to scrape YouTube?

No: channels, videos, comments and search results are public. Signed-in features such as a channel's business email are out of scope under ProxyField's acceptable use policy.

How do I scrape YouTube data with Python?

Use the yt_dlp library with extract_flat and a proxy, as in the code on this page, to list each channel's videos with their views and titles into a CSV. For other pages, fetch the HTML and parse the ytInitialData JSON it carries.

How do I scrape YouTube transcripts?

Run yt-dlp with --skip-download --write-auto-subs --sub-langs en to save the auto-generated captions, or --write-subs for captions the creator uploaded. Not every video has a transcript.

What does the YouTube Data API's quotaExceeded error mean?

The API answers HTTP 403 with the reason quotaExceeded ("The request cannot be completed because you have exceeded your quota.") when your project has used its daily units, 10,000 by default. Stop for the day and resume from your cached pageToken, request more quota through YouTube's compliance audit, or move the job to yt-dlp, which uses no quota.

How do I scrape YouTube without getting blocked?

Rotate residential IPs across videos, use a sticky session for one video's comment pages, pause between requests, keep to public pages and slow down when you start getting HTTP 429 errors. Or send the URLs to the Web Scraping API instead.

What are the rate limits when scraping YouTube?

YouTube publishes no limit for page requests; it slows clients as it sees fit. The Data API's limit is its daily quota, 10,000 units by default, where one search costs 100 units and a page of comments, playlist items or video details costs 1.

Can I scrape YouTube from a specific country?

Yes: send the requests through IPs in that country, so you see search results and trending videos as viewers there do. ProxyField residential proxies offer targeting by country, region (state) and city, with 412M+ residential IPs in 195+ countries.

Do you need a headless browser to scrape YouTube?

Usually not: the page HTML carries its data as JSON, so plain HTTP at $0.50 per 1,000 results reads most of it. A browser, or JS rendering at $2.00 per 1,000, helps when you need content that loads on scroll and you are not following the continuation requests yourself.

Can I scrape YouTube Shorts and live streams?

Shorts have their own pages with title, views and channel, and yt-dlp reads them like any video; a channel's /shorts and /streams tabs list them. Live streams have a watch page too, with the title, channel and viewer count while live.

Can I scrape YouTube without writing code?

yt-dlp needs one command line and no programming, and it covers metadata, comments and transcripts. The Web Scraping API is called from your own code.

Can I scrape emails from YouTube channels?

The business email on a channel's About page is shown only to signed-in users after a check, so it is out of scope under ProxyField's acceptable use policy. The links a creator lists on that page are public.

Why scrape YouTube, and what is YouTube data used for?

Teams use it for creator research, competitor channel tracking, comment and sentiment analysis, and keyword research on what ranks in YouTube search. Transcripts feed summaries and research on content you are allowed to use.

How do I get started with a YouTube scraper API?

Contact sales with the YouTube pages and volume you plan; the price is $0.50 per 1,000 successful results over plain HTTP, from $0.20 at volume. To run yt-dlp through ProxyField residential proxies instead, start with the Easy Trial: 1 GB for $2.95.

Collect YouTube pages with the Web Scraping API

Billed on successful results only. Contact sales for the Web Scraping API and the volume you need, or run your own scraper on residential proxies. 24/7 live chat helps with setup and integration.