youtube-nocookie.com is an official YouTube hostname for embedding videos in Google’s privacy-enhanced mode. It can reduce cookie activity, but it does not eliminate data transfers: the player can store data in the browser, contact Google, and transmit the visitor’s IP address as soon as the iframe loads.
📋 TL;DR • What it is: A legitimate Google domain that serves the same YouTube player through privacy-enhanced mode. • What it changes: Google documents non-personalized ads and views that do not personalize YouTube (YouTube Help). In our signed-out test with DoubleClick requests completing, standard YouTube had five cookies; nocookie had none in its loaded or post-Play snapshots. • What it does not change: The nocookie iframe initialized localStorage and IndexedDB, contacted Google services, and sent a logging request before Play. A lite-youtube façade delayed the player, but its default preview still fetched images from Google. • GDPR: Changing the hostname alone does not make a YouTube iframe compliant. Where consent is required, block the relevant storage and requests until consent exists, or remove the integration. • Outside YouTube: A native video file served from your own site removes the YouTube iframe. Check the replacement’s requests and storage separately.
What is youtube-nocookie.com?
youtube-nocookie.com is a Google-owned domain that serves YouTube videos through what Google calls privacy-enhanced mode. The video, player, and basic embed workflow are still YouTube; the URL simply points the iframe at a different host.
The domain dates back to 2009, when a YouTube spokesperson described creating a delayed-cookie player for videos embedded on U.S. federal government websites, as quoted in a contemporaneous CNET report. A later Cloud Four account of the no-cookie feature records the same host change and historical cookie timing. Google’s current instructions describe changing the iframe hostname to enable privacy-enhanced mode.
Here is the practical difference:
| Mode | Embed URL |
|---|---|
| Standard | https://www.youtube.com/embed/VIDEO_ID |
| Privacy-enhanced | https://www.youtube-nocookie.com/embed/VIDEO_ID |
The ?rel=0 parameter can be added to a YouTube embed URL to restrict suggested videos to the same channel after playback; it controls recommendations, not the consent and privacy questions described below.
What does privacy-enhanced mode actually change?
Google documents two benefits of privacy-enhanced mode:
- Embedded views do not personalize YouTube. Google documentation states that views from privacy-enhanced embeds do not influence the viewer’s YouTube browsing experience or subsequent YouTube viewing experience (YouTube Help).
- Ads are non-personalized. Google’s documentation confirms that ads served in privacy-enhanced mode are non-personalized rather than targeted using the viewer’s profile.
Those personalization limits do not tell you what the iframe sends or stores. That requires a browser capture.
Does youtube-nocookie.com actually stop tracking?
No. Privacy-enhanced mode does not prevent contact with Google or browser storage. In our test, the nocookie player ran JavaScript, wrote browser storage, contacted Google services, and sent a logging request before the viewer clicked Play.
What did we test?
On October 28, 2026, we compared standard and nocookie iframes, default and local-preview lite-youtube façades, and a native video on local pages. Each used a fresh, signed-out, headless Linux Chrome profile. The installed google-chrome-stable package, browser binary and DevTools all reported 156.0.8078.47. Third-party cookies were allowed, with normal storage partitioning enabled.
DevTools captured cookies, including HttpOnly and partitioned cookies, frame-specific localStorage and IndexedDB inventories, and requests. We sampled the fresh profile, eight seconds after load without interaction, and 15 seconds after a trusted Play click. All five videos were unpaused and advanced past 13 seconds.
The ad-host requests were not blocked in this capture. Our local DNS sinkholed two DoubleClick hosts, so we used DNS-over-HTTPS answers to map those hosts to real IPs inside the test browser only. The standard player completed googleads.g.doubleclick.net/pagead/id after a redirect and loaded static.doubleclick.net/instream/ad_status.js, both with final HTTP 200 responses. No requests were intercepted. Other hosts used the normal resolver; no requested host was refused. This removed the observed DNS filter for the comparison without changing system settings.
These are snapshots from one signed-out configuration, not continuous cookie monitoring or a promise for every visitor. The reproduction steps below let you check your own configuration.
What happens in the browser before Play?
The nocookie origin contained two localStorage keys, ytidb::LAST_RESULT_ENTRY_KEY and yt-icons-last-purged, plus an IndexedDB database named YtIdbMeta. Its databases object store was empty. The standard origin had those same localStorage keys and YtIdbMeta, plus a LogsDatabaseV2:… database. The storage names alone do not establish that each item is a tracking identifier.
The embed writes to the browser as it loads, before the viewer decides to watch.
That detail matters because privacy rules are not limited to files named cookies. Article 5(3) of the ePrivacy Directive, explained in the EDPB’s technical-scope guidelines, addresses storing information on, or accessing information from, a user’s device, with exceptions for transmission and strictly necessary storage or access. The Web Storage API and IndexedDB API are both client-side storage systems.
The yt-remote-device-id key was absent before and after Play in both direct embeds. It matters because a 2019 Cookiebot investigation reported it as a localStorage identifier that could enable tracking without video interaction. Older investigations can explain what happened then; they should not be treated as a guaranteed inventory of today’s player.
What data reaches Google before Play?
Before Play, the nocookie iframe contacted www.google.com, fonts.gstatic.com, www.gstatic.com, i.ytimg.com, yt3.ggpht.com, and jnn-pa.googleapis.com, as well as its own youtube-nocookie host. The capture included a /generate_204 beacon and a /youtubei/v1/log_event request.
The standard embed additionally completed requests to googleads.g.doubleclick.net and static.doubleclick.net before Play. Neither host appeared in the nocookie request log. After Play, both direct embeds successfully requested video data from a googlevideo.com subdomain.
Successful requests expose the browser’s connecting IP address to the receiving service. That demonstrates contact, not the purpose of every stored item or how long Google keeps the resulting data.
What happens when the viewer presses Play?
No cookies appeared in the nocookie context’s post-Play snapshot, when the video had advanced to 14.42 seconds. Its localStorage key list and IndexedDB inventory also stayed unchanged. The standard context retained the five .youtube.com cookies already present before Play: __Secure-YNID, __Secure-ROLLOUT_TOKEN, YSC, VISITOR_INFO1_LIVE, and VISITOR_PRIVACY_METADATA. The first two were partitioned cookies. No DoubleClick cookie appeared, despite the completed ad-host responses.
A Play button is not a consent-management system. A visitor can want to watch a video without understanding that the click authorizes a Google iframe to process data. The CNIL’s guidance on third-party cookies and consent says users must be able to choose freely and in an informed manner whether to accept tracking, and it specifically lists embedded YouTube videos among services that can receive or place cookies.
How does youtube-nocookie compare with other players?
All four options below used the same browser version and cookie settings, with the DoubleClick DNS exception active. The native page had no analytics or third-party resources; it is a minimal baseline, not a feature-equivalent managed player.
| Observed behavior | Standard YouTube iframe | youtube-nocookie iframe | Default lite-youtube façade | Native self-hosted <video> |
|---|---|---|---|---|
| Cookies before Play | Five, all on .youtube.com |
None | None | None |
| Browser storage before Play | Two localStorage keys; two IndexedDB databases | Two localStorage keys; YtIdbMeta |
No YouTube frame loaded | None |
| Google contact before Play | Player, supporting services and completed DoubleClick requests | Player and supporting services; no DoubleClick request observed | Two Google-hosted preview images | None |
| Third-party HTTP requests before / after Play | 17 / 22 | 14 / 23 | 2 / 36 | 0 / 0 |
| Cookies after the Play observation window | Same five | None | None | None |
| Player after Play | Video playing | Video playing | Nocookie iframe inserted; video playing | Video playing |
How can you check your own embed?
Save this as embed-check.html in an empty folder:
<!doctype html>
<title>YouTube embed privacy check</title>
<iframe title="Test video" width="640" height="360"
src="https://www.youtube.com/embed/aqz-KE-bpKQ"></iframe>
Serve that folder locally:
python3 -m http.server 8000 --bind 127.0.0.1
- Use a fresh Chrome profile with third-party cookies allowed and no extensions. Open DevTools on a blank tab, select Network, and enable Preserve log before visiting
http://localhost:8000/embed-check.html. - Wait eight seconds without interacting. In Application, record cookies for every listed Google origin, including partitioned cookies, plus localStorage keys and IndexedDB databases. In Network, record request hosts, response statuses and any blocked-cookie reasons.
- Click Play, wait 15 seconds, and record the same inventories again. Confirm the visible playhead advances. If the standard player attempts DoubleClick requests, check whether they complete; a refused or blocked request can hide downstream cookies and requests.
- Close that profile. Repeat in a separate fresh profile after changing only
www.youtube.comtowww.youtube-nocookie.com. For a native control, save your MP4 asclip.mp4in the folder, replace the iframe with<video controls preload="metadata" src="clip.mp4"></video>, and use another fresh profile.
Your browser policy, region and page configuration can change the result. Record those conditions rather than treating a cookie count as a permanent YouTube specification, and do not share cookie values or request tokens.
If you want the performance, branding, and viewer-leakage consequences of YouTube in one place, see why standard YouTube embeds are costly for your site and explore the hidden cost of keeping YouTube on your site. Privacy is only one part of the embed decision.
Is youtube-nocookie.com GDPR compliant?
Not by itself. The hostname switch does not provide a legal basis or obtain consent. Our test still showed client-side storage and Google requests before playback.
Keep the legal questions separate: ePrivacy rules address device storage and access, while GDPR addresses personal-data processing. Your legal reviewer must assess which operations are necessary and which require a prior choice.
Why is a Play button not enough information?
The GDPR’s Article 4(11), reproduced in the EDPB’s consent guidelines, defines consent as freely given, specific, informed, and unambiguous. A normal Play label explains playback, not the identity of a controller or purposes of data processing. That is why the surrounding notice and consent flow matter, especially when storage and network requests happen before the click.
Where consent is required, do not load the iframe before that choice. A façade can delay the iframe, but its preview image and connection hints need review too: a Google-hosted thumbnail can contact Google before the player exists.
Does a lite-youtube façade prevent Google contact?
In the matched October 28 test, Paul Irish’s lite-youtube-embed 0.3.4, with its JavaScript and CSS served locally, created no iframe and no YouTube-origin storage before Play, but fetched two preview images from i.ytimg.com: hqdefault.jpg and sddefault.webp. After the click it inserted a nocookie iframe, created the same two localStorage keys and YtIdbMeta, and played the video; its post-Play cookie snapshot was empty.
A second matched test supplied a local preview image through the component’s background-image style. That version made zero third-party HTTP requests before interaction. After activation it loaded YouTube normally and playback advanced past 14 seconds. This is a useful distinction: delaying the iframe and removing all pre-click Google contact are separate implementation choices.
<lite-youtube
videoid="aqz-KE-bpKQ"
style="background-image: url('/images/local-video-preview.jpg');"
></lite-youtube>
Include the component’s CSS and JavaScript from your own site as in the test. The component also adds Google and DoubleClick preconnect hints on pointer hover or keyboard focus. Our no-interaction snapshots did not exercise those hints, and HTTP request capture is not a DNS/TLS connection audit. A strict consent gate must review that warm-up behavior as well as explain what activation does; the default Play label is not, by itself, a consent notice.
What does a compliant YouTube setup need?
Check three things on the deployed page: when the iframe appears, where the preview comes from, and which connection hints run before activation.
A consent gate must control the integration’s resources, not just change a hostname.
- Use a consent management platform. Configure it to block the iframe until any required consent exists, and verify that behavior rather than relying on a “privacy-enhanced” label.
- Use a two-click façade. Serve the preview locally, explain that activating the video loads YouTube and transfers data, and review hover/focus preconnections as well as iframe insertion.
- Remove YouTube. A player delivered without Google’s iframe avoids that iframe’s request and storage flow.
🎬 Want to remove YouTube from the consent decision? SmartVideo replaces the Google iframe with an ad-free player without YouTube branding, delivered through its own video delivery network. See the YouTube alternative and compare what changes when the player does not route viewers through YouTube.
How do you use youtube-nocookie.com?
How do you enable it from YouTube?
Open the video on YouTube, select Share → Embed, and copy the iframe HTML. Then follow Google’s documented privacy-enhanced setup: change the iframe host from www.youtube.com to www.youtube-nocookie.com.
How do you change an existing embed manually?
Replace the hostname while keeping the video ID and any parameters you need:
<!-- Standard -->
<iframe src="https://www.youtube.com/embed/VIDEO_ID"></iframe>
<!-- Privacy-enhanced -->
<iframe src="https://www.youtube-nocookie.com/embed/VIDEO_ID"></iframe>
Parameters such as ?rel=0 can be appended to a YouTube iframe URL; Google’s player-parameter documentation describes what that setting controls. For a deeper look at iframe syntax and configuration, see how video embed codes work.
How do you use it in WordPress?
The core WordPress YouTube Embed block asks YouTube’s oEmbed provider for an iframe. Our direct request to that provider on October 28 returned www.youtube.com/embed/…, not youtube-nocookie.com. That was a provider-response check, not a rendered WordPress test; plugins and themes can filter the output.
To choose the host explicitly, replace the YouTube Embed block with a Custom HTML block and paste the privacy-enhanced iframe shown above, if your account permits iframe HTML. The unfiltered_html capability controls unrestricted HTML and differs between single-site and Multisite installations. If your account cannot retain the iframe, configure an embed tool instead. Inspect the released page’s iframe to confirm the final host.
For broader setup options, compare WordPress video hosting alternatives and review these methods for embedding video in WordPress.
How long does youtube-nocookie.com keep data?
Our capture establishes that localStorage and IndexedDB existed during the observation window; it does not establish an expiration period. According to MDN’s Web Storage documentation, localStorage normally survives closing and reopening the browser, while private browsing treats it as session-scoped data. Browser eviction and player cleanup can also affect stored data.
None of that tells you how long Google retains server-side request logs, telemetry, or identifiers. Google can also change the player without changing the embed URL. For a privacy review, do not promise that youtube-nocookie data disappears after a session; document the data flow you observed and re-test when the player or consent configuration changes.
If your requirement is to avoid YouTube’s data flow, assess a player that does not use YouTube infrastructure. A different host still needs its own privacy review. The options and trade-offs are covered in this guide to hosting videos without YouTube entirely.
How do you replace YouTube’s player?
To avoid YouTube’s storage and Google requests, serve the video outside YouTube’s iframe through your own infrastructure or a host without ad-tech.
What changes when Google is out of the path?
A native <video> element can play an MP4 without a YouTube iframe. When the file and page come from your own origin, those video requests go to your server. A managed video host uses its own servers or CDN instead; its storage and analytics behavior need a separate check.
We tested that minimal alternative alongside the iframes and façades: a 24-second H.264/AAC MP4 generated with ffmpeg and served from the same local origin as its page, with no analytics. It made four HTTP requests, all local, and had no cookies in any snapshot. Its loaded and post-Play pages also had no localStorage entries or IndexedDB databases. Playback advanced to 14.63 seconds after Play.
A self-hosted video file can play without loading YouTube’s player.
SmartVideo offers an ad-free player without YouTube branding through its own delivery network, according to its YouTube alternative page. For a manual installation outside WordPress, its setup documentation directs you to copy the snippet from the dashboard’s Configuration tab into the page’s <head>, then place a video tag where the video belongs. Replace the example URL below with your MP4’s direct URL:
<smartvideo src="https://your-video.example.com/file.mp4" width="1280" height="720" class="swarm-fluid" controls></smartvideo>
On WordPress, the plugin handles script installation and provides a block and shortcode. On other platforms, use the dashboard-generated snippet plus the video tag. Replacing YouTube’s player changes the service receiving the video requests; it does not remove the need to review that replacement’s data flow.
For a practical comparison of the move away from YouTube, read how to embed video without ads or tracking and review private video hosting options.
Frequently asked questions
These are the questions that come up once you spot youtube-nocookie.com in your page source — or once someone on your legal team asks what that domain is doing on the site.
Is youtube-nocookie.com an official Google domain?
Yes. It is Google’s official privacy-enhanced host for YouTube embeds, so seeing it in an iframe URL is expected. Its legitimacy is separate from its privacy properties: an official domain can still receive an IP address and store browser data.
Does youtube-nocookie.com still use cookies?
In our signed-out Chrome test, the nocookie context had no cookies in the before-Play or post-Play snapshots, even with the ad-host DNS exception active. Historical reports describe cookies appearing after activation. Neither result is a permanent cookie policy: re-test your own deployment with your visitors’ browser settings.
What happens before a youtube-nocookie video is played?
In our test, the nocookie player created YtIdbMeta and two localStorage keys: ytidb::LAST_RESULT_ENTRY_KEY and yt-icons-last-purged. It contacted Google services and sent a log_event request before Play. The empty cookie snapshot did not mean the player was inactive.
Did yt-remote-device-id appear in the test?
No. Neither direct embed contained a yt-remote-device-id localStorage key before or after Play in our run. That absence does not mean there was no browser storage: both origins had other localStorage keys and IndexedDB databases.
Is youtube-nocookie.com GDPR compliant by itself?
The hostname change does not obtain consent or supply a legal basis for processing. Where prior consent is required, prevent the iframe and related requests from loading until the visitor chooses.
Does clicking Play count as GDPR consent?
A bare Play label explains playback, not third-party processing. CNIL’s guidance requires a free and informed choice about tracking. Explain who receives data and why before activation.
How long does youtube-nocookie keep local data?
The test did not measure an expiration period. MDN documents that localStorage normally survives browser restarts, although private browsing is different and browsers can remove stored data. Do not infer session-only retention, or Google’s server-side retention, from an empty cookie jar.
Does youtube-nocookie.com block ads?
No. Privacy-enhanced mode allows ads to appear, but YouTube Help documents them as non-personalized rather than targeted using the viewer’s profile. Privacy-enhanced mode is not an ad-removal setting.
How do I enable privacy-enhanced mode?
Copy the iframe from YouTube’s Share → Embed dialog, then replace www.youtube.com with www.youtube-nocookie.com in the iframe src attribute while keeping the video ID and parameters. This is the manual host change documented by YouTube Help.
How can I embed video without cookies or third-party tracking?
A façade can delay the iframe, but a default Google-hosted preview still makes third-party requests. Use a local preview and review connection warm-ups if pre-consent contact must be prevented. To remove YouTube after activation as well, use a player outside YouTube and audit that replacement’s requests and storage.
The bottom line
youtube-nocookie.com is legitimate, and Google’s documented limits on personalization are useful when you still need YouTube.
But an empty cookie jar is not an empty data flow. The nocookie iframe wrote browser storage and contacted Google before Play. Choose the implementation around the requirement: fewer personalization effects, no iframe before consent, or no YouTube player at all.
For a site that wants video without YouTube’s ads, branding, viewer leakage, and Google iframe, compare SmartVideo with your current player. SmartVideo’s pricing page lists a 14-day free trial: a credit card is required, with no charge until day 15.