You want the text of a YouTube video as data: every line with its timestamp, ready to search, summarise or pass to a model. YouTube shows the transcript in the browser, and Google's YouTube Data API has a captions resource. That resource gives caption text only for videos you are allowed to edit.
What the official API gives you
The YouTube Data API v3 has a captions resource with two read methods. captions.list "Returns a list of caption tracks that are associated with a specified video." Google's reference adds: "the API response does not contain the actual captions."
The text comes from captions.download, which takes a track ID from captions.list. It returns the track in its original format or as SRT, VTT, TTML, SBV or SCC. With tlang it returns a machine translation.
Both methods need authorization with the youtube.force-ssl or youtubepartner scope. Google's auth guide says the API "supports the OAuth 2.0 protocol for authorizing access to private user data."
Where it stops
Google's captions.download reference says: "This method requires the user to have permission to edit the video." Its error table lists 403 forbidden: "The permissions associated with the request are not sufficient to download the caption track."
Quota is the second limit. captions.list costs 50 units and captions.download costs 200, so one transcript costs 250 units. A project gets 10,000 units a day for all endpoints except search.list and videos.insert. That is 40 transcripts a day if nothing else uses quota. More needs Google's quota extension request form. Searches come from a separate bucket of 100 calls a day; see the YouTube search API quota.
Get a public video's transcript in one request
ToolzerHub returns the transcript of a public YouTube video as JSON. You need one API key. There is no Google Cloud project, no OAuth and no access to the channel. video_reference takes a video ID or a watch, youtu.be, Shorts or embed URL.
curl "https://api.toolzerhub.com/v2/youtube/transcript?video_reference=M7lc1UVf-VE&language_code=en" \
-H "x-api-key: $TOOLZERHUB_API_KEY"
Response shape from the API reference, checked 2026-10-08. We have not captured a live response from this endpoint yet, so this shows the documented fields, not real output.
{
"data": {
"id": "string",
"transcript": [
{
"startMs": "string",
"endMs": "string",
"startTime": "string",
"text": "string"
}
]
}
}
What the fields mean:
transcriptis a list of timed segments. Each has the line'stext, itsstartMsandendMs, and a displaystartTime.- The millisecond fields are strings. Convert them to numbers before you do arithmetic.
language_codepicks the transcript language. There is no cursor: one call returns one video.
Whether a transcript exists depends on the video and its published captions. A call that fails costs nothing.
For an SRT or VTT file, GET /v2/youtube/subtitles lists a video's caption tracks with each track's language and url. Pass that url as caption_source to GET /v2/youtube/subtitle with caption_style=srt or vtt. Add translation_code for a translation. That is 2 calls per video.
What it costs
- Every call costs 1 credit. One call returns one video's transcript, so 1,000 transcripts is 1,000 credits.
- Plans start at $29 a month for 20,000 credits ($1.45 per 1,000) and go down to $0.99 per 1,000 on Business; one-time packs start at $19 for 10,000 credits and never expire. That is $0.99 to $1.90 per 1,000 transcripts.
- The SRT or VTT route is 2 credits per video: $2.22 to $3.80 per 1,000.
- Failed calls are not charged. Every account gets 100 free credits a month, which is 100 transcripts for testing.
Next step
See the YouTube API page and the YouTube reference, which lists all 29 endpoints under /v2/youtube/. Or get a free API key and run the request above.
Use Google's API for videos you can edit. There it returns the official track list and downloads tracks in five formats. We cannot upload or edit captions; captions.insert (400 units) and captions.update (450 units) can. For a few videos from your own computer, the open-source youtube-transcript-api Python library is free and "does not require an API key nor a headless browser." Its README warns that it "uses an undocumented part of the YouTube API."
Not affiliated with YouTube or Google LLC.
Details
Official API, from Google's reference pages:
- "All API requests, including invalid requests, incur at least a one-point quota cost."
captions.downloaderrors: 403forbidden, 404captionNotFound, and 400couldNotConvertwhen the requestedtfmtortlangcannot be produced.trackKindisASR("generated using automatic speech recognition"),forcedorstandard.tlangtranslations use "machine translation, such as Google Translate."
ToolzerHub:
caption_styleacceptsjson3,srv1,srv2,srv3,ttml,vttandsrt. Omitted, it issrv1./v2/youtube/subtitlereturns the track as one string indata.- For metadata on many videos,
GET /v2/youtube/videotakes comma-separated video IDs invideo_references. - Errors come back as
{ error: { code, status, message, retryable, details } }. An empty balance returns 402PAYMENT_REQUIRED.
Sources
- YouTube Data API
captions.download, https://developers.google.com/youtube/v3/docs/captions/download, checked 2026-10-08 - YouTube Data API
captions.list, https://developers.google.com/youtube/v3/docs/captions/list, checked 2026-10-08 - Captions resource, https://developers.google.com/youtube/v3/docs/captions, checked 2026-10-08
- Quota costs, https://developers.google.com/youtube/v3/determine_quota_cost, checked 2026-10-08
- Getting started (default quota, extension form), https://developers.google.com/youtube/v3/getting-started, checked 2026-10-08
- Authentication guide, https://developers.google.com/youtube/v3/guides/authentication, checked 2026-10-08
- ToolzerHub transcript reference, https://docs.toolzerhub.com/reference/youtube/video/get-you-tube-transcript, checked 2026-10-08
- ToolzerHub YouTube reference (29 endpoints), https://docs.toolzerhub.com/reference/youtube, checked 2026-10-08
- youtube-transcript-api README, https://github.com/jdepoix/youtube-transcript-api, checked 2026-10-08
- ToolzerHub plans and credit packs, https://toolzerhub.com/pricing, checked 2026-10-12
- ToolzerHub credits, https://docs.toolzerhub.com/docs/credits, checked 2026-10-08