Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> Now that WebP is widely supported by browsers and operating systems, there's really no downside to using it. It's much more flexible than JPEG or PNG and offers better compression than both of them.

I'd probably skip WebP, and go straight to AVIF at this point. I believe all modern browsers support it, and it compresses better than WebP.



> I'd probably skip WebP, and go straight to AVIF now.

That is my assessment as well. The compression ratios with AVIF are ridiculous compared to older formats.


It's great but you definitely pay for it. Encoding can be really slow, and to a lesser extent decoding as well.

So I still end up using .jpg quite often, or .webp as a good middle ground


You can adjust how much "effort" the avif encoder puts on images.

The default speed in libavif (-s 6 in avifenc) is fast enough, and it has been used by big CDNs to encode AVIFs for years. You can make the encoder as fast or slow as you'd like, depending on your compute/compression efficiency trade-off requirements.


TIL that AVIF has been supported across all browsers since January 2024. Definitely looks like something I can start using.


Personally I dislike all of these new formats. Shame that most big sites use either avif or webp. When I save these images to disk I always convert to png because storage isn't an issue and bandwidth isn't an issue. Oh well...


> storage isn't an issue and bandwidth isn't an issue. Oh well...

Right; the issue is compatibility. But that doesn't get solved if we collectively stick to the past and only use old formats like gif and jpeg. Compatibility gets fixed by using a format, and then complaining to software developers when their software isn't compatible with our workflows. Eventually compatibility improves, and we get our cake and eat it too. Better storage and bandwidth use. And compatibility across all our software.

It just takes time.


In lossless mode WebP is superior to AVIF.




Consider applying for YC's Winter 2027 batch! Applications are open till November 2.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: