# YouTube Transcript Scraper - Subtitles, SRT & RAG (`zenomastro/youtube-transcript-reliable`) Actor

Get YouTube transcripts from video, Shorts, channel, playlist or search URLs. Returns clean text, timed segments, SRT/VTT and RAG-ready chunks in any caption language, with optional translation. Built for summaries, RAG and AI agents.

- **URL**: https://apify.com/zenomastro/youtube-transcript-reliable.md
- **Developed by:** [Rosario Vitale](https://apify.com/zenomastro) (community)
- **Categories:** Videos, AI, Developer tools
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $3.00 / 1,000 successful transcripts

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

### Why use this Actor?

Get YouTube transcripts from video, Shorts, channel, playlist or search URLs. Returns clean text, timed segments, SRT/VTT and RAG-ready chunks in any caption language, with optional translation. Built for summaries, RAG and AI agents.

### Features

- **YouTube URLs or video IDs** — YouTube video links or 11-character video IDs, one per line. Watch, youtu.be, Shorts, Live and Embed links all work, e.g. https://www.youtube.com/watch?v=dQw4w9WgXcQ. Up to 500 per run. Can be combined with channel, playlist and search sources below.
- **Channel, playlist or search URLs** — Get transcripts of the videos in a YouTube channel (e.g. https://www.youtube.com/@mkbhd or /@mkbhd/videos), playlist (https://www.youtube.com/playlist?list=...) or search-results page (filters you set on youtube.com are kept). Channels are read newest first, playlists in playlist order, up to Maximum videos from channels, playlists and searches. Shortcuts work too: @handle, a channel ID (UC...) or plain keywords (read as a search).
- **Search keywords** — Search YouTube for these keywords, one search per line (e.g. sourdough bread recipe), and get the transcripts of the top video results, like searching on youtube.com with the Videos filter.
- **Maximum videos from channels, playlists and searches** — Total cap on videos taken from Channel, playlist or search URLs and Search keywords in one run (videos you list directly are not counted). Use Maximum videos per source below to spread it over several sources.
- **Preferred languages** — Caption languages in order of preference, as codes such as en, es, it, pt, de, fr, ja. When a video has no exact match, a regional variant is used (en finds en-GB or en-US, pt finds pt-BR). Human-made captions are preferred over auto-generated ones unless you change it under Language options.
- **Translate transcript to** — Optional language code (e.g. en, es, fr, de, it, pt) to get every transcript in that language using YouTube's own auto-translation, when YouTube offers it for the video. If YouTube refuses, you get the original transcript (not charged) with translationError explaining why. Leave empty for no translation.
- **Fallback to any available language** — If the video has none of your preferred languages, return a transcript in another available language instead of an error row. availableTranscripts always lists every language the video has.
- **Prefer auto-generated captions** — Prefer YouTube's automatic (speech recognition) captions over human-made captions when both exist in your language.
- **Include timestamped segments** — Include every caption line with its start time and duration in seconds (segments).
- **Include timestamped text** — Add timestampedText: plain text with one "\[mm:ss] text" line per caption ("\[hh:mm:ss]" for videos of an hour or more). Easy to paste into ChatGPT or a document and cite by time.
- **Timestamp every N seconds** — With timestamped text, group captions into one line every N seconds (for example 30). 0 = one line per caption.
- **Include readable paragraphs** — Group captions into paragraph-sized blocks, each with start/end time and a link that opens the video at that moment.

### Use cases

- Video-to-text pipelines.
- Rag and embeddings.
- Subtitle export.
- Content research and summarization.

### Related tools

- [YouTube Comments Scraper API](https://apify.com/zenomastro/youtube-comments-reliable)
- [Audio & Video to Text - Whisper Transcription API](https://apify.com/zenomastro/audio-video-to-text)
- [Image to Text OCR - Extract Text from Images & PDFs](https://apify.com/zenomastro/image-ocr-text-extractor)

### Example input

```json
{
  "maxDiscoveredVideos": 100,
  "languages": [
    "en"
  ],
  "fallbackToAnyLanguage": true,
  "preferAutoGenerated": false,
  "includeSegments": true,
  "includeTimestampedText": false
}
```

### Pricing & cost control

The primary event costs **$0.003750 per Successful transcript** (about **$3.75 per 1,000** successful primary events).
Only successful primary events are intentionally billed by this Actor; summary/status rows add context without adding primary-event charges.

Use the bounded input limits and filters to keep both event charges and platform usage predictable.

### FAQ

**What is this Actor for?**\
It is designed for video-to-text pipelines, RAG and embeddings, subtitle export.

**Can I run it on a schedule?**\
Yes. You can schedule Actor runs on Apify and send the resulting dataset into automations, webhooks, storage, or downstream APIs.

**How do I control cost and run size?**\
Use the input limits and filters shown in the Actor input form. The Actor applies bounded defaults and hard caps so large jobs remain predictable.

### Pricing at a glance

| | Price per 1,000 transcripts |
|---|---:|
| **This Actor** | **$3.75** |
| Comparable Actor with 3,800+ monthly users (price checked November 2026) | $5.00 |

That is **25% below that comparable Actor** for this task in Apify Store.

**Paid Apify plans pay less per result:** Bronze $3.40, Silver $3.20, Gold and higher **$3.00** per 1,000 transcripts.

**Apify platform usage (compute, storage, data transfer) is included** — you pay only the result price plus a small run start fee ($0.0001 per GB of run memory). No surprise compute bill, even on long runs.

Use the run's *maximum charge* setting to cap spending — the Actor stops cleanly when the limit is reached.

### Use it from AI agents (MCP) and code

**AI agents** — Claude, ChatGPT, Cursor, VS Code, n8n AI agents and any MCP client can run this Actor through the official Apify MCP server: add `https://mcp.apify.com?tools=zenomastro/youtube-transcript-reliable` to your client. Then just ask, for example:

> *"Get the transcript of this YouTube video in English as clean text and as SRT subtitles."*

The agent fills the input from the field descriptions and receives clean JSON it can reason over.

**API** — one HTTP call runs the Actor and returns the results directly:

```bash
curl -X POST "https://api.apify.com/v2/acts/zenomastro~youtube-transcript-reliable/run-sync-get-dataset-items?token=YOUR_APIFY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"videoUrls": ["https://www.youtube.com/watch?v=dQw4w9WgXcQ"], "languages": ["en"], "fallbackToAnyLanguage": true, "includeSegments": false, "includeMetadata": false, "includeParagraphs": true, "includeChunks": true, "retries": 1}'
```

The same works from the Apify Python/JavaScript clients, Make, n8n, Zapier, LangChain and LlamaIndex integrations, or on a schedule.

### What this YouTube transcript scraper does

Paste YouTube video links, a channel, a playlist or a few search keywords, and get every video's transcript as clean text, plus timed segments, readable paragraphs, chapters, SRT/WebVTT subtitles and RAG chunks, together with the video's metadata. It reads the captions YouTube already has (human-made or auto-generated, in any language the video offers), so no YouTube API key and no login are needed.

Who it is for:

- **AI and RAG builders**: chunks carry their start and end time and a link that opens the video at that moment, so answers can cite the exact second.
- **Researchers, marketers and students**: turn a whole channel, playlist or search into text, or into one Markdown file you can upload to ChatGPT, Claude or NotebookLM.
- **Video editors and translators**: SRT and WebVTT subtitles, and YouTube's own auto-translation into another language.
- **Monitoring**: scheduled runs that return only new or changed transcripts.

### How to use it

1. Add video links to **YouTube URLs or video IDs**, channel/playlist/search links to **Channel, playlist or search URLs**, or keywords to **Search keywords**. You can combine all three.
2. Set **Preferred languages** (for example `en`). To get every transcript in one language, also set **Translate transcript to**.
3. Choose the extra formats you need under **Output formats** (plain text is always included) and click **Start**.
4. Open the **Output** tab: the results table, the "Videos & metadata" table, the full JSON, and **transcripts.md** with all transcripts in one readable file.

### Input examples

One video, with a timestamped line every 30 seconds (handy for ChatGPT):

```json
{
  "videoUrls": ["https://www.youtube.com/watch?v=dQw4w9WgXcQ"],
  "languages": ["en"],
  "includeTimestampedText": true,
  "timestampEverySeconds": 30
}
```

The 20 newest videos of a channel as RAG chunks for a vector database:

```json
{
  "sourceUrls": ["https://www.youtube.com/@mkbhd/videos"],
  "maxDiscoveredVideos": 20,
  "includeSegments": false,
  "includeChunks": true,
  "chunkSizeChars": 2000,
  "chunkOverlapChars": 200,
  "removeSoundTags": true
}
```

Up to 10 top videos for each of three searches, keeping those published in the last 6 months:

```json
{
  "searchQueries": ["sourdough bread recipe", "sourdough starter", "no knead bread"],
  "maxVideosPerSource": 10,
  "maxDiscoveredVideos": 30,
  "publishedAfter": "6 months"
}
```

Spanish SRT subtitles for an English video:

```json
{
  "videoUrls": ["https://youtu.be/dQw4w9WgXcQ"],
  "languages": ["en"],
  "translateTo": "es",
  "includeSrt": true
}
```

A daily schedule that returns only the channel's new videos:

```json
{
  "sourceUrls": ["https://www.youtube.com/@RickAstleyYT/videos"],
  "maxDiscoveredVideos": 15,
  "monitorName": "rick-astley-daily",
  "onlyChanged": true
}
```

### Output

Every video gives one row. A successful transcript looks like this (shortened; values are illustrative):

```json
{
  "recordType": "transcript",
  "videoId": "dQw4w9WgXcQ",
  "url": "https://www.youtube.com/watch?v=dQw4w9WgXcQ",
  "success": true,
  "language": "English",
  "languageCode": "en",
  "isGenerated": false,
  "translatedTo": "",
  "fullText": "We're no strangers to love You know the rules and so do I ...",
  "segmentCount": 61,
  "segments": [{ "text": "We're no strangers to love", "start": 18.6, "duration": 3.2 }],
  "paragraphs": [{ "start": 18.6, "end": 95.1, "text": "We're no strangers to love ...", "url": "https://www.youtube.com/watch?v=dQw4w9WgXcQ&t=18s" }],
  "chapters": [],
  "chunks": [{ "index": 0, "text": "We're no strangers to love ...", "start": 18.6, "end": 95.1, "startTimestamp": "00:18", "url": "https://www.youtube.com/watch?v=dQw4w9WgXcQ&t=18s", "startChar": 0, "endChar": 1980, "chunkId": "5f0c...", "wordCount": 371, "estimatedTokens": 495 }],
  "metadata": {
    "title": "Rick Astley - Never Gonna Give You Up (Official Video)",
    "channel": "Rick Astley",
    "channelHandle": "@RickAstleyYT",
    "publishedAt": "2009-10-24T23:57:33-07:00",
    "durationSeconds": 213,
    "viewCount": 1700000000,
    "likeCount": 18700000,
    "commentCount": 2400000,
    "channelSubscriberCount": 4310000,
    "thumbnailUrl": "https://i.ytimg.com/vi/dQw4w9WgXcQ/maxresdefault.jpg"
  },
  "availableTranscripts": [{ "language": "English", "languageCode": "en", "isGenerated": false, "isTranslatable": true }],
  "wordCount": 487,
  "estimatedTokens": 640,
  "sha256": "3b1f..."
}
```

A video that cannot be transcribed gives an error row instead. Error rows are never charged, say why the video failed and whether a later run may succeed (`retryable`):

```json
{
  "recordType": "error",
  "videoId": "abcdefghijk",
  "url": "https://www.youtube.com/watch?v=abcdefghijk",
  "success": false,
  "errorType": "TranscriptsDisabled",
  "error": "This video has no captions (subtitles are turned off or were never added), so there is no transcript.",
  "retryable": false,
  "metadata": { "title": "Some video without captions", "channel": "Some channel" }
}
```

When none of your languages exist and fallback is off, the error row also lists the video's `availableTranscripts`, so you can see which language codes to ask for. Runs that read channels, playlists or searches end with a free `discovery_summary` row (videos found per source), and monitor runs with a `monitor_summary` row.

### All transcripts in one file (transcripts.md)

With **Save all transcripts in one file** (on by default, free), the run also saves `transcripts.md` in its key-value store, linked from the Output tab. It has a table of contents and, for each video, the title, link, channel, publish date, duration and language, then the transcript as paragraphs with `[mm:ss]` timestamps, grouped under the video's chapters when it has them. Upload it to ChatGPT, Claude or NotebookLM to ask questions across a whole channel. Very large runs are split into `transcripts.md`, `transcripts-2.md` and so on.

### Languages and translation

- **Preferred languages** are tried in order. Human-made captions are preferred over auto-generated ones; turn on **Prefer auto-generated captions** to reverse that.
- If a video has no exact match, a regional variant of the same language is used (`en` finds `en-GB` or `en-US`, `pt` finds `pt-BR`), before any other language.
- With **Fallback to any available language** (on by default) a video without your languages still returns its best available transcript; turn it off to get an error row instead.
- **Translate transcript to** uses YouTube's own auto-translation. When YouTube refuses a translation, you get the original transcript (not charged) and `translationError` says why.
- **Remove sound tags** deletes `[Music]`, `[Applause]` and similar notes from every output.

### Channels, playlists and search

- Channel URLs are read newest first. A channel URL without a tab reads the Videos, Live and Shorts tabs; pick tabs with **Channel tabs to include** or use a tab URL such as `/@name/shorts`.
- **Maximum videos from channels, playlists and searches** caps the total; **Maximum videos per source** caps each source, e.g. the 5 newest videos of each of 10 channels.
- **Published on or after / before** accept dates (`2026-09-01`) or relative values (`30 days`, `6 months`). Videos outside the window are skipped and not charged.
- **Search keywords** return the top video results, like youtube.com with the Videos filter. For YouTube's own filters (upload date, duration, sort), apply them on youtube.com and paste the results URL into **Channel, playlist or search URLs**.
- Shortcuts are accepted in the URL list: `@handle`, a channel ID (`UC...`) or plain keywords.

### Reliability

- One bad video never fails the run: it gets an uncharged error row with a clear reason (no captions, private, members-only, age-restricted, blocked) and the run continues.
- Temporary problems are retried with backoff and a fresh proxy session; every request has a timeout.
- Blocks are handled automatically: a blocked video is retried at once from other IP addresses (Apify Proxy and the run's own address), and the run learns which of the two works better and uses it first for the next videos.
- Apify Proxy (datacenter) is on by default because YouTube often blocks cloud servers. Your own proxy URLs (for example residential) also work and are then always used.
- The run stops cleanly, keeping all results, before your maximum charge and before the run timeout, and the status message says how many videos were not processed.
- Video metadata is read from the page the transcript request already loads, so it usually costs no extra request, and a metadata problem never costs you the transcript (`metadataError` explains it).

### What is charged

You pay only for successful transcript rows, one per video (see Pricing at a glance above and the Pricing tab). These are free: error rows, videos skipped by the date window, unchanged transcripts in monitor mode, transcripts returned untranslated because YouTube refused the translation, the summary rows and the transcripts.md file.

### Limits

- Up to 500 videos per run (listed and discovered together) and up to 50 channel, playlist or search sources.
- Only videos with captions (human-made or auto-generated) have a transcript; this Actor does not transcribe audio. For videos without captions, use [Audio & Video to Text](https://apify.com/zenomastro/audio-video-to-text).
- Private, members-only, age-restricted and region-locked videos cannot be read, because the Actor does not log in.
- Likes, comment count and subscribers are read as YouTube shows them on the video page: they can be rounded (for example 2.4M) or missing (null).
- One dataset row can hold up to 9 MB. For very long videos with every format turned on, turn off segments, SRT or VTT if a `SaveFailed` row appears.

Use transcripts in accordance with applicable copyright, privacy and platform rules.

### Troubleshooting and FAQ

**Why did a video fail?**
Read `error` and `errorType` on its row. `retryable: true` (for example `IpBlocked`, `RequestBlocked` or a timeout) means running the same video again later may work; `retryable: false` (for example `TranscriptsDisabled` or `VideoUnavailable`) means it will not without changing the input.

**Can I get a transcript in a language the video does not have?**
Yes, when YouTube offers auto-translation for that video: set **Translate transcript to**. `translatedTo` confirms the translation and `sourceLanguageCode` shows the original language.

**How do I get only the plain text?**
`fullText` is always included. Turn off timestamped segments and paragraphs to keep rows small.

**How do I download everything at once?**
Download `transcripts.md` from the Output tab, or export the dataset as JSON, CSV or Excel.

**Does it work with Shorts and live streams?**
Yes, Shorts, Live and past live-stream URLs work when the video has captions.

**Can I run it on a schedule and get only what is new?**
Yes: set a **Transcript monitor name** and turn on **Emit only new or changed transcripts**, then schedule the run or task.

### Support

For a reproducible issue, open an issue with the public video URL, your language settings, whether a proxy was enabled, and the run ID. Never post private proxy credentials or API tokens in an issue.

### Extended capabilities

- Accept direct video IDs/URLs or discover videos from playlists, channels, handles, search-result pages, and other supported YouTube source URLs.
- Fetch transcript segments with language controls and optional proxy fallback.
- Produce text, paragraphs, RAG chunks, SRT, VTT, metadata, hashes, and persistent transcript-change monitoring.

# Changelog

This Actor's version history is a separate document: https://apify.com/zenomastro/youtube-transcript-reliable/changelog.md

# Actor input Schema

## `videoUrls` (type: `array`):

YouTube video links or 11-character video IDs, one per line. Watch, youtu.be, Shorts, Live and Embed links all work, e.g. https://www.youtube.com/watch?v=dQw4w9WgXcQ. Up to 500 per run. Can be combined with channel, playlist and search sources below.

## `sourceUrls` (type: `array`):

Get transcripts of the videos in a YouTube channel (e.g. https://www.youtube.com/@mkbhd or /@mkbhd/videos), playlist (https://www.youtube.com/playlist?list=...) or search-results page (filters you set on youtube.com are kept). Channels are read newest first, playlists in playlist order, up to Maximum videos from channels, playlists and searches. Shortcuts work too: @handle, a channel ID (UC...) or plain keywords (read as a search).

## `searchQueries` (type: `array`):

Search YouTube for these keywords, one search per line (e.g. sourdough bread recipe), and get the transcripts of the top video results, like searching on youtube.com with the Videos filter.

## `maxDiscoveredVideos` (type: `integer`):

Total cap on videos taken from Channel, playlist or search URLs and Search keywords in one run (videos you list directly are not counted). Use Maximum videos per source below to spread it over several sources.

## `languages` (type: `array`):

Caption languages in order of preference, as codes such as en, es, it, pt, de, fr, ja. When a video has no exact match, a regional variant is used (en finds en-GB or en-US, pt finds pt-BR). Human-made captions are preferred over auto-generated ones unless you change it under Language options.

## `translateTo` (type: `string`):

Optional language code (e.g. en, es, fr, de, it, pt) to get every transcript in that language using YouTube's own auto-translation, when YouTube offers it for the video. If YouTube refuses, you get the original transcript (not charged) with translationError explaining why. Leave empty for no translation.

## `fallbackToAnyLanguage` (type: `boolean`):

If the video has none of your preferred languages, return a transcript in another available language instead of an error row. availableTranscripts always lists every language the video has.

## `preferAutoGenerated` (type: `boolean`):

Prefer YouTube's automatic (speech recognition) captions over human-made captions when both exist in your language.

## `includeSegments` (type: `boolean`):

Include every caption line with its start time and duration in seconds (segments).

## `includeTimestampedText` (type: `boolean`):

Add timestampedText: plain text with one "\[mm:ss] text" line per caption ("\[hh:mm:ss]" for videos of an hour or more). Easy to paste into ChatGPT or a document and cite by time.

## `timestampEverySeconds` (type: `integer`):

With timestamped text, group captions into one line every N seconds (for example 30). 0 = one line per caption.

## `includeParagraphs` (type: `boolean`):

Group captions into paragraph-sized blocks, each with start/end time and a link that opens the video at that moment.

## `paragraphMaxChars` (type: `integer`):

Approximate maximum characters per paragraph.

## `includeChapters` (type: `boolean`):

Split the transcript into the video's chapters (title, start, end, text and a link to the chapter) when the creator added chapter timestamps to the description. Videos without chapters return an empty list.

## `includeSrt` (type: `boolean`):

Return the transcript as an SRT subtitle string (srt).

## `includeVtt` (type: `boolean`):

Return the transcript as a WebVTT subtitle string (vtt).

## `includeChunks` (type: `boolean`):

Split the text into overlapping chunks for embeddings and vector databases. Each chunk has its start/end time and a link that opens the video at that moment, so AI answers can cite the exact moment.

## `chunkSizeChars` (type: `integer`):

Approximate maximum characters per chunk (about 4 characters per token).

## `chunkOverlapChars` (type: `integer`):

Characters repeated between consecutive chunks, so no sentence is lost at a boundary.

## `removeSoundTags` (type: `boolean`):

Remove sound descriptions in square brackets (\[Music], \[Applause], \[Laughter]) and music notes from every output, for cleaner text for AI and reading.

## `preserveFormatting` (type: `boolean`):

Keep YouTube's caption HTML formatting tags (such as <i> and <b>) where the captions have them.

## `saveCombinedFile` (type: `boolean`):

Also save every transcript of the run in one readable Markdown file (transcripts.md, linked in the Output tab), with titles, links, chapters and \[mm:ss] timestamps. Ready to upload to ChatGPT, Claude or NotebookLM. Free.

## `includeMetadata` (type: `boolean`):

Add title, channel, channel handle, subscribers, description, keywords, thumbnail, duration, views, likes, comment count and publish date when YouTube shows them. Read from the page the transcript request already loads, so it usually adds no extra request.

## `maxVideosPerSource` (type: `integer`):

Cap for each channel, playlist or search, e.g. 10 = the 10 newest videos of every channel. 0 = no per-source cap (only the total maximum applies, so the first source can use it all).

## `sourceContentTypes` (type: `array`):

For channel URLs without a tab (for example https://www.youtube.com/@name), which tabs to read: videos, shorts and/or live streams. Empty = all tabs (videos first, then live streams, then Shorts). Playlist, search and tab URLs such as /@name/videos are read as given.

## `publishedAfter` (type: `string`):

Only videos from channels, playlists and searches published on or after this date: YYYY-MM-DD (for example 2026-09-01) or a relative value such as "30 days", "2 weeks" or "6 months" (counted back from today, UTC). Videos outside the window are skipped and not charged. Videos in videoUrls are always processed.

## `publishedBefore` (type: `string`):

Only videos from channels, playlists and searches published on or before this date: YYYY-MM-DD or a relative value such as "7 days". Leave empty for no upper limit.

## `monitorName` (type: `string`):

Give scheduled runs the same name (e.g. my-channel-monitor) to remember transcripts between runs: every row then says whether its text changed since the last run (changed, previousSha256).

## `onlyChanged` (type: `boolean`):

With a monitor name, skip (and do not charge) transcripts whose text is identical to the previous run. New videos are always emitted, so a channel schedule returns only what is new.

## `requestTimeoutSecs` (type: `integer`):

Maximum time for one transcript attempt.

## `retries` (type: `integer`):

Retry temporary failures (timeouts, network errors) with backoff and a fresh proxy session. A video YouTube blocks is retried right away from other IP addresses, at least 5 times unless this is 0. Failed videos are never charged.

## `proxyConfiguration` (type: `object`):

Apify Proxy (datacenter) is on by default because YouTube often blocks cloud servers; when it is blocked, the run also tries its own IP address. Your own proxy URLs (for example residential) are always used as given.

## Actor input object example

```json
{
  "videoUrls": [
    "https://www.youtube.com/watch?v=dQw4w9WgXcQ"
  ],
  "sourceUrls": [],
  "searchQueries": [],
  "maxDiscoveredVideos": 100,
  "languages": [
    "en"
  ],
  "translateTo": "",
  "fallbackToAnyLanguage": true,
  "preferAutoGenerated": false,
  "includeSegments": true,
  "includeTimestampedText": false,
  "timestampEverySeconds": 0,
  "includeParagraphs": true,
  "paragraphMaxChars": 1200,
  "includeChapters": true,
  "includeSrt": false,
  "includeVtt": false,
  "includeChunks": false,
  "chunkSizeChars": 6000,
  "chunkOverlapChars": 500,
  "removeSoundTags": false,
  "preserveFormatting": false,
  "saveCombinedFile": true,
  "includeMetadata": true,
  "maxVideosPerSource": 0,
  "sourceContentTypes": [],
  "monitorName": "",
  "onlyChanged": false,
  "requestTimeoutSecs": 25,
  "retries": 2,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}
```

# Actor output Schema

## `overview` (type: `string`):

Main fields of every result, ready to preview or export as CSV, Excel or JSON.

## `transcriptsFile` (type: `string`):

Every transcript of the run in one readable file with titles, links, chapters and timestamps, ready for ChatGPT, Claude or NotebookLM. Saved when "Save all transcripts in one file" is on (default).

## `videos` (type: `string`):

Title, channel, publish date, duration, views, likes, comments and transcript language of every video.

## `results` (type: `string`):

Every result with all fields, for APIs, AI agents and integrations.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "videoUrls": [
        "https://www.youtube.com/watch?v=dQw4w9WgXcQ"
    ],
    "languages": [
        "en"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("zenomastro/youtube-transcript-reliable").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "videoUrls": ["https://www.youtube.com/watch?v=dQw4w9WgXcQ"],
    "languages": ["en"],
}

# Run the Actor and wait for it to finish
run = client.actor("zenomastro/youtube-transcript-reliable").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "videoUrls": [
    "https://www.youtube.com/watch?v=dQw4w9WgXcQ"
  ],
  "languages": [
    "en"
  ]
}' |
apify call zenomastro/youtube-transcript-reliable --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,zenomastro/youtube-transcript-reliable"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/n1McARqABW40ReKd4/builds/obhwqAkGMjuBfk1Cc/openapi.json
