I had known how to choose formats for a single video.But if I'd like to download a playlist with all videos in the formats of 360P,how can I do ?Thanks!

  • You can use the same options as with downloading just one file (i.e. -f18) - format codes are fixed. Since if a video is not available in this format will result in stopping download you'll, most likely, want to add the option -i to ignore errors. – user448115 Sep 18 '15 at 7:45
  • @adonis That works! All the videos have the same format code! – peter Sep 18 '15 at 12:18
  • 1
    Possible duplicate of youtube-dl multiple files downloading – karel Aug 13 '17 at 11:47

First check for the format code of the video quality you want:

$ youtube-dl -F https://www.youtube.com/playlist?list=PLSXu8_7Y8pIb7BraT3mpyCBDk7RQ2QZlb

This command gives you:

format code  extension  resolution note
139          m4a        audio only DASH audio   48k , m4a_dash container, mp4a.40.5@ 48k (22050Hz)
249          webm       audio only DASH audio   50k , opus @ 50k, 762.50KiB
250          webm       audio only DASH audio   59k , opus @ 70k, 866.37KiB
171          webm       audio only DASH audio   90k , vorbis@128k, 1.28MiB
251          webm       audio only DASH audio  108k , opus @160k, 1.53MiB
140          m4a        audio only DASH audio  127k , m4a_dash container, mp4a.40.2@128k (44100Hz)
160          mp4        256x144    DASH video   77k , avc1.4d400c, 30fps, video only
278          webm       256x144    144p   99k , webm container, vp9, 30fps, video only, 968.10KiB
242          webm       426x240    240p  172k , vp9, 30fps, video only, 1.44MiB
133          mp4        426x240    DASH video  192k , avc1.4d4015, 30fps, video only
134          mp4        640x360    DASH video  306k , avc1.4d401e, 30fps, video only
243          webm       640x360    360p  361k , vp9, 30fps, video only, 2.78MiB
244          webm       854x480    480p  618k , vp9, 30fps, video only, 4.66MiB
135          mp4        854x480    DASH video  720k , avc1.4d401f, 30fps, video only
247          webm       1280x720   720p 1362k , vp9, 30fps, video only, 9.98MiB
136          mp4        1280x720   DASH video 1446k , avc1.4d401f, 30fps, video only
17           3gp        176x144    small , mp4v.20.3, mp4a.40.2@ 24k
36           3gp        320x180    small , mp4v.20.3, mp4a.40.2
43           webm       640x360    medium , vp8.0, vorbis@128k
18           mp4        640x360    medium , avc1.42001E, mp4a.40.2@ 96k
22           mp4        1280x720   hd720 , avc1.64001F, mp4a.40.2@192k (best)

So, from here, we know that 360p format code is 18

Now, to download whole playlist in this format, simply fire up:

$ youtube-dl -citf 18 https://www.youtube.com/playlist?list=PLSXu8_7Y8pIb7BraT3mpyCBDk7RQ2QZlb

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.