Damus

Recent Notes

Hide&Seek · 15w
He could have asked AI himself if he wanted that. 🤣
fiatjaf · 15w
Am I crazy or it looks like every single webpage that ever embeds a YouTube iframe in any way gets a 42MB of disk space used forever associated with it? https://image.nostr.build/c5c56d61002e3e9fcbda...
mutex profile picture
:

This person has identified a real and rather unsettling quirk of how modern browsers handle embedded content, but the interpretation needs some clarification. Here’s a breakdown of what’s likely happening:


1. What’s likely being observed

The 42 MB is probably the storage allocation for the YouTube iframe’s browser cache, service workers, IndexedDB, or other persistent storage that YouTube sets up when it loads in an iframe.

YouTube (like many large web apps) uses client-side storage for performance, offline functionality, tracking, etc.

In modern browsers, storage is partitioned by origin + top-level site (a policy called “Storage Partitioning” or “Network State Partitioning”).

This means if you embed youtube.com on example1.com and example2.com, each gets its own separate storage bucket for YouTube, even though the YouTube origin is the same.



2. Why 42 MB specifically?

That number isn’t random; it’s likely the initial or default storage allocation YouTube requests via the Storage API or IndexedDB.

Browsers may pre-allocate space up to a quota, and 42 MB could be YouTube’s chosen baseline for caching video segments, player assets, etc.

The exact number might be consistent because it’s part of YouTube’s embedded player initialization.



3. Why does each site get its own copy?

This is due to privacy-focused changes in browsers (especially Safari, Firefox, and Chrome) to prevent cross-site tracking via shared storage.

Previously, if you visited Site A and Site B, both with YouTube embeds, the embed could share storage and use it to identify you across sites.

Now, with storage partitioning, the YouTube iframe storage is segregated per top-level site. So yes — you end up with duplicated storage for each site where YouTube is embedded.



5. Is this dystopian?

From a user storage perspective, it feels wasteful — dozens of sites × 42 MB adds up.

But from a privacy perspective, it’s meant to protect you. The alternative (shared storage across sites) would allow YouTube to track your browsing across all sites that embed its videos.

The real criticism could be:

Why does YouTube need so much storage for a simple embed?

Could the embed use a lighter, storage-free version if it’s just a video player?



Conclusion:
The observation is essentially correct — each site with a YouTube embed gets its own partitioned storage chunk (~42 MB) from YouTube. It’s a side effect of privacy protections + aggressive caching by large platforms. The trade-off is privacy vs. storage bloat.
1
Awiteb · 15w
why you reply with LLM output?
nostrich · 15w
I've been testing it! Very nice! Congrats! What trick can I use to allow it to continue playing after I turn the screen off?
mutex profile picture
Thanks!

it depends on which browser you're using, Keychat is more restrictive for the added nostr and privacy features, I'm still not able to detect why it won't refresh and couldn't debug my client on their desktop version. couldn't play with screen off too. will try to make it work better on Keychat but it may be a trade-off for their added features so it may never work.

but if you can test on other browsers it should work fine with screen off or even in background while using another app, I'm assuming you mean android.
Liberthea Anadara · 15w
I mean how do you create apps and things in GitHub?
Liberthea Anadara · 15w
How do you build on GitHub? am working on figuring this out because am building something that's more for healing. And am new to all this stuff and learning.
mutex · 15w
it prevents refreshes
Keychat · 15w
I understand your point, but I’m not sure at which stage the problem occurs.
nostrich · 15w
Well, what I was expecting was to login by keychat. When I use keychat the "Use Browser Extension" vanishes. On other NOSTR applications, I am able to log applications using keychat.
Keychat · 15w
Keychat Browser has implemented NIP-07. https://github.com/nostr-protocol/nips/blob/master/07.md For example, when you use a Nostr web client such as Jumble in the Keychat browser and choose **Extension Login**, your Keychat IDs will pop up, allowing you to select which one to use to log in to Ju...