惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Y
Y Combinator Blog
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
V
V2EX
博客园 - 三生石上(FineUI控件)
Hugging Face - Blog
Hugging Face - Blog
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
罗磊的独立博客
博客园_首页
量子位
雷峰网
雷峰网
GbyAI
GbyAI
小众软件
小众软件
酷 壳 – CoolShell
酷 壳 – CoolShell
D
DataBreaches.Net
H
Hackread – Cybersecurity News, Data Breaches, AI and More
The Cloudflare Blog
IT之家
IT之家
WordPress大学
WordPress大学
人人都是产品经理
人人都是产品经理
Apple Machine Learning Research
Apple Machine Learning Research
P
Proofpoint News Feed
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
博客园 - 聂微东

Mozilla Hacks – the Web developer blog

PACT: Anonymous Credentials for the Web – Mozilla Hacks - the Web developer blog Announcing Web Serial Support in Firefox – Mozilla Hacks - the Web developer blog Behind the Scenes Hardening Firefox with Claude Mythos Preview – Mozilla Hacks - the Web developer blog Trustworthy JavaScript for the Open Web – Mozilla Hacks - the Web developer blog Firefox Developer Edition and Beta: Try out Mozilla’s .rpm package! – Mozilla Hacks - the Web developer blog Why is WebAssembly a second-class language on the web? – Mozilla Hacks - the Web developer blog Goodbye innerHTML, Hello setHTML: Stronger XSS Protection in Firefox 148 – Mozilla Hacks - the Web developer blog Launching Interop 2026 – Mozilla Hacks - the Web developer blog CRLite: Fast, private, and comprehensive certificate revocation checking in Firefox – Mozilla Hacks - the Web developer blog Improving Firefox Stability in the Enterprise by Reducing DLL Injection – Mozilla Hacks - the Web developer blog Launching Interop 2025 – Mozilla Hacks - the Web developer blog Introducing Uniffi for React Native: Rust-Powered Turbo Modules – Mozilla Hacks - the Web developer blog Llamafile v0.8.14: a new UI, performance gains, and more – Mozilla Hacks - the Web developer blog 0Din: A GenAI Bug Bounty Program – Securing Tomorrow’s AI Together – Mozilla Hacks - the Web developer blog Announcing Official Puppeteer Support for Firefox – Mozilla Hacks - the Web developer blog Snapshots for IPC Fuzzing – Mozilla Hacks - the Web developer blog Sponsoring sqlite-vec to enable more powerful Local AI applications – Mozilla Hacks - the Web developer blog Experimenting with local alt text generation in Firefox Nightly – Mozilla Hacks - the Web developer blog Llamafile’s progress, four months in – Mozilla Hacks - the Web developer blog Porting a cross-platform GUI application to Rust – Mozilla Hacks - the Web developer blog
Intent to Ship: JPEG XL – Mozilla Hacks - the Web develop...
By Jake Archibald · 2026-08-24 · via Mozilla Hacks – the Web developer blog

It isn’t often that new image formats land in browsers. In the early 2000s we had JPEG, GIF, and PNG. The 2010s gave us WebP, which was a modest step up from JPEG. But the 2020s have given us two new image formats that are a big step up from previous formats: AVIF and JPEG XL.

We shipped AVIF back in 2021, and today we posted our intent to ship JPEG XL. Chrome are also intended to ship, and given there’s already a partial implementation in Safari, the format will be supported across browsers before the end of the year.

Shipping JPEG XL securely

We added experimental support for JPEG XL behind a flag back in 2021. But, at 100,000 lines of multithreaded C++, we were concerned about the attack surface this added to Firefox.

So, we laid down a challenge to the JPEG XL team at Google Research: Build a safe, performant, compact, and compatible JPEG XL decoder in Rust, and we’ll ship it. That challenge was met; Google Research built jxl-rs, and it’s the core of our JPEG XL support in Firefox.

We also pushed for high quality integration tests to be part of Interop 2026, and they’re coming along nicely.

Progressive rendering

Although Safari shipped JPEG XL in 2023, their implementation lacked some key features of JPEG XL – our favourite is progressive rendering, which is something we pushed for in the Rust implementation.

Progressive rendering means the image can render as it’s downloading.

An image of a fox curled up in a ball, sleeping amongst some grass, divided into four columns, showing JPEG XL progressive rendering. At 4% it's very blurry. At 15% you can tell it's a picture of a fox. At 50% the full image is clear, but not full resolution. At 100% it's full resolution.

Although the full image is 135 kB, with only a few kB downloaded the user can determine the subject of the image. Try the above demo image in a browser that supports JPEG XL & progressive rendering, like Firefox Nightly – move the slider to see how the image displays with just a portion downloaded.

JPEG XL vs AVIF

Browsers will now have two modern image formats for developers to choose from. Which you choose depends on your use-case.

  • JPEG XL: Excels at lossless imagery, progressive rendering, and further compressing JPEGs without quality loss.
  • AVIF: Excels at web-quality photographic images, and images that have a mix of sharp edges and flat surfaces.

For example:

A fox curled up in a ball, sleeping amongst some grass.

The image above is a 116 kB AVIF with a quality score (SSIMULACRA 2) of 62.8, meaning medium-high quality. To get the same quality, the JPEG XL image would be 134 kB.

At a SSIMULACRA 2 score of 80 (very high quality), the AVIF is 227 kB, and the JPEG XL is 264 kB.

But at lossless, the AVIF is 1.76 MB, and the JPEG XL is 1.45 MB. A lossless WebP is 1.55 MB.

Another example is a screenshot of the Interop 2025 scores:

Interop dashboard showing browser scores. At the top are two large circles: ‘Interop’ with a score of 95 in green, and ‘Investigations’ with a score of 36 in orange. Below are four browser scores in green circles: Chrome 99, Edge 98, Firefox 99, and Safari 98, each shown with their respective browser icons.

At a SSIMULACRA 2 score of 78 (very high quality), the AVIF is 11.6 kB, and the JPEG XL is 23.8 kB.

But at lossless, the AVIF is 164 kB, and the JPEG XL is 92 kB. A lossless WebP is 96 kB.

Although AVIF tends to produce smaller files at web-quality than JPEG XL, AVIF only has basic progressive rendering support. So, for very large images, it may be worth taking the filesize hit with JPEG XL.

The key is to test with a representative set of images for your site, at a quality that works best for your users, and remember to optimise for high density.

More articles by Jake Archibald…