Advertisement
PrimePastes

Relevant YT-DLP Commands

May 18th, 2024 (edited)
41
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.05 KB | None | 0 0
  1. Check available formats:
  2. -F then -f

  3.  
  4. -F: Check available formats for file
  5. -f: Download file in chosen format from its respective number (I.E, 18, 22 are usually best quality MP4)
  6.  
  7.  
  8. Extract just the audio from file:
  9. --extract-audio / -x
  10.  
  11. Trim the length of file name: (File won’t download if the title is too long)

  12. --trim-filenames [LENGTH] (I.E, 10, 12, 15, etc.)
  13.  
  14. Extract certain part of a file:
If the file DOES have chapters:
  15. --download-section *[TIMESTAMP]-[TIMESTAMP]
  16.  
  17. If the file DOESN’T have chapters:
  18. --force-keyframes --download-section *[TIMESTAMP]-[TIMESTAMP]
  19.  
  20. If the file is a YouTube video, right click on the video after pausing on the start of where you want the video to begin. Click on ‘Copy video URL at current time’. Do this for where you want the video/audio file to begin and end.
  21.  
  22. For example: yt-dlp --force-keyframes --download-section *688-731 [URL]
  23.  
  24. NOTICE: If downloaded file does not have video, but does have audio; re-download the video in a different format. You can do this using the ‘-F / -f’ tool
  25.  
  26. 
Download the thumbnail, description or subtitles:

  27. --write-thumbnail
  28. --write-description
  29. --write-subtitles
  30.  
  31. 
Download thumbnail but not the video:
  32. --skip-download --write-thumbnail
  33. --skip-download --write-description
  34. --skip-download --write-subtitles
  35.  
  36.  
  37. Downloading videos from sites that require cookies:
Sometimes, a site (Like Instagram) needs your cookies to get the download. So, while logged into the respective browser, use:
--cookies-from-browser [BROWSER NAME]
  38.  
  39. Current supported browsers: brave, chrome, chromium, edge, firefox, opera, safari, vivaldi
  40.  
  41. Download a livestream while it is still live:

  42. --live-from-start
  43.  
  44. Get ready for youtube-dlp to start downloading a livestream before it starts:
  45. --wait-for-video
  46.  
  47. Download a video in the best available video and audio quality:
  48. -f bv*+ba/b
  49.  
  50.  
  51. Embed subtitles onto downloaded video:
  52. --embed-subs
  53.  
  54. Embed thumbnail onto downloaded video:
  55. --embed-thumbnail
  56.  
  57. Embed metadata onto downloaded video:
  58. --embed-metadata
  59.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement