Youtube Download
A quick tips on how to download stuff from Youtube, using yt-dlp.
Setup: run sudo snap install yt-dlp
to get the downloader.
To download audio, run yt-dlp --extract-audio "URL"
.
Alternatively, run yt-dlp -f bestaudio -x "URL"
:
-f bestaudio
picks the highest quality audio format-x
drops video- Not using
--audio-format
to avoid lossy-to-lossy re-encoding, keeping the original quality.
To list all available formats:
$ yt-dlp --list-formats "URL"
Then, to download specific combo of video and audio:
$ yt-dlp --format "401+140" "URL"
yt-dlp will download both formats then combine them with ffmpeg
(ffmpeg must be installed).
More documentation:
- yt-dlp homepage
yt-dlp -h
- Additional tips: How to use yt-dlp
Written on November 1, 2024