yt-dlp

Download video and audio from many sites

About

yt-dlp fetches video and audio from a long list of streaming sites. It can extract only the soundtrack or pick a particular quality. Respect the terms of service of any site you use it with.

Install it

pkg install yt-dlp

Run this inside Termux. If the package is already present, pkg will say so and do nothing.

Commands worth knowing

5 of the invocations you will actually reach for. Tap the copy button to put one on your clipboard.

yt-dlp -f best https://example.com/video Download the best combined video and audio stream available for a link.
yt-dlp -x --audio-format mp3 https://example.com/video Extract the audio track and save it as an MP3 for offline listening.
yt-dlp -F https://example.com/video List every format the site offers with its code. Pick one deliberately.
yt-dlp -o "%(title)s.%(ext)s" https://example.com/video Save the file using the title of the video rather than a generic name.
yt-dlp -f "bv*+ba" https://example.com/video Grab the best video stream and the best audio stream, then merge them.

Worked example

Run yt-dlp -F https://example.com/video and this is what you should see.

termux
$ yt-dlp -F https://example.com/video
[info] Available formats for video:
137  mp4  1920x1080  4000k
140  m4a  audio      128k
[download] Destination: video.mp4
[download] 100% of 42.10MiB

Developed by

The yt-dlp project .