🖼️JPEG XL Lands in All Major Browsers, But AVIF Still Wins
AVIF Still Smaller Than JPEG XL for Most Use Cases
TL;DR
JPEG XL is now supported in all major browsers, but AVIF still produces smaller files for most photos. JPEG XL's size advantage is only significant in lossless and existing JPEG compression.
JPEG XL is now supported in all major browsers, but AVIF still produces smaller files for most photos. At default settings, AVIF files are 15-25% smaller than JPEG XL for lossy photos, and this gap narrows slightly at higher settings. For detailed images like screenshots and illustrations, AVIF remains the better choice, with JPEG XL being 30-90% larger. AVIF also offers better HDR support and faster encoding times. JPEG XL shines in lossless compression and making existing JPEGs smaller without further loss. The latest versions of AVIF (1.4.2), libjxl (0.12.0), and jixel (0.4.2) were used in benchmarks, with AVIF producing a file size of 41.4 kB compared to 58.4 kB for JPEG XL (libjxl) and 46.6 kB for JPEG XL (jixel).

Key Points
AVIF files are 15-25% smaller than JPEG XL at default settings for lossy photos.
JPEG XL is 30-90% larger than AVIF for detailed images like screenshots and illustrations.
JPEG XL can make existing JPEGs 9-20% smaller without further loss.
AVIF offers better HDR support and faster encoding times compared to JPEG XL.
Benchmarks used the latest versions of AVIF (1.4.2), libjxl (0.12.0), and jixel (0.4.2).
Why It Matters
If you're optimizing images for web performance, AVIF is still the better choice for most photos and detailed images. JPEG XL is worth considering for lossless compression and making existing JPEGs smaller. The latest benchmarks show AVIF producing smaller files and offering better HDR support, while JPEG XL excels in lossless compression and existing JPEG optimization.
Comments
Be the first to comment
Enjoyed this article?
Get it daily. 7am. Free. Reads in 5 minutes.
Join 3,568 builders reading daily.