WebP was a genuine improvement over JPEG when Google released it in 2010. It offered 25 to 34% smaller files at comparable quality and it eventually won broad browser support after a decade of slow adoption. For most websites through most of the 2010s, converting to WebP was the right call and it still is if you're currently serving JPEG. But if you're already on WebP and wondering whether AVIF is worth the migration, the answer depends on how much you care about the last 15 to 30% of file size savings.
AVIF is built on AV1, the same codec that powers high-quality streaming video at low bitrates. It was designed from the start to achieve better compression than anything that came before it, and it delivers on that promise. A WebP image at quality 80 and an AVIF image that looks visually identical typically differ by 15 to 30% in file size, with AVIF being smaller. For a blog or small website, that difference is modest. For a platform serving millions of images daily, it's substantial in CDN costs and bandwidth.
The encoding speed tradeoff is real
The honest limitation of AVIF is how long it takes to encode. WebP encodes fast enough that you barely notice it. AVIF can take 5 to 30 seconds per image in a browser, depending on image size and device speed. On a modern laptop with a fast processor, a typical web image takes 3 to 8 seconds. On an older phone, it can take much longer.
For one-off conversions this is fine. For batch converting a product catalog of 500 images, it's slow. In that case, server-side tools like libavif or ImageMagick with AV1 support handle the encoding much faster than a browser can. This converter is best suited for individual images or small batches where you want a quick result without installing anything.
Serving AVIF safely alongside WebP
AVIF at 95% browser support means 5% of visitors on older browsers won't see the image at all if you serve only AVIF. The solution is the HTML <picture> element, which lets you offer AVIF first and WebP as a fallback. The browser picks the best format it supports automatically. You get AVIF for modern browsers and WebP for everything else. This two-format approach gives you the full compression benefit without dropping support for any user.