# YouTube Transcript Scraper with Timestamps and Languages (`talcoe/youtube-transcripts`) Actor

Get the full transcript of any YouTube video as plain text and timestamped segments, with title, channel, publish date, duration and views, filtered by caption language with optional translation, at a fixed price per video.

- **URL**: https://apify.com/talcoe/youtube-transcripts.md
- **Developed by:** [M Usama](https://apify.com/talcoe) (community)
- **Categories:** News
- **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 results

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

### What does YouTube Transcript Scraper with Timestamps and Languages do?

You have a list of videos and you need the words in them. Paste the links, and you get one record per video: title, channel, publish date, duration, views, the language of the captions, the full transcript as plain text, and every caption line with its start time and duration. If you run an AI pipeline, a research desk or a content team, that list is usually a long afternoon of copy and paste. This Actor does it in seconds and bills a fixed price per video.

### Data source

The Actor calls the same public player endpoint that the YouTube mobile app uses, then downloads the caption track the video publishes. No login, no cookies, no browser.

### Why use it?

- Feed transcripts to an LLM for summaries, search or retrieval over a channel's back catalog.
- Pull quotes with exact timestamps, so you can link straight to the moment a point was made.
- Track what competitors and creators say across dozens of videos without watching them.
- Build a multilingual dataset: pick a caption language, or ask for a translation when YouTube offers one.

It replaces manual transcript copying and the paid subscriptions that cap how many videos you can export.

### How to use it

1. Paste YouTube links or bare video ids into the input. Watch links, youtu.be links and Shorts links all work.
2. Pick a caption language. Leave translation empty unless you want it.
3. Click Start. Download results as JSON, CSV or Excel, or read them through the API.
4. Add a Schedule and an Integration (Slack, Google Sheets, webhook) to process new videos automatically.

### Input

| Field | Description |
|---|---|
| `videoUrls` | Watch links, youtu.be links, Shorts links or 11 character video ids. |
| `language` | Caption language code, for example `en`, `es`, `de`. Human made captions win over auto generated ones. If your language is missing, the first available track is returned and `language` tells you which one. |
| `translateTo` | Optional language code. Used only when YouTube offers translation for that video. |
| `includeSegments` | Include the timestamped `segments` array. Default on. |
| `maxResults` | Hard stop for the run. You are billed per result, so this caps the cost. |
| `proxyConfiguration` | Residential proxy is the default, because YouTube challenges datacenter IPs. |

Example input:

```json
{
  "videoUrls": ["https://www.youtube.com/watch?v=dQw4w9WgXcQ", "jNQXAC9IVRw"],
  "language": "en",
  "includeSegments": true,
  "maxResults": 50,
  "proxyConfiguration": { "useApifyProxy": true, "apifyProxyGroups": ["RESIDENTIAL"] }
}
```

### Output

Every record has the same shape:

```json
{
  "id": "jNQXAC9IVRw",
  "videoId": "jNQXAC9IVRw",
  "url": "https://www.youtube.com/watch?v=jNQXAC9IVRw",
  "title": "Me at the zoo",
  "channel": "jawed",
  "publishDate": "2005-04-23",
  "durationSeconds": 19,
  "views": 449292929,
  "language": "en",
  "autoGenerated": false,
  "transcript": "All right, so here we are, in front of the elephants the cool thing about these guys is that they have really...",
  "segments": [
    { "start": 1.2, "duration": 2.16, "text": "All right, so here we are, in front of the elephants" },
    { "start": 5.318, "duration": 2.656, "text": "the cool thing about these guys is that they have really..." }
  ],
  "wordCount": 39,
  "segmentCount": 6,
  "translatedFrom": null,
  "availableLanguages": ["en", "de"],
  "channelId": "UC4QobU6STFB0P71PMvOGN5A",
  "keywords": ["me at the zoo", "jawed karim"],
  "scrapedAt": "2026-11-24T16:24:07.774Z"
}
```

| Field | Meaning |
|---|---|
| `id` | Stable key (the video id), safe for deduplication between runs |
| `transcript` | All caption lines joined into one block of text |
| `segments` | Caption lines with `start` and `duration` in seconds |
| `language` | Language of the returned text |
| `autoGenerated` | True when the captions are YouTube's speech recognition, not a human upload |
| `translatedFrom` | Source language code when you asked for a translation, otherwise null |
| `availableLanguages` | Every caption language the video offers |

### Pricing

Pay per event: a small fee when a run starts, then a fixed price per result returned. A video with no captions returns no record and costs you nothing. Set `maxResults` to cap any run.

### Limitations

- Videos without captions, private videos, and age restricted videos return no record. They are listed in the `ERRORS` record of the run's key value store with a reason.
- Live streams that are still running have no finished captions.
- Very new videos can have auto generated captions only after YouTube finishes processing them.
- Some videos have no publish date in the data YouTube returns, and `publishDate` is then null.

### FAQ

**Is this legal?** The Actor reads public pages and caption files that YouTube serves to any visitor without a login. You are responsible for how you use the transcripts.

**Why a residential proxy?** YouTube challenges many datacenter IPs. Residential IPs get through reliably, and each video uses one sticky session so its requests share an address.

**Something is missing or broken?** Open an issue in the Issues tab; response time is usually under a day.

# Actor input Schema

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

YouTube watch links, youtu.be links, Shorts links or bare 11 character video ids. One transcript record per video.

## `language` (type: `string`):

Language code of the captions you want, for example en, es, de, fr, pt, ja. Human made captions win over auto generated ones. If the video has no caption in this language, the first available track is returned.

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

Language code to translate the transcript into when YouTube offers translation for that video, for example es or de. Leave empty for no translation.

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

Add a segments array with start, duration and text for every caption line. Turn off to return only the plain transcript.

## `maxResults` (type: `integer`):

Hard stop for the run. You are billed per result, so this caps the cost.

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

YouTube blocks datacenter IPs, so the Residential proxy group is the default. Do not switch to datacenter.

## Actor input object example

```json
{
  "videoUrls": [
    "https://www.youtube.com/watch?v=dQw4w9WgXcQ",
    "https://www.youtube.com/watch?v=jNQXAC9IVRw",
    "https://www.youtube.com/watch?v=9bZkp7q19f0",
    "https://www.youtube.com/watch?v=kJQP7kiw5Fk",
    "https://www.youtube.com/watch?v=hT_nvWreIhg",
    "https://www.youtube.com/watch?v=YE7VzlLtp-4",
    "https://www.youtube.com/watch?v=UF8uR6Z6KLc",
    "https://www.youtube.com/watch?v=arj7oStGLkU",
    "https://www.youtube.com/watch?v=8jPQjjsBbIc",
    "https://www.youtube.com/watch?v=ZXsQAXx_ao0",
    "https://www.youtube.com/watch?v=fJ9rUzIMcZQ",
    "https://www.youtube.com/watch?v=OPf0YbXqDm0"
  ],
  "language": "en",
  "includeSegments": true,
  "maxResults": 200,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}
```

# Actor output Schema

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

No description

# 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",
        "https://www.youtube.com/watch?v=jNQXAC9IVRw",
        "https://www.youtube.com/watch?v=9bZkp7q19f0",
        "https://www.youtube.com/watch?v=kJQP7kiw5Fk",
        "https://www.youtube.com/watch?v=hT_nvWreIhg",
        "https://www.youtube.com/watch?v=YE7VzlLtp-4",
        "https://www.youtube.com/watch?v=UF8uR6Z6KLc",
        "https://www.youtube.com/watch?v=arj7oStGLkU",
        "https://www.youtube.com/watch?v=8jPQjjsBbIc",
        "https://www.youtube.com/watch?v=ZXsQAXx_ao0",
        "https://www.youtube.com/watch?v=fJ9rUzIMcZQ",
        "https://www.youtube.com/watch?v=OPf0YbXqDm0"
    ],
    "language": "en",
    "proxyConfiguration": {
        "useApifyProxy": true,
        "apifyProxyGroups": [
            "RESIDENTIAL"
        ]
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("talcoe/youtube-transcripts").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",
        "https://www.youtube.com/watch?v=jNQXAC9IVRw",
        "https://www.youtube.com/watch?v=9bZkp7q19f0",
        "https://www.youtube.com/watch?v=kJQP7kiw5Fk",
        "https://www.youtube.com/watch?v=hT_nvWreIhg",
        "https://www.youtube.com/watch?v=YE7VzlLtp-4",
        "https://www.youtube.com/watch?v=UF8uR6Z6KLc",
        "https://www.youtube.com/watch?v=arj7oStGLkU",
        "https://www.youtube.com/watch?v=8jPQjjsBbIc",
        "https://www.youtube.com/watch?v=ZXsQAXx_ao0",
        "https://www.youtube.com/watch?v=fJ9rUzIMcZQ",
        "https://www.youtube.com/watch?v=OPf0YbXqDm0",
    ],
    "language": "en",
    "proxyConfiguration": {
        "useApifyProxy": True,
        "apifyProxyGroups": ["RESIDENTIAL"],
    },
}

# Run the Actor and wait for it to finish
run = client.actor("talcoe/youtube-transcripts").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",
    "https://www.youtube.com/watch?v=jNQXAC9IVRw",
    "https://www.youtube.com/watch?v=9bZkp7q19f0",
    "https://www.youtube.com/watch?v=kJQP7kiw5Fk",
    "https://www.youtube.com/watch?v=hT_nvWreIhg",
    "https://www.youtube.com/watch?v=YE7VzlLtp-4",
    "https://www.youtube.com/watch?v=UF8uR6Z6KLc",
    "https://www.youtube.com/watch?v=arj7oStGLkU",
    "https://www.youtube.com/watch?v=8jPQjjsBbIc",
    "https://www.youtube.com/watch?v=ZXsQAXx_ao0",
    "https://www.youtube.com/watch?v=fJ9rUzIMcZQ",
    "https://www.youtube.com/watch?v=OPf0YbXqDm0"
  ],
  "language": "en",
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}' |
apify call talcoe/youtube-transcripts --silent --output-dataset

```

## MCP server setup

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

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/I08VV3YT2hzOW24Bb/builds/NfL4NxRMMdcxE6F9e/openapi.json
