om_kh Apify Actor Catalogue

← All guides · All Actors

YouTube Transcript API in Python — No API Key, With Timestamps

How do I get the transcript of a YouTube video with an API?

Call the YouTube Transcript API Actor on Apify with a list of video URLs. It returns, for each video, the full text, timestamped segments, the caption language and, on request, SRT, VTT or ~250-word RAG chunks with start and end seconds. No YouTube API key, no OAuth, no cookies. Videos without captions are never charged.

Try it: YouTube Transcript API on Apify — click Try for free, the input is prefilled.

Step by step

  1. Open YouTube Transcript API and click Try for free (an Apify account is free).
  2. Paste this input (or fill the form):
{
  "videos": [
    "https://www.youtube.com/watch?v=aircAruvnKk"
  ],
  "outputFormats": [
    "chunks",
    "srt"
  ]
}
  1. Click Start. Download the results as JSON, CSV or Excel, or read them from the API.

From Python

from apify_client import ApifyClient

client = ApifyClient("<YOUR_APIFY_TOKEN>")
run = client.actor("om_kh/youtube-transcript-api").call(run_input={
    "videos": [
        "https://www.youtube.com/watch?v=aircAruvnKk"
    ],
    "outputFormats": [
        "chunks",
        "srt"
    ]
})
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item)

With one HTTP call (cURL)

curl -X POST "https://api.apify.com/v2/acts/om_kh~youtube-transcript-api/run-sync-get-dataset-items?token=<YOUR_APIFY_TOKEN>" \
  -H "Content-Type: application/json" \
  -d '{"videos": ["https://www.youtube.com/watch?v=aircAruvnKk"], "outputFormats": ["chunks", "srt"]}'

What you get

Price

Pay per transcript delivered — see the Pricing tab for the current price. You only pay for results delivered; set maxTotalChargeUsd to cap a run.

Use cases

From an AI agent (MCP)

Connect Claude, Cursor or any MCP client to https://mcp.apify.com and add om_kh/youtube-transcript-api as a tool. The agent sends the same JSON input and gets the rows back.

FAQ

Do I need a YouTube Data API key?
No. The official YouTube Data API does not return transcripts of other people’s videos anyway; this Actor reads the public captions.

What if the video has no captions?
It is reported as unavailable and not charged.

Can I get a whole channel?
Yes, use YouTube Channel Transcripts with an @handle.