Playlists and Archives
A playlist URL — a channel page, an album, a series — is where yt-dlp earns its keep: point it at the list and it works through the items one by one. This chapter ran in the lab against the Blender Foundation's channel on its PeerTube instance, which the extractor reads as a playlist of 23 films and extras (transcript t12).
Look at the list first
yt-dlp --flat-playlist \
--print "%(playlist_index)02d. %(title)s" \
https://video.blender.org/c/blender_open_movies
--flat-playlist lists the items without
visiting each one — fast, and the right
way to see what a URL actually contains
before committing to it. The shape of the
address matters: the channel's /c/…
page works; its /video-channels/…/videos
page does not, and the extractor says so
plainly ("Unsupported URL"). When a page
refuses, try the site's other addresses
for the same list before concluding
anything.
The flat listing also shows what the
channel page does not know: every
duration came back NA. Deeper facts
require visiting each item — which is
what a real download does.
Download some of it
yt-dlp --playlist-items 1 \
-f "b[height<=360]/b" \
-o "playlist/%(playlist_index)02d - %(title)s.%(ext)s" \
https://video.blender.org/c/blender_open_movies
--playlist-items takes item numbers
(and ranges: 1-3,7). The lab took item
1 — the OVERGROWN teaser — and the
transcript keeps the whole run, including
the format surprise dissected in chapter
5: the file that landed is 33.24 MiB and
sharp enough to project, whatever the
request said. Check the transcript's
ffprobe lines: 2578x1080 picture, stereo
sound, 1 minute 21 seconds. Whole-list
downloads work the same way with no
--playlist-items at all; the lab
verified one item of 23 rather than
fetching a channel's entire catalogue,
and says so.
The download archive
Playlists invite repetition — run the same command next month for the new items, not the whole list again:
yt-dlp --download-archive archive.txt <playlist URL>
Every finished download appends one line — the extractor's name and the item's ID:
archiveorg big-buck-bunny-720-10s-5-mb-1
On later runs, listed items are skipped before any downloading starts:
[download] big-buck-bunny-720-10s-5-mb-1: has already been recorded in the archive
Transcript t13 shows the lab's archive doing exactly this on its second run. Two properties worth knowing:
- The archive is consulted early — so
early that even
yt-dlp -Frefuses an archived item until the line is removed or--no-download-archiveis passed. The lab met this by accident; chapter 14 keeps it as a symptom. - It records by ID, not by filename. Rename or move the downloaded file and the archive still knows you have it; delete the archive line if you truly want the item fetched again.
Keep one archive per collection, in the folder with the downloads. Chapter 9 shows the archive living in a config file instead — which is where the lab's story about it begins.