Skip to content

Commit 2e8c3a3

Browse files
authored
[youtube] Suggest mweb instead of web (#53)
1 parent d2db3bd commit 2e8c3a3

File tree

2 files changed

+11
-11
lines changed

2 files changed

+11
-11
lines changed

Extractors.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
>
66
> By default, yt-dlp will attempt to download videos using clients that do not currently require a PO Token. However, some formats and features may not be available without the token(s).
77
>
8-
> At this time, it is **recommended** to use provide a PO Token to use with the `web` client. Refer to the [PO Token Guide](https://github.com/yt-dlp/yt-dlp/wiki/PO-Token-Guide) on how to set up yt-dlp for this.
8+
> At this time, if you are having issues with the default clients, it is suggested to use the `mweb` client with a PO Token. Refer to the [PO Token Guide](https://github.com/yt-dlp/yt-dlp/wiki/PO-Token-Guide) on how to set up yt-dlp for this.
99
1010
## Exporting YouTube cookies
1111

PO Token Guide.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
# YouTube PO Token Guide
44

55
> [!TIP]
6-
> TL;DR recommended setup: Either use a [plugin](#plugins), or [manual extraction](#guide-providing-a-po-token-manually-for-use-with-web-client), to provide the `web` client with a [PO Token for GVS requests](#cases-where-a-po-token-is-required).
6+
> TL;DR recommended setup: Either use a [plugin](#plugins), or [manual extraction](#guide-providing-a-po-token-manually-for-use-with-mweb-client), to provide the `mweb` client with a [PO Token for GVS requests](#cases-where-a-po-token-is-required).
77
>
88
> See the notice in the [YouTube Extractor Wiki](https://github.com/yt-dlp/yt-dlp/wiki/Extractors#youtube) for more information on the current state of downloading videos from YouTube.
99
@@ -50,12 +50,12 @@ YouTube is at present rolling out changes to enforce PO Tokens for video playbac
5050

5151
| Client | PO Token for GVS Required | PO Token for Player Required | Notes |
5252
|----------------|---------------------------|------------------------------|---------------------------------------|
53-
| `web` | Yes | No | |
53+
| `web` | Yes | No | Only SABR formats available |
5454
| `web_safari` | Yes* | No | |
5555
| `mweb` | Yes | No | |
5656
| `tv` | No | No | |
5757
| `tv_embedded` | No | No | Requires account cookies |
58-
| `web_embedded` | No | No | |
58+
| `web_embedded` | No | No | Only embeddable videos available |
5959
| `web_music` | Yes | No | |
6060
| `web_creator` | Yes | No | Requires account cookies |
6161
| `android` | Yes | ? | Account cookies not supported |
@@ -66,14 +66,14 @@ YouTube is at present rolling out changes to enforce PO Tokens for video playbac
6666

6767
You can select what client to use with the [`player_client` extractor argument](https://github.com/yt-dlp/yt-dlp#youtube).
6868

69-
## Guide: Providing a PO Token manually (for use with `web` client)
69+
## Guide: Providing a PO Token manually (for use with `mweb` client)
7070

71-
This section provides a basic guide on extracting PO Token(s) manually from YouTube in a web browser **for use with the `web` client**, and manually passing it to yt-dlp via the [`po_token` extractor argument](https://github.com/yt-dlp/yt-dlp#youtube).
71+
This section provides a basic guide on extracting PO Token(s) manually from YouTube in a web browser **for use with the `mweb` client**, and manually passing it to yt-dlp via the [`po_token` extractor argument](https://github.com/yt-dlp/yt-dlp#youtube).
7272
The same PO Token extraction method _may_ work with other web browser-based clients too.
7373

7474
> [!TIP]
7575
> When supplying multiple PO Tokens, use the same extractor args option and comma-separate the PO Token configurations. For example:
76-
> `--extractor-args "youtube:po_token=web.gvs+GVS_PO_TOKEN_VALUE_HERE,web.player+PLAYER_PO_TOKEN_VALUE_HERE"`
76+
> `--extractor-args "youtube:po_token=mweb.gvs+GVS_PO_TOKEN_VALUE_HERE,mweb.player+PLAYER_PO_TOKEN_VALUE_HERE"`
7777
7878

7979
### PO Token for GVS
@@ -88,7 +88,7 @@ The PO Token used for `web` GVS requests is tied to your YouTube session. It gen
8888
4. Filter requests by `googlevideo.com`
8989
5. Click the video and play for a few seconds - requests to `googlevideo.com` should appear in the network tab
9090
6. From the most recent `googlevideo.com` request, extract the `pot` query parameter value from the URL
91-
7. Pass the PO Token for GVS to yt-dlp using `--extractor-args "youtube:po_token=web.gvs+PO_TOKEN_VALUE_HERE"` with cookies (`--cookies COOKIES_FILE` or `--cookies-from-browser`)
91+
7. Pass the PO Token for GVS to yt-dlp using `--extractor-args "youtube:player-client=default,mweb;po_token=mweb.gvs+PO_TOKEN_VALUE_HERE"` with cookies (`--cookies COOKIES_FILE` or `--cookies-from-browser`)
9292

9393
Although not recommended, you may also provide visitor data instead of cookies. Refer to [Passing Visitor Data without cookies](https://github.com/yt-dlp/yt-dlp/wiki/Extractors#passing-visitor-data-without-cookies).
9494

@@ -97,7 +97,7 @@ Although not recommended, you may also provide visitor data instead of cookies.
9797
1. Open [YouTube Music](https://music.youtube.com) in a browser, and log in with the user you are using with yt-dlp
9898
2. Open any video
9999
3. Follow steps 3-6 above
100-
4. Pass the PO Token for GVS to yt-dlp using `--extractor-args "youtube:po_token=web.gvs+PO_TOKEN_VALUE_HERE"` [with your account cookies ](https://github.com/yt-dlp/yt-dlp/wiki/Extractors#exporting-youtube-cookies)
100+
4. Pass the PO Token for GVS to yt-dlp using `--extractor-args "youtube:player-client=default,mweb;po_token=mweb.gvs+PO_TOKEN_VALUE_HERE"` [with your account cookies ](https://github.com/yt-dlp/yt-dlp/wiki/Extractors#exporting-youtube-cookies)
101101

102102
Addendum:
103103
- If there is no `pot` parameter in the `googlevideo.com` URL, wait a few seconds for more requests to be made and check them.
@@ -107,7 +107,7 @@ Addendum:
107107

108108
### PO Token for Player
109109

110-
The PO Token for `web` Player requests is tied to the Video ID. This means you must generate a new PO Token for each video.
110+
The PO Token for `web`/`mweb` Player requests is tied to the Video ID. This means you must generate a new PO Token for each video.
111111

112112
> [!NOTE]
113113
> If you are using the `web` client and have not disabled the `webpage` request, providing this PO Token is not necessary at this time.
@@ -117,7 +117,7 @@ The PO Token for `web` Player requests is tied to the Video ID. This means you m
117117
3. Navigate to the video you want to download (e.g. using search - do not go to the video url directly as the page will refresh)
118118
4. In the request payload JSON, find the PO Token at `serviceIntegrityDimensions.poToken` and save that value
119119
5. Export cookies from the browser
120-
6. Pass the PO Token for Player to yt-dlp using `--extractor-args "youtube:po_token=web.player+PO_TOKEN_VALUE_HERE"`
120+
6. Pass the PO Token for Player to yt-dlp using `--extractor-args "youtube:player-client=default,mweb;po_token=mweb.player+PO_TOKEN_VALUE_HERE"`
121121

122122
## Plugins
123123

0 commit comments

Comments
 (0)