CompuServe introduced GIF in 1987 to move colour images across slow modems; a palette of 256 colours was a reasonable compromise then. Animation arrived with GIF89a in 1989, and the format’s fate was sealed: it became the internet’s default moving image for three decades, long past the point where that made sense.
01The GIF problem
The technical problems compound. Indexed colour limits every frame to 256 shades, so anything photographic looks posterised. There is no audio, and no compression between frames — each is individually LZW-compressed, a codec never designed for video. A five-second clip that would be 300 KB as H.264 routinely runs 3–8 MB as a GIF. Yet it persisted because it worked everywhere: drop it in an <img> tag and it plays.
02What actually beats it
For anything longer than a short loop, video is what every platform uses internally. Deliver it so the browser treats it like a GIF — no controls, silent, looping:
<video autoplay loop muted playsinline>
<source src="clip.webm" type="video/webm">
<source src="clip.mp4" type="video/mp4">
</video>