See llms.txt for all machine-readable content.

Back to Templates

Save YouTube transcripts to Google Sheets with Apify

Quick overview

This workflow runs every morning to fetch YouTube video transcripts via the Apify YouTube Transcript Scraper actor and appends the results to Google Sheets, while also logging videos that fail to return captions into a separate tab.

How it works

  1. Runs every morning at 07:00 (or on manual execution for testing).
  2. Builds an Apify actor input from your YouTube channel and/or video URLs, including limits, language, and an "only new videos" state key.
  3. Calls the Apify YouTube Transcript Scraper actor to retrieve dataset items for videos with available caption tracks (up to a 5-minute request timeout).
  4. Formats one output row per delivered video, truncating transcripts that exceed the Google Sheets cell limit and flagging when a cut occurs.
  5. Appends the formatted transcript rows to the Google Sheets "Transcripts" tab.
  6. Fetches the actor run’s OUTPUT summary from Apify, extracts any failed videos with reason codes, and appends or updates them in the Google Sheets “Failed” tab keyed by Video ID.

Setup

  1. Create an Apify account and an HTTP Header Auth credential that sets Authorization: Bearer <YOUR_APIFY_TOKEN>, then select it in both Apify HTTP Request steps.
  2. Create a Google Sheet with two tabs named "Transcripts" and "Failed" (or update the tab names in the Settings) and connect a Google Sheets credential.
  3. In the Settings step, paste your Google Sheet URL, add one or more YouTube channel/video URLs, and adjust limits (max items/videos), language, state key, and the maxTotalChargeUsd cap as needed.

Requirements

  • An Apify account (the free plan works) and its API token
  • A Google account with Google Sheets

Customization

  • Change the schedule time or the language code in Settings, or add "srt" to outputFormats in Build actor input.

Additional info

Cost: the YouTube Transcript Scraper actor is a paid Apify actor that charges per transcript delivered (see its Apify page for the current price). Videos that fail are not charged, and maxTotalChargeUsd in Settings caps each run. The actor is published by SKILLMERC, the author of this template. If a Google Sheets node shows Map Each Column Manually after you connect Google, set it back to Map Automatically.