Description
Youtarr can fail to download certain publicly available YouTube videos when cookies are enabled.
yt-dlp reports:
ERROR: [youtube] <video-id>: Video unavailable
However, the exact same video succeeds when yt-dlp is run without cookies.
I have seen this affect multiple videos from the same channel repeatedly over more than a week.
Youtarr currently retries the affected video on subsequent channel scans using cookies again, so it keeps failing with the same error.
Environment
- Youtarr: v1.81.1
- yt-dlp: stable@2026.08.19
- Python: 3.11.2
- ffmpeg: 5.1.9
- Docker on Linux
- Cookies enabled using Youtarr's uploaded cookie file
- yt-dlp IP family: IPv4
Reproduction
Affected video:
https://www.youtube.com/watch?v=kLibHr-jNeE
Without cookies:
docker exec -it youtarr yt-dlp -vU --simulate \
"https://www.youtube.com/watch?v=kLibHr-jNeE"
This succeeds:
[youtube] kLibHr-jNeE: Downloading visionos player API JSON
[info] kLibHr-jNeE: Downloading 1 format(s): 401+251-5
With cookies:
docker exec -it youtarr yt-dlp -vU --simulate \
--cookies /app/config/cookies.user.txt \
"https://www.youtube.com/watch?v=kLibHr-jNeE"
This fails:
[debug] [youtube] Found YouTube account cookies
[debug] [youtube] kLibHr-jNeE: web_embedded player response playability status: UNPLAYABLE
[debug] [youtube] kLibHr-jNeE: tv_downgraded player response playability status: UNPLAYABLE
ERROR: [youtube] kLibHr-jNeE: Video unavailable
Forcing tv_downgraded with cookies also fails:
--extractor-args "youtube:player_client=tv_downgraded"
visionos cannot be used while cookies are enabled:
WARNING: [youtube] Skipping client "visionos" since it does not support cookies
But adding --no-cookies after the cookie option succeeds:
docker exec -it youtarr yt-dlp -vU --simulate \
--cookies /app/config/cookies.user.txt \
--no-cookies \
"https://www.youtube.com/watch?v=kLibHr-jNeE"
Result:
[youtube] kLibHr-jNeE: Downloading visionos player API JSON
[info] kLibHr-jNeE: Downloading 1 format(s): 401+251-5
Working proof-of-concept
I patched Youtarr locally using its existing auto-retry system.
The logic is:
- Normal download runs with cookies.
- An individual video fails with
Video unavailable.
- If cookies are enabled, Youtarr marks that failed video for an anonymous retry.
- Only that video is queued again.
- The retry adds
--no-cookies.
- yt-dlp uses the visionos client.
- The download succeeds.
This was tested during an actual scheduled Youtarr channel download.
The logs showed:
ERROR: [youtube] kLibHr-jNeE: Video unavailable
Then:
Then:
Retrying cookie-specific Video unavailable failure without cookies
The retry yt-dlp arguments contained:
--cookies /app/config/cookies.user.txt
...
--no-cookies
https://www.youtube.com/watch?v=kLibHr-jNeE
Then:
[youtube] kLibHr-jNeE: Downloading visionos player API JSON
[info] kLibHr-jNeE: Downloading 1 format(s): 299+140-5
and the video downloaded successfully.
Proposed behaviour
When:
- cookies are enabled
- an individual video fails with
Video unavailable
- the video is not members-only, upcoming, a premiere, terminated, etc.
Youtarr should retry only that failed video once without cookies.
Cookies should not be disabled globally because they are still needed for other videos and YouTube bot checks.
Implementation notes
Youtarr already has most of the required infrastructure through:
transient403RetryPlanner.js
downloadJobFinalizer.js
enqueueAutoRetryJob()
doSpecificDownloads()
The working local patch:
- detects cookie-specific
Video unavailable
- carries an
anonymousRetry flag
- separates normal authenticated retries from anonymous retries
- appends
--no-cookies only to the anonymous retry job
- keeps normal 403 retries authenticated
- continues to use the existing retry-attempt limit
Additional affected video
I have also seen repeated Video unavailable failures with:
So this appears to affect multiple videos, not just one.
Expected result
Youtarr should continue using cookies normally, but automatically fall back to an anonymous retry for an individual public video when authenticated extraction incorrectly returns Video unavailable.
Description
Youtarr can fail to download certain publicly available YouTube videos when cookies are enabled.
yt-dlp reports:
However, the exact same video succeeds when yt-dlp is run without cookies.
I have seen this affect multiple videos from the same channel repeatedly over more than a week.
Youtarr currently retries the affected video on subsequent channel scans using cookies again, so it keeps failing with the same error.
Environment
Reproduction
Affected video:
Without cookies:
This succeeds:
With cookies:
This fails:
Forcing tv_downgraded with cookies also fails:
visionos cannot be used while cookies are enabled:
But adding --no-cookies after the cookie option succeeds:
Result:
Working proof-of-concept
I patched Youtarr locally using its existing auto-retry system.
The logic is:
Video unavailable.--no-cookies.This was tested during an actual scheduled Youtarr channel download.
The logs showed:
Then:
Then:
The retry yt-dlp arguments contained:
Then:
and the video downloaded successfully.
Proposed behaviour
When:
Video unavailableYoutarr should retry only that failed video once without cookies.
Cookies should not be disabled globally because they are still needed for other videos and YouTube bot checks.
Implementation notes
Youtarr already has most of the required infrastructure through:
transient403RetryPlanner.jsdownloadJobFinalizer.jsenqueueAutoRetryJob()doSpecificDownloads()The working local patch:
Video unavailableanonymousRetryflag--no-cookiesonly to the anonymous retry jobAdditional affected video
I have also seen repeated
Video unavailablefailures with:So this appears to affect multiple videos, not just one.
Expected result
Youtarr should continue using cookies normally, but automatically fall back to an anonymous retry for an individual public video when authenticated extraction incorrectly returns
Video unavailable.