Snippets

Dénes Türei how to download a video from youtube

Created by Dénes Türei
#!/bin/bash

# from https://askubuntu.com/a/486298/341752

# show available formats
youtube-dl -F "http://www.youtube.com/watch?v=P9pzm5b6FFY"

# format #22
youtube-dl -f 22 "http://www.youtube.com/watch?v=P9pzm5b6FFY"

# to select the best quality
youtube-dl -f bestvideo+bestaudio "http://www.youtube.com/watch?v=P9pzm5b6FFY"

# alternatively
youtube-dl -f 'bestvideo[ext=mp4]+bestaudio[ext=m4a]/bestvideo+bestaudio' --merge-output-format mp4 "http://www.youtube.com/watch?v=P9pzm5b6FFY"

Comments (0)

HTTPS SSH

You can clone a snippet to your computer for local editing. Learn more.