Get the best audio into mp3 file: yt-dlp -f 'ba' -x -audio-format mp3 -o '%(id)s.mp3'Īll the options for format selection and filtering can be found here, There are a lot. Save this file as video_id.extension (1La4QzGeaaQ.mp4): yt-dlp -f "best" -o '%(id)s.%(ext)s'ĭownload and merge the best video stream with the best audio stream: yt-dlp -f 'bv*+ba' -o '%(id)s.%(ext)s'ĭownload 1080p video and merge with best audio stream: yt-dlp -f 'bv*+ba' -o '%(id)s.%(ext)s'ĭownload 1080p video that is mp4 format and merge with best m4a audio format: yt-dlp -f 'bv+ba' -merge-output-format mp4 -o '%(id)s.mp4'Įmbed video thumbnail into video file use -embed-thumbnail: yt-dlp -f 'bv+ba' -embed-thumbnail -merge-output-format mp4 -o '%(id)s.mp4'Įmbed subtitles to video file (if they exist) -embed-subs : yt-dlp -f 'bv+ba' -embed-subs -merge-output-format mp4 -o '%(id)s.mp4'Įmbed metadata about the video -embed-metadata : yt-dlp -f 'bv+ba' -embed-metadata -merge-output-format mp4 -o '%(id)s.mp4'
YOUTUBE DOWNLOAD 1080 720P
Print JSON information for the video and audio streams: yt-dlp -dump-json Single video or audio downloadsĭownload the best format (video + audio) that is equal to or greater than 720p width.
Print out the available formats and information with: yt-dlp -list-formats
If you ever need to update yt-dlp use: yt-dlp -U Installing yt-dlp can simply be done with: sudo wget -O /usr/local/bin/yt-dlpįollowed by: sudo chmod a+rx /usr/local/bin/yt-dlp Yt-dlp is a fork from the now troubled youtube-dl, the best part about yt-dlp aside from being actively maintained is that it follows similar commands to youtube-dl.