Command line/terminal based app written in Go to download Shorts & Videos using YouTube URLs/IDs.
Note: If you're looking for a ready-to-use tool, please check pinned issues for this repo.
-
YouTube Shorts & Videos downloading.
-
Ability to select from different content qualities.
At present, the project has 2 dependencies,
-
tview - Terminal UI library with rich, interactive widgets - written in Golang.
-
FFmpeg - The leading cross-platform multimedia framework. It should be installed in system or at-least have latest static binary in project's root directory. It's more of an external runtime dependency.
-
When pasted either YouTube Shorts/Video ID or URL, the app fetches the metadata from YouTube's internal APIs.
-
Then depending on quality selections for video & audio, the application downloads the Shorts/Video content by making of small sized data requests to the fetched content URLs.
-
In the end, if the FFmpeg exist, then both separate video & audio stream files are merged into single output file.
working_demo_clip.mp4
After installing Go, enter below command from project's root,
-
On Linux/UNIX,
go build -o go_youtube_downloader ./cmd/go_youtube_downloader.go
-
On Windows,
go build -o go_youtube_downloader.exe ./cmd/go_youtube_downloader.go
build_clip.mp4
After installing Go, clone/download this project & enter below command from project's root,
go run ./cmd/go_youtube_downloader.go
direct_run_clip.mp4
-
Systems must have FFmpeg installed or have latest static binary in project's root directory to merge downloaded separate video & audio streams into a single file.
-
Age-restricted videos can not be downloaded due to YouTube's Signature Ciphering.
-
YouTube have bandwidth limitations for each incoming request, around 10 MB per request. If any request gets more data than this size limit, then further requests will throttle download or connection may get terminated. So, to get better performance when downloading data & writing it to output file, it's divided into smaller chunks for consistency. Based on selected quality & size, the download time would be more or less.
-
Reverse-Engineering YouTube: Revisited - Blog explaining YouTube's internal APIs.
-
YouTube-Internal-Clients - A python script that discovers hidden YouTube API clients. Just a research project.
-
YT-DLP - A youtube-dl fork with additional features and fixes
-
Youtubei - Get Youtube data such as videos, playlists, channels, video information & comments, related videos, up next video, and more!