Youtube Transcript Scraper
Pricing
Pay per usage
Youtube Transcript Scraper
Extract YouTube video transcripts, subtitles, captions, timestamps, video metadata, and text at scale. Scrape accurate transcript data from YouTube URLs for AI training, LLM datasets, content analysis, research, SEO, summarization, and automation workflows.
Pricing
Pay per usage
Rating
0.0
(0)
Developer
Shahid Irfan
Maintained by CommunityActor stats
0
Bookmarked
2
Total users
1
Monthly active users
2 days ago
Last modified
Categories
Share
What does YouTube Transcript Scraper API do?
YouTube Transcript Scraper API extracts transcripts, timestamped segments, and public metadata from one or more YouTube video URLs. Add direct video links to video_urls, choose a caption language, and receive one structured dataset item per video. It uses @egoist/youtube-transcript-plus as the primary provider, with youtube-transcript as a fallback. Every request is sent through impit (Chrome impersonation) so a residential Apify proxy can be applied.
The Actor is useful for building searchable transcript libraries, AI and RAG datasets, research collections, accessibility workflows, and content analysis pipelines. It supports standard watch links, shortened links, Shorts, live video links, and embed links.
Why use YouTube Transcript Scraper API?
- Transcript-first output - Get complete caption text and timestamped segments in a predictable format.
- Proxy-ready - All requests go through
impit, so an Apify residential proxy is applied to the InnerTube player call and the caption download. - Batch video processing - Submit multiple video URLs in one run and receive one result per video.
- Language selection - Request a language by name, such as
EnglishorSpanish, or by code, such asen. - Metadata included - Combine transcript content with titles, descriptions, publication text, views, duration, thumbnails, creator information, and public status fields.
- Clean dataset records - Unavailable values are omitted instead of being returned as
null, empty strings, or empty arrays. - Workflow-ready exports - Download results as JSON, CSV, Excel, XML, and other Apify dataset formats, or connect the run to webhooks and integrations.
What data can you extract from YouTube videos?
| Field | Description |
|---|---|
video_id | Stable YouTube video identifier. |
title | Public video title. |
url | Canonical watch URL for the video. |
description | Public video description when available. |
transcript | Complete caption text in reading order. |
transcript_language | Language label selected for the transcript. |
transcript_language_code | Language code, such as en or es. |
transcript_segments | Array of timestamped caption segments. |
transcript_segments[].start_ms | Segment start time in milliseconds. |
transcript_segments[].end_ms | Segment end time in milliseconds when available. |
transcript_segments[].text | Caption text for the segment. |
published_text | Publication date or relative publication text. |
view_count | Numeric public view count when available. |
duration_seconds | Video duration in seconds. |
thumbnail_url | Best available video thumbnail. |
tags | Public video tags when available. |
channel_id | Public creator channel identifier when available. |
channel_title | Public creator channel name when available. |
channel_url | Public creator channel URL when available. |
has_captions | Whether captions were available for the video. |
video_details_fetched | Whether the video detail request completed. |
How to use YouTube Transcript Scraper API
- Open the Actor in Apify Console.
- Add one or more direct YouTube video URLs to YouTube video URLs.
- Enter a caption language, or keep the default
English. - Start the run.
- Open the dataset to review transcript text, timestamps, and metadata.
- Export the dataset or connect it to your application, webhook, or automation.
Only direct video URLs are accepted. Channel pages, playlists, search pages, and other non-video pages are not input sources for this Actor.
Input parameters
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
video_urls | Array of strings | Yes | Example video URL | One or more direct YouTube video URLs. Duplicate URLs are processed once. |
language | String | No | English | Caption language name or code, such as English, en, or Spanish. |
proxy | Object | No | { "useApifyProxy": true } | Apify proxy configuration. Use residential proxies to avoid YouTube bot detection on datacenter IPs, for example { "useApifyProxy": true, "apifyProxyGroups": ["RESIDENTIAL"] }. |
The values provided by the user are used as supplied. The requested language takes priority over any available-language fallback. If the requested language is unavailable, the Actor keeps the video metadata and omits transcript fields rather than silently selecting another language.
Usage examples
Extract one video transcript
Use a one-item array when you need a single transcript.
{"video_urls": ["https://www.youtube.com/watch?v=7pq7jlR0R6o"],"language": "English"}
Extract several video transcripts
Submit multiple direct links to process them in the same run.
{"video_urls": ["https://www.youtube.com/watch?v=7pq7jlR0R6o", "https://www.youtube.com/watch?v=hePb00CqvP0"],"language": "English"}
Request a specific caption language
Use a language code when you need an exact language request.
{"video_urls": ["https://www.youtube.com/watch?v=7pq7jlR0R6o"],"language": "es"}
Sample output
The exact fields depend on the public information and captions available for each video at run time.
{"video_id": "7pq7jlR0R6o","title": "Avengers Endgame: Encore | Official Trailer I In Cinemas Sep 25","url": "https://www.youtube.com/watch?v=7pq7jlR0R6o","description": "Reassemble the team and relive the experience as Avengers Endgame: Encore returns in cinemas September 25.","duration_seconds": 96,"has_captions": true,"transcript_language": "English (auto-generated)","transcript_language_code": "en","transcript": "Hey Cap, you read me? Cap, it's Sam. Can you hear me?","transcript_segments": [{"start_ms": 7960,"end_ms": 10880,"text": "Hey Cap, you read me?"}]}
Transcript behavior
- Captions are matched to the requested language name or language code.
- Automatic captions are included when YouTube provides them for the requested language.
- Transcript segments include start times and end times when the source provides them.
- JSON3, WebVTT, and XML caption responses are normalized into the same segment structure.
- Videos without captions still return available public metadata.
- Private, removed, age-restricted, or temporarily unavailable videos may return fewer fields or fail to produce a dataset item.
- Null values, empty strings, and empty arrays are omitted recursively from dataset records.
Tips for best results
- Use complete public video URLs copied from YouTube.
- Use a language code such as
enwhen matching a particular language matters. - Start with one or two videos to check transcript availability before submitting a larger list.
- Keep
video_idas the stable key when joining results across runs. - Review the dataset preview because captions, counts, descriptions, and availability can change.
- Keep the requested language consistent when comparing transcripts across multiple videos.
Integrations and exports
- Google Sheets - Review transcript text, titles, and timestamp segments in a spreadsheet.
- Webhooks - Notify downstream services after a run completes.
- Make or Zapier - Send transcript records into no-code workflows.
- Apify API - Start runs and retrieve dataset items programmatically.
- AI and RAG pipelines - Load transcript text and timestamps into search, embedding, or knowledge-base workflows.
- Exports - Download JSON, CSV, Excel, XML, and other supported dataset formats.
Frequently asked questions
Does the Actor accept multiple videos?
Yes. Add multiple direct video URLs to the video_urls array. The Actor returns one dataset item per unique URL.
Does the Actor accept a channel URL or playlist URL?
No. The input is intentionally limited to direct YouTube video URLs. Add individual video links to video_urls instead.
Can I request automatic captions?
Yes. Automatic captions are returned when they are the available track for the requested language. The language label identifies automatic captions when YouTube provides that information.
What happens when a video has no transcript?
The Actor returns the public metadata that is available and omits transcript fields. A missing transcript can mean that captions are disabled, the requested language is unavailable, or YouTube did not make captions available for that request.
Can I export the results to CSV or Excel?
Yes. Apify datasets can be downloaded as CSV, Excel, JSON, XML, and other supported formats.
Can I run the Actor on a schedule?
Yes. Schedule repeated runs in Apify Console with the same list of video URLs to refresh transcript and metadata records.
Does this require a YouTube login or API key?
No. The Actor is intended for publicly available YouTube videos and captions. All requests use the unofficial InnerTube API through impit, with no po_token requirement.
How are requests sent?
Every request (the watch page, InnerTube player call, and caption download) is made by impit with Chrome browser impersonation. If you configure the proxy input, those requests share one sticky residential proxy session so YouTube sees a consistent IP while validating the caption URL. Failed requests rotate to a new session before retrying.
Is collecting YouTube data legal?
You are responsible for complying with YouTube's terms, applicable laws, copyright rules, and privacy requirements. Collect and use public data responsibly.
Related Actors
No additional related Actor links are listed because another relevant public Actor under the Shahid Irfan profile could not be verified while preparing this README. This avoids publishing guessed or incorrect links.
Support
For issues or feature requests, use the Issues tab on the Actor page or contact the developer through Apify.
Legal notice
This Actor is intended for legitimate collection of publicly available information. Users are responsible for complying with YouTube's terms of service, applicable laws, copyright obligations, and privacy rules.