# $4/1K | YouTube Transcript Scraper - Captions to Text (`scrapercompany/youtube-transcript-scraper`) Actor

Get YouTube video transcripts: timed caption segments and the full text, in any caption language the video has, from a video id or link. Batch videos for summaries, research, search and AI. No login. Pay only when a video has captions. Made by ScraperCompany.

- **URL**: https://apify.com/scrapercompany/youtube-transcript-scraper.md
- **Developed by:** [ScraperCompany](https://apify.com/scrapercompany) (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 $4.00 / 1,000 youtube transcripts

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

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

## YouTube Transcript Scraper - Captions & Subtitles to Text

**YouTube Transcript Scraper** by ScraperCompany reads a YouTube video's captions and returns them as **timed segments** (start, duration, text) and as **one joined text**, with the **video title, channel and length** and **every caption language the video offers**.

### ⭐ Like this Actor? Leave a review

If YouTube Transcript Scraper saved you time, please [leave a review on the Store](https://apify.com/scrapercompany/youtube-transcript-scraper/reviews). It takes a minute, helps other people find a scraper that works, and tells us what to build next.

> 🟢 **Nothing to set up:** no code, no login and no keys. Click **Try for free**, start a run, and export JSON, CSV or Excel, or pull the results through the Apify API. You pay only for results; failed and empty requests are free.

### 📦 What you get

| What you get | Price | Per 1,000 |
| --- | --- | --- |
| A video's captions as timed segments and joined text, in a chosen language, plus every caption language available | $0.004 | $4.00 |

- 💵 **Price:** **$4 per 1,000** `transcript` events ($0.004 each); failed and empty requests are free.
- ⚙️ **Setup:** none. No account on the site, no cookies, no keys.
- 📁 **Export:** JSON, CSV, Excel or HTML from the **Output** tab, or the Apify API.
- 🔁 **Automate:** schedules, webhooks, Make, Zapier, n8n and AI agents (MCP).

### ✨ What can this YouTube transcript scraper do?

Pick a language or take the default track. No login. Pricing is pay-per-event: **$0.004 per video with captions**; videos without captions and failed requests are free.

- Paste **video ids or any YouTube link** (watch, youtu.be, Shorts, live).
- **Timed segments** with start and duration in seconds, plus the **full text** in one field.
- Choose the **caption language** (e.g. en, es, pt-BR); every row lists the languages available.
- Manual and auto-generated captions; the row says which.
- Batch any number of videos. Videos without captions are free.

### 🚀 Quick start: how to scrape YouTube transcripts

1. Click **Try for free** (or open the Actor in Apify Console) and go to the **Input** tab.
2. Enter **Videos**, one per line: a video id (<code>8jPQjjsBbIc</code>) or a YouTube link. Optionally pick a caption language.
3. Adjust the options if needed.
4. Click **Start** and wait for the run to finish.
5. Download the results from the **Output** tab as JSON, CSV, Excel or HTML, or fetch them with the Apify API.

💡 **Tip:** run it once with the pre-filled input to see the output, then change the input to your own.

### ⚖️ What makes it different?

| | **YouTube Transcript Scraper** | Many alternatives |
| --- | --- | --- |
| Setup | Nothing to configure: no login, no keys | Often your own accounts, cookies or network setup |
| You pay for | Successful results; failed and empty requests are free | Often run time, or every attempt |
| When a request fails | Retried automatically, and never charged | Often an empty or failed run |

### 👥 Who uses YouTube transcript data?

- **AI and RAG builders**: Feed video transcripts to summarizers, chatbots and search indexes.
- **Researchers and journalists**: Quote and search what was said in talks, interviews and news clips.
- **Content and SEO teams**: Turn videos into articles, show notes and subtitles.

### 🧭 Common jobs

#### Transcripts for a playlist

Paste the playlist's video links, one per line.

#### Spanish captions only

Set Caption language to es.

### 📋 What YouTube transcript data can you extract?

| Field | Description |
| --- | --- |
| `video.video_id / title / author / channel_id / length_seconds` | The video |
| `language.code / name / kind` | The caption track returned (manual or auto-generated) |
| `segments[].start_s / duration_s / text` | Timed caption segments |
| `text` | The whole transcript as one text |
| `available_languages[]` | Every caption language the video has |

Every dataset item also carries `input` (the options used for that request), `request_id` (quote it to support), `billed` and `scraped_at`.

### ⌨️ Input

| Input | Name | What it does |
| --- | --- | --- |
| `videos` | Videos | ?.be/`, `/shorts/`, `/live/`). Each line is one request. |
| `lang`| Caption language | .g.`en`, `es`, `pt-BR`. Leave empty for the video's default track. Every row lists the languages the video has. |
| `hl`| Interface language | .g.`en`. |
| `gl`| Country | .g.`US\`. |

### 📥 Input example

This is the default input; running the Actor without changes uses it.

```json
{
  "videos": [
    "https://www.youtube.com/watch?v=8jPQjjsBbIc"
  ],
  "includeErrors": true,
  "maxConcurrency": 3,
  "maxRetries": 2
}
```

### 📤 Output example

One dataset item per request (trimmed here; real items contain all the fields):

```json
{
  "input": {
    "video_id": "8jPQjjsBbIc"
  },
  "available_languages": [
    {
      "code": "ar",
      "is_default": false,
      "kind": "manual",
      "name": "Arabic",
      "translatable": true
    },
    {
      "code": "en",
      "is_default": true,
      "kind": "manual",
      "name": "English",
      "translatable": true
    }
  ],
  "language": {
    "code": "en",
    "is_default": true,
    "kind": "manual",
    "name": "English",
    "translatable": true
  },
  "search_parameters": {
    "gl": "US",
    "hl": "en",
    "video_id": "8jPQjjsBbIc"
  },
  "segments": [
    {
      "duration_s": 2.56,
      "start_s": 13.24,
      "text": "A few years ago, I broke into my own house."
    },
    {
      "duration_s": 1.216,
      "start_s": 16.88,
      "text": "I had just driven home,"
    }
  ],
  "text": "A few years ago, I broke into my own house. I had just driven home, it was around midnight in the dead of Montreal winter,",
  "video": {
    "author": "TED",
    "channel_id": "UCAuUUnT6oDeKwE6v1NGQxug",
    "length_seconds": 740,
    "title": "How to stay calm when you know you'll be stressed | Daniel Levitin | TED",
    "video_id": "8jPQjjsBbIc"
  },
  "request_id": "req_3f9c0d6e2b8a4c1f9e7d5b3a1c0e8f6d",
  "billed": true,
  "scraped_at": "2026-10-01T14:03:27.512Z"
}
```

A request that fails is saved with an `error` message instead (turn off **Include failed requests** to skip those). Failed requests are never charged.

### 💰 How much does it cost to scrape YouTube transcripts?

This Actor uses **pay-per-event** pricing: you pay for successful requests, not for compute time.

| Event | Charged when | Price | Per 1,000 |
| --- | --- | --- | --- |
| `transcript` | One video's captions as timed segments plus the joined text. Videos without captions are free. | $0.004 | $4.00 |

The **$4/1K** in the title is the price of 1,000 `transcript` events.

#### Cost examples

| Job | Cost |
| --- | --- |
| 100 videos, once | **$0.40** |
| 1,000 videos | **$4.00** |

Apify's $5 of free monthly usage covers about **1,250** `transcript` events.

- ✅ Failed requests (errors, invalid input, a site refusing after retries) are **free**.
- ✅ Requests where the source returns nothing at all (no results, nothing priced) are saved but **not charged**.
- ✅ Set **Maximum cost per run** when you start a run and the Actor stops cleanly before going over it.

### 🔌 Integrations

#### ⏰ Schedules and webhooks

Use Apify **Schedules** to repeat a run hourly, daily or weekly and compare results over time, and **webhooks** or the **Integrations** tab to push new results to Make, Zapier, n8n, Google Sheets, Slack or your own warehouse.

#### 🤖 AI agents and MCP

Results are structured JSON, so they are easy to feed to a model. AI agents such as Claude can run this Actor and read its results through the [Apify MCP server](https://mcp.apify.com).

#### 💻 API: JavaScript and Python

Call the Actor from any language through the [Apify API](https://docs.apify.com/api/v2). With the JavaScript client (`npm install apify-client`):

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

const client = new ApifyClient({ token: process.env.APIFY_TOKEN });
const run = await client.actor('scrapercompany/youtube-transcript-scraper').call({
    "videos": [
        "https://www.youtube.com/watch?v=8jPQjjsBbIc"
    ]
});
const { items } = await client.dataset(run.defaultDatasetId).listItems();
console.log(items);
```

With Python (`pip install apify-client`):

```python
import os
from apify_client import ApifyClient

client = ApifyClient(os.environ["APIFY_TOKEN"])
run = client.actor("scrapercompany/youtube-transcript-scraper").call(run_input={
    "videos": ["https://www.youtube.com/watch?v=8jPQjjsBbIc"],
})
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item)
```

### ❓ FAQ

#### Do I need an account on the site, or an API key?

No. The Actor is ready to run as is, and you only pay the per-event prices above.

#### What if a video has no captions?

It is not charged; the row says no captions were found.

#### Can I get a translation?

Pick any language listed in available_languages; YouTube translates when the track is marked translatable.

#### Do I need a YouTube account or API key?

No.

#### Is it legal to scrape YouTube transcripts?

The Actor collects publicly available information that anyone can see without logging in. You are responsible for how you use the results: respect the source site's terms, copyright and privacy law (such as GDPR) and do not collect personal data without a lawful basis. If in doubt, ask a lawyer.

#### What happens when a request fails?

Failed attempts are retried automatically. If a request still fails it is saved with the error message and not charged, and the rest of the batch keeps going. A run only fails when every request failed.

#### Why did a request return an error?

Read the `error` field: it says what was wrong with the input, for example a malformed date or an unknown id. Fix it and run again; failed requests cost nothing.

#### How many requests can I run at once?

Any number per run. The Actor sends up to 3 requests in parallel by default (change it under **Run options**); larger batches simply take longer.

### 🔗 Related scrapers

- [YouTube Scraper](https://apify.com/scrapercompany/youtube-scraper): search, video details, comments, channels and playlists
- [TikTok Scraper](https://apify.com/scrapercompany/tiktok-scraper): profiles, videos and hashtags
- [Google Search Scraper](https://apify.com/scrapercompany/google-search-scraper): organic results and SERP features

### 📝 Tried it? Tell others

Once you have run YouTube Transcript Scraper, a [short review on the Store](https://apify.com/scrapercompany/youtube-transcript-scraper/reviews) helps the next person decide.

### 💬 Support

Questions, a field you need, or a site that stopped working? Open an issue on the **Issues** tab. Include the `request_id` from the dataset item so we can trace the request. We read every issue.

# Changelog

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

# Actor input Schema

## `videos` (type: `array`):

One video per line: the 11-character id (<code>8jPQjjsBbIc</code>) or any YouTube video link (<code>watch?v=</code>, <code>youtu.be/</code>, <code>/shorts/</code>, <code>/live/</code>). Each line is one request.

## `lang` (type: `string`):

Language code of the captions to read, e.g. <code>en</code>, <code>es</code>, <code>pt-BR</code>. Leave empty for the video's default track. Every row lists the languages the video has.

## `hl` (type: `string`):

YouTube interface language for video titles, e.g. <code>en</code>.

## `gl` (type: `string`):

Two-letter country YouTube answers for, e.g. <code>US</code>.

## `customRequests` (type: `array`):

Optional list of JSON objects, one request each, using the field names shown above. Each object is merged over the options above, so you only need to give what differs. Example: <code>{"video_id":"arj7oStGLkU","lang":"es"}</code>

## `includeErrors` (type: `boolean`):

When on, a request that fails (for example an unknown property id) is saved as a dataset item with an <code>error</code> message so you can see what went wrong. Failed requests are never charged.

## `maxConcurrency` (type: `integer`):

How many requests run at the same time (1-8). Parallel runs share one limit, so extra requests wait for a free slot instead of failing.

## `maxRetries` (type: `integer`):

How many times a request that failed for a temporary reason is tried again right away. A request still failing then gets one more try at the end of the run, after a 30-second pause. Invalid input is never retried.

## Actor input object example

```json
{
  "videos": [
    "https://www.youtube.com/watch?v=8jPQjjsBbIc"
  ],
  "hl": "en",
  "gl": "US",
  "includeErrors": true,
  "maxConcurrency": 3,
  "maxRetries": 2
}
```

# Actor output Schema

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

One dataset item per request.

## `summary` (type: `string`):

Counts of succeeded, failed, skipped and charged requests.

# 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 = {
    "videos": [
        "https://www.youtube.com/watch?v=8jPQjjsBbIc"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("scrapercompany/youtube-transcript-scraper").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 = { "videos": ["https://www.youtube.com/watch?v=8jPQjjsBbIc"] }

# Run the Actor and wait for it to finish
run = client.actor("scrapercompany/youtube-transcript-scraper").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 '{
  "videos": [
    "https://www.youtube.com/watch?v=8jPQjjsBbIc"
  ]
}' |
apify call scrapercompany/youtube-transcript-scraper --silent --output-dataset

```

## MCP server setup

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

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/1wqXyXTFIeKKebg0N/builds/F2x1tr1PyTBRRV0Wj/openapi.json
