Any way to download the contents of a youtube mix?

I installed yt-dlp with yay yt-dlp & nothing more.

which yt-dlp
/usr/bin/yt-dlp

yt-dlp -U
Current version: stable@2025.03.31 from yt-dlp/yt-dlp
Latest version: stable@2025.04.30 from yt-dlp/yt-dlp


You may need a YouTube session for the process to continue, I’ve had this before too & again just minutes ago:

yt-dlp https://www.youtube.com/watch?v=LiCjD5qVV_U&list=RDLiCjD5qVV_U
[youtube] Extracting URL: https://www.youtube.com/watch?v=LiCjD5qVV_U
[youtube] LiCjD5qVV_U: Downloading webpage
...truncated for brevity...

Short answer: simply open your YT playlist link then pause playback & run the yt-dlp command again, my yt-dlp output from doing this just now:

yt-dlp https://www.youtube.com/watch?v=LiCjD5qVV_U&list=RDLiCjD5qVV_U
[YoutubeYtBe] Extracting URL: https://youtu.be/LiCjD5qVV_U?list=RDLiCjD5qVV_U
[youtube:tab] Extracting URL: https://www.youtube.com/watch?v=LiCjD5qVV_U&list=RDLiCjD5qVV_U&feature=youtu.be
[youtube:tab] Downloading playlist RDLiCjD5qVV_U - add --no-playlist to download just the video LiCjD5qVV_U
[youtube:tab] RDLiCjD5qVV_U: Downloading webpage
[download] Downloading playlist: Mix - I Ain't Mad At Cha
[youtube:tab] RDLiCjD5qVV_U page 1: Downloading API JSON
...truncated for brevity...
[download] Destination: I Ain't Mad At Cha [LiCjD5qVV_U].f616.mp4
[download] 100% of   21.00MiB in 00:00:09 at 2.21MiB/s
[download] Destination: I Ain't Mad At Cha [LiCjD5qVV_U].f251.webm
[download] 100% of    4.58MiB in 00:00:00 at 5.44MiB/s
[Merger] Merging formats into "I Ain't Mad At Cha [LiCjD5qVV_U].webm"
...truncated for brevity...
[download] Destination: All Eyez On Me [zgZ52M4a_R0].f616.mp4
[download] 100% of    7.41MiB in 00:00:03 at 2.06MiB/s
[download] Destination: All Eyez On Me [zgZ52M4a_R0].f251.webm
[download] 100% of    5.04MiB in 00:00:00 at 5.87MiB/s
[Merger] Merging formats into "All Eyez On Me [zgZ52M4a_R0].webm"
...truncated for brevity...
[download] Destination: Life Goes On [k11iUIQ5XbY].f616.mp4
[download]   1.7% of ~  20.96MiB at  226.43KiB/s ETA Unknown (frag 2/59)^C
ERROR: Interrupted by user

Note the difference in output from the same command run a few minutes apart, second run with the playlist opened & paused in the browser.

And yes, please do be kind to people who offer help freely of their own will, lest you discourage them. Getting an outcome is a process & one in which there are often learning opportunities for those involved & others who read later on, I learn a lot from the EnOS forum :smiley:

Maybe its do to your location?

Location may impact access to YT, yes, but I got 2 different results just now running yt-dlp https://www.youtube.com/watch?v=LiCjD5qVV_U&list=RDLiCjD5qVV_U

  1. stopped at end of 1st playlist vid
  2. with playlist opened & paused in browser, continued through playlist until interrupted

Thanks for LZ, btw :wink::sign_of_the_horns:

1 Like

Just gave it a quick spin, out of interest:

  • used https://www.youtube.com/watch?v=LiCjD5qVV_U&list=RDLiCjD5qVV_U
  • logged into YT
  • started playing, paused
  • used yt-dlp https://www.youtube.com/watch?v=LiCjD5qVV_U&list=RDLiCjD5qVV_U
  • first song loads, then yt-dlp seems to “hang”, you have to press ENTER
  • then displays “Done”. 1 song downloaded.
  • I’m in Germany, yt-dlp version stable@2025.04.30 from yt-dlp/yt-dlp

Solution: Quote the link using single quotes, as in yt-dlp 'https://www.youtube.com/watch?v=LiCjD5qVV_U&list=RDLiCjD5qVV_U'!

Seems some links aren’t shell/yt-dlp-friendly.

You can of course also do lots of other crazy stuff, like

yt-dlp -x --audio-format mp3 --audio-quality 320K 'https://www.youtube.com/watch?v=LiCjD5qVV_U&list=RDLiCjD5qVV_U'

(Although you probably shouldn’t. Using whipper to rip your own CDs to accurate FLAC is much more satisfying. On some of these videos, you have additional into/outro/ad stuff, some are just shitty quality.)

1 Like

Thanks for adding. That’s interesting, did yt-dlp retrieve the playlist? (see the 2nd, larger output in this post)

Nope, instead it showed &list… as a second entry number. That’s what brought me to the solution above. Sometimes it’s easy…

Oh, wait, I should abort it, has already downloaded 24 songs of a list I don’t want! :rofl:

1 Like

I was starting to wonder about he URL enclosing in quotes, had to do that yesterday while writing an IP geolocation function.

So the final solution is:

  1. Obtain the YouTube link inclusive of playlist ID
  2. wrap the URL in quotes in the yt-dlp command to make it shell safe
  3. possibly load the playlist in your browser (for cookies?)

Example:
yt-dlp "https://www.youtube.com/watch?v=LiCjD5qVV_U&list=RDLiCjD5qVV_U"

1 Like

Using or not using --cookies-from-browser firefox made no difference here (it’s mostly needed for private videos you have access to). I could also just copy a playlist link without first opening it. Seems to have been the missing quoting.

Use single quotes though, so the shell won’t try to expand anything, like with double quotes!

I edited my above post for some more info.

But I got different results from the same yt-dlp command only several minutes apart, 1st stalled, 2nd with playlist loaded in browser continued until interrupted, only difference was loading the playlist in my browser, the actual output is in my post above.

At any rate, enclosing the URL in quotes seems to be needed in some cases so chars like & don’t get interpreted.

Note: You won’t always get all videos from a playlist. Reasons:

  • YT hides those that are not available.
  • Some videos may be private, and you don’t have access.

Just gave it a try with YT’s VH1’s 100 Greatest Hard Rock Songs:

  • Supposedly 100 songs.
  • Reduced to 89 due to YT’s hiding the unavailable.
  • Further reduced (by yt-dlp) to 63 due to some being private.
1 Like