explaingit

kartikeysepta/youtube-transcript-scraper

Analysis updated 2026-05-18

1PythonAudience · dataComplexity · 2/5Setup · moderate

TLDR

A Python CLI that downloads a YouTube video's audio, transcribes it locally with Whisper or via Google Gemini, and outputs a JSON file with full metadata and timestamped transcript.

Mindmap

mindmap
  root((youtube-transcript-scraper))
    What it does
      Downloads YouTube audio
      Extracts video metadata
      Generates transcripts
    Transcription modes
      Local Faster Whisper
      Google Gemini cloud
      GPU acceleration
    Output
      Timestamped transcript
      Rich metadata JSON
      Appendable dataset
    Use cases
      Research datasets
      SEO analysis
      Content repurposing
      RAG pipelines
    Audience
      Researchers
      Data builders
      Content creators
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Run the CLI on a YouTube lecture URL to get a timestamped transcript JSON you can load into a search index or RAG pipeline.

USE CASE 2

Build a growing dataset of video transcripts by pointing the tool at multiple URLs with --output to append each result to the same file.

USE CASE 3

Extract metadata like view count, tags, and upload date from a set of competitor videos for SEO research.

What is it built with?

Pythonyt-dlpFFmpegFaster WhisperGoogle Gemini

How does it compare?

kartikeysepta/youtube-transcript-scrapera-bissell/unleash-liteabhiinnovates/whatsapp-hr-assistant
Stars111
LanguagePythonPythonPython
Setup difficultymoderatehardhard
Complexity2/54/53/5
Audiencedataresearcherdeveloper

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · moderate Time to first run · 30min

Requires FFmpeg installed on your system PATH, Gemini mode also needs a Google AI Studio API key added directly to the script.

No license file has been added yet, terms for reuse are unclear until one is added.

In plain English

This is a Python command-line tool that takes a YouTube video link and gives you back a structured JSON file containing the video's metadata and a full timestamped transcript. You run a single command with the video URL and it handles the rest: downloading the audio, converting it to MP3, pulling the channel and video details, and transcribing the spoken words with timestamps. Transcription can happen in two ways. The default method runs a speech-to-text model called Faster Whisper directly on your machine. This works without any external account or API key, and it can use a graphics card to speed up processing if you have one available. The second option sends the audio to Google Gemini, a cloud AI service, which requires a free Google AI Studio API key that you add directly to the script. The output JSON includes fields like title, channel name, view count, like count, upload date, tags, categories, and the full transcript with time markers so you can find specific moments. When you point the tool at an existing JSON file, it appends the new result rather than overwriting, making it easy to build a growing dataset across multiple videos. The README lists several practical purposes: building a searchable archive of video transcripts, extracting metadata for SEO or content analysis, creating datasets for AI search systems, and converting long lectures or interviews into text you can work with in other tools. Setup requires Python, FFmpeg installed on your computer, and cloning the repository. The API key for Gemini mode is currently hardcoded in the script rather than read from an environment variable, which the contributing notes flag as a known improvement to make. The project has no license file yet, so the terms for reuse are unclear until one is added.

Copy-paste prompts

Prompt 1
Using this youtube-transcript-scraper CLI, write a Python script that reads a list of YouTube URLs from a text file and runs the tool on each one, appending all results to transcripts.json.
Prompt 2
I have a youtube-transcript-scraper JSON output file. Write a Python script that loads it, builds a simple full-text search index with the transcript text, and lets me search by keyword.
Prompt 3
Show me how to set up youtube-transcript-scraper with Gemini cloud transcription mode, moving the API key out of the script and into an environment variable instead.

Frequently asked questions

What is youtube-transcript-scraper?

A Python CLI that downloads a YouTube video's audio, transcribes it locally with Whisper or via Google Gemini, and outputs a JSON file with full metadata and timestamped transcript.

What language is youtube-transcript-scraper written in?

Mainly Python. The stack also includes Python, yt-dlp, FFmpeg.

What license does youtube-transcript-scraper use?

No license file has been added yet, terms for reuse are unclear until one is added.

How hard is youtube-transcript-scraper to set up?

Setup difficulty is rated moderate, with roughly 30min to a first successful run.

Who is youtube-transcript-scraper for?

Mainly data.

Open on GitHub → Explain another repo

This repo across BitVibe Labs

Scan in gitsafehub Deploy in gitdeployhub kartikeysepta on gitmyhub

Verify against the repo before relying on details.