# YouTube Transcript Scraper: Text, SRT & Timestamps (`nexo_data/youtube-transcripts-timestamps`) Actor

Extract YouTube transcripts and subtitles from public videos with captions. Get text, timestamped segments, Markdown and SRT for manual or auto-generated captions in your language. $0.50 per 1,000 videos; failed videos are not charged.

- **URL**: https://apify.com/nexo_data/youtube-transcripts-timestamps.md
- **Developed by:** [Nexo Data](https://apify.com/nexo_data) (community)
- **Categories:** Social media, Developer tools
- **Stats:** 3 total users, 2 monthly users, 96.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.50 / 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.

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: Text, SRT & Timestamps

Extract YouTube transcripts and subtitles from public videos with captions. Get text, timestamped segments, Markdown and SRT for manual or auto-generated captions in your language. $0.50 per 1,000 videos; failed videos are not charged.

**Store page:** https://apify.com/nexo_data/youtube-transcripts-timestamps

### What can you do with this YouTube transcripts scraper?

- Feed video transcripts into RAG / LLM pipelines
- Repurpose videos into blog posts, summaries and SRT subtitles
- Research competitors' video content at scale
- Search spoken content across a channel or playlist

### How to extract YouTube transcripts with timestamps

1. Open the Actor on Apify Store and click **Try for free**.
2. Paste your input (see the example below) in the Input tab.
3. Click **Start** and wait for the run to finish.
4. Download results as JSON, CSV, Excel or HTML, or fetch them via the Apify API.

### How to extract YouTube transcripts with timestamps via API

```bash
curl -X POST "https://api.apify.com/v2/acts/nexo_data~youtube-transcripts-timestamps/run-sync-get-dataset-items?token=YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"videoUrls": ["https://www.youtube.com/watch?v=jNQXAC9IVRw"], "languages": ["en", "es"], "proxyMode": "auto"}'
```

You can also call it from Python/JS with the `apify-client`, schedule it, or connect it to Make, Zapier, n8n or an MCP-enabled AI agent.

### How to schedule it for monitoring

Create an Apify **Schedule** (e.g. daily) with the same input. Combine with webhooks or integrations to get alerts in Slack, email or Google Sheets.

### Input example

```json
{
  "videoUrls": [
    "https://www.youtube.com/watch?v=jNQXAC9IVRw"
  ],
  "languages": [
    "en",
    "es"
  ],
  "proxyMode": "auto"
}
```

### Output example

Each item in the dataset is one result. Typical fields are listed in the **Output** tab; export to JSON/CSV/Excel.

### Pricing (pay per event)

You only pay for what you get — no monthly rental. Apify platform usage is included in the event prices below.

| Event | What it is | Price |
|---|---|---|
| `run-start` | Run initialization — One initialization event per valid run. Covers setup and unsuccessful network attempts. | $0.0002 ($0.2 / 1,000) |
| `transcript` | Successful transcript — One video with a successfully extracted caption track. | $0.001 ($1.0 / 1,000) |
| `residential-data-100kb` | Residential route data (100 KB) — Charged only when YouTube blocks the direct route: each 100 KB of compressed residential proxy transfer beyond the first 50 KB per video. | $0.0015 ($1.5 / 1,000) |

Tip: set **Maximum cost per run** in run options to cap spend. New Apify accounts get free monthly credits, so your first runs are effectively free.

### FAQ

**Is it legal to scrape YouTube transcripts?** This Actor collects only publicly available data. Make sure your use complies with the site's terms and data protection laws (e.g. GDPR).

**Do I need an API key or login?** No. Only an Apify account.

**What if a source fails?** Failed or empty sources are reported in the output for diagnosis; you are not charged the `transcript` event for them.

**Can I use it with AI agents / LLMs?** Yes — output is structured JSON, ready for RAG, LangChain, LlamaIndex or the Apify MCP server.

**Found a bug or need a feature?** Open an issue in the **Issues** tab — we usually respond within 24 hours.

# Actor input Schema

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

Public YouTube video URLs or 11-character IDs. Duplicate videos are processed once. Maximum 200 distinct videos per run.

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

Language codes such as en, es or pt. Manual captions are preferred within each language. No machine translation is performed.

## `allowOtherLanguages` (type: `boolean`):

If false, a video without one of your requested languages returns language_unavailable.

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

Fetch public metadata via YouTube oEmbed. Metadata failure does not discard a valid transcript.

## `proxyMode` (type: `string`):

YouTube can block cloud IPs. Auto makes at most four residential attempts after a block. Caption content and timing are preserved. Residential traffic has a platform cost; keep run limits small while testing.

## Actor input object example

```json
{
  "videoUrls": [
    "https://www.youtube.com/watch?v=jNQXAC9IVRw"
  ],
  "languages": [
    "en",
    "es"
  ],
  "allowOtherLanguages": false,
  "includeMetadata": true,
  "proxyMode": "auto"
}
```

# Actor output Schema

## `transcripts` (type: `string`):

Full caption text, timestamped segments and SRT, plus explicit errors.

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

Counts, errors and coverage information.

# 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=jNQXAC9IVRw"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("nexo_data/youtube-transcripts-timestamps").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=jNQXAC9IVRw"] }

# Run the Actor and wait for it to finish
run = client.actor("nexo_data/youtube-transcripts-timestamps").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=jNQXAC9IVRw"
  ]
}' |
apify call nexo_data/youtube-transcripts-timestamps --silent --output-dataset

```

## MCP server setup

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

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/kEFEyNuZPivbPGFrm/builds/Lr2DAW1edW9RUnmbo/openapi.json
