Published at
Updated at
Reading time

Do you remember Facebook's hugely popular like button? A quick-to-add JS snippet enabled site owners to implement Facebook functionality, and the social media giant started tracking people across the web.

It's been wild times, and luckily, things are different today. People are more privacy aware, (some) browsers started blocking all these trackers, and I stopped using Facebook years ago.

But I do watch many YouTube videos. And this made me think: how does YouTube treat privacy when you embed a video?

I was delighted to learn about YouTube's privacy-enhanced embed mode!

YouTube embed dialog with a "enabled privacy-enhanced mode" checkbox.

If you turn it on, the iframe source changes from[ID] to[ID]. That's pretty cool!

But unfortunately, I just stumbled upon Jason Grigsby's disappointment about the feature.

So what's up?

First, the domain seemed to have been a cute developer idea until the business decided that dropping all cookies isn't great for the ad monetization model. does not mean no cookies.

Info text: When you turn on privacy-enhanced mode, YouTube won't store information about visitors on your website unless they play the video.

"We won't store user info unless you interact with the embed".

Ouch... but fair; YouTube doesn't hide what they're doing here. isn't more than an unfortunate domain choice, but hey, we've all bought silly domains at some point, right?

But it's not okay that the explainer claims that the embed only starts storing user info after an interaction.

I just tried it out, and look what I've found in my localstorage. 🤦‍♂️

Localstorage entry set by

So much about, "we won't store user info unless you play the video". Not cool, YouTube. Really not cool!

Was this post helpful?
Yes? Cool! You might want to check out Web Weekly for more WebDev shenanigans. The last edition went out 8 days ago.
Stefan standing in the park in front of a green background

About Stefan Judis

Frontend nerd with over ten years of experience, freelance dev, "Today I Learned" blogger, conference speaker, and Open Source maintainer.

Related Topics

Related Articles