explaingit

nhodges/yt-dlv

13RustAudience · developerComplexity · 3/5LicenseSetup · moderate

TLDR

A Rust rewrite of yt-dlp for downloading YouTube videos, with a built-in JavaScript engine to decrypt stream URLs so no external Node.js or runtime installation is needed.

Mindmap

mindmap
  root((yt-dlv))
    What it does
      YouTube video download
      Audio extraction
      Playlist download
    Key Feature
      Embedded QuickJS engine
      No external JS runtime
      Pluggable JS interface
    Format Options
      Quality and codec select
      Merge with ffmpeg
      Subtitle and thumbnail
    Tech Stack
      Rust
      QuickJS embedded
      ffmpeg optional
    Extras
      Proxy support
      Cookie auth
      Public domain license
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

Things people build with this

USE CASE 1

Download YouTube videos or playlists from the command line without installing Node.js or any JavaScript runtime.

USE CASE 2

Extract audio-only from YouTube videos by selecting audio streams and skipping video tracks.

USE CASE 3

Route downloads through a proxy or load browser cookies to reduce the chance of being blocked by YouTube.

Tech stack

RustQuickJSffmpegC

Getting it running

Difficulty · moderate Time to first run · 30min

Requires Rust toolchain and a C compiler to build from source, ffmpeg is needed separately to merge video and audio streams.

Released into the public domain, do anything you want with no restrictions whatsoever.

In plain English

yt-dlv is a command-line tool for downloading videos and audio from YouTube, written from scratch in Rust. It is the author's personal reimplementation of yt-dlp, a well-known Python downloader, with a focus on learning and architectural exploration. The author describes it as an honest work-in-progress rather than a finished product, though the core pipeline works end-to-end for ordinary YouTube downloads. The most technically distinctive aspect is how it handles YouTube's stream protection. YouTube encrypts its video URLs using JavaScript code that must be run before a download can start. Most downloaders call an external JavaScript runtime for this step. yt-dlv instead compiles a small JavaScript engine called QuickJS directly into the binary, so no external Node.js, Deno, or similar runtime needs to be installed. If YouTube's defenses grow complex enough to need a full external runtime, the design allows swapping one in through a pluggable interface. From a user's perspective, the tool supports the same format-selection syntax as yt-dlp: you can list available formats, pick video and audio streams by quality or codec, merge them with ffmpeg, extract audio only, download playlists, and save subtitles, thumbnails, and description files. You can also route downloads through a proxy or load authentication cookies from a browser profile to reduce the chance of being blocked. There is a known limitation: YouTube increasingly requires "proof of origin" from datacenter IP addresses and blocks them even when signatures are valid. This is the same problem yt-dlp faces, and resolving it requires additional attestation work the author is tracking in the issue tracker. Building the tool requires Rust, a C compiler, and optionally ffmpeg for merging streams. The code is released into the public domain under the Unlicense. It is not affiliated with yt-dlp or YouTube, and the README notes that users are responsible for complying with YouTube's terms of service.

Copy-paste prompts

Prompt 1
I built yt-dlv from source with Rust and a C compiler. How do I list all available formats for a YouTube URL and then download the best 1080p video merged with audio using ffmpeg?
Prompt 2
Using yt-dlv, how do I download an entire YouTube playlist to a local folder and save subtitles and thumbnails for each video?
Prompt 3
I need yt-dlv to route all downloads through an authenticated HTTP proxy. What command-line flags or config options do I use?
Open on GitHub → Explain another repo

← nhodges on gitmyhub — every repo by this author, as a profile.

Verify against the repo before relying on details.