---
date: 2025-04-16T13:22:38+00:00
modified: 2025-04-16T13:22:38+00:00
permalink: https://kaspars.net/note/mastodon-social-114348560144474546
post_type: note
author:
  name: Kaspars
  avatar: https://reverse.kaspars.net/gravatar/avatar/92bfcd3a8c3a21a033a6484d32c25a40b113ec6891f674336081513d5c98ef76?s=96&d=mm&r=g
---

# On April 16, 2025 at 16:22

Native &lt;video&gt; in HTML is extremely good these days. Videos encoded with H264/AAC are universally playable and with HTTP chunk support you can serve the same video to all users.

However, browsers seem to request videos with preload=auto/metadata as soon as the page loads which is unnecessary. So I built this lazy-load solution that hides the src attribute (prevents loading) until an Intersection Observer callback.