Jump to main content

Nicolas Hoizey

  • articles
  • billets
  • links
  • notes
  • talks
  • archives
  • about

Note from 16 October 2021

  • Nicolas Hoizey
  • 16 October 2021
  • CanIUse, image, WebPerf
  • 44 reactions

JPEG XL competes with AVIF which has similar compression quality but fewer features overall

This is on #CanIUse page for JPEG XL: https://caniuse.com/jpegxl

I'm not sure @jonsneyers would approve… 😅

44 reactions

6 likes

  1. Jim avatar
  2. George Liu avatar
  3. Richard Yeo avatar
  4. Jon Sneyers 🔻 avatar
  5. Joan León 🏞⚡️ avatar
  6. Alistair Shepherd avatar

38 replies

  1. Jyrki Alakuijala avatar Jyrki Alakuijala
    JPEG XL compresses significantly (~25 %) more in the Web quality range. Think libjpeg quality 75-95.
    • 16 October 2021, 00:34
    • Source
  2. Jim avatar Jim
    I would say 50+. Once you go below 50 it becomes a mixed bag. Sometimes AVIF looks better and sometimes JXL does - depends on the image content.
    • 16 October 2021, 00:44
    • Source
  3. Jon Sneyers 🔻 avatar Jon Sneyers 🔻
    Very roughly speaking, I'd say avif is better at q<30, jxl and avif are similar at q around 50, and jxl is better at q>60 (significantly better at q>80).

    "Web quality" is typically q70-90, "Camera quality" is q92-98.
    • 16 October 2021, 08:50
    • Source
  4. Nicolas Hoizey avatar Nicolas Hoizey
    How/where is q<30 useful?

    (I really don’t like LQIP 😅)
    • 16 October 2021, 09:49
    • Source
  5. Anton avatar Anton
    I wrote that note. Which part of it do you disagree with?
    • 16 October 2021, 11:06
    • Source
  6. Jon Sneyers 🔻 avatar Jon Sneyers 🔻
    I don't think it is very useful at all. Maybe when filesize/bandwidth is really, really more important than image fidelity, or if you have manual inspection to check that the artifacts are not excessive. You're probably better off just sending a lower res image though.
    • 16 October 2021, 11:10
    • Source
  7. Nicolas Hoizey avatar Nicolas Hoizey
    2 parts:
    - compression quality:
    - features
    • 16 October 2021, 11:53
    • Source
  8. Jyrki Alakuijala avatar Jyrki Alakuijala
    Mobile bandwidth 3x'ed in last 5 years. Screen resolutions didn't increase much, and image resolutions increased less.

    Because of these trends I believe the future is for shinier pixels at higher quality.
    • 16 October 2021, 11:55
    • Source
  9. Jyrki Alakuijala avatar Jyrki Alakuijala
    Current Internet qualities I observe to be in 75-100 range with median/average somewhere around 85.
    • 16 October 2021, 11:59
    • Source
  10. Nicolas Hoizey avatar Nicolas Hoizey
    I agree it’s almost never useful.

    Maybe with save-data if you don’t want lower res, but I can’t find how it would be better.
    • 16 October 2021, 12:05
    • Source
  11. Jyrki Alakuijala avatar Jyrki Alakuijala
    What are your thoughts on higher quality progression -- is it more acceptable than LQIP?

    For example the first video on this page:
    opensource.googleblog.com/2021/09/using-…
    • 16 October 2021, 12:09
    • Source
  12. Nicolas Hoizey avatar Nicolas Hoizey
    This is exactly what I would like to have indeed, I loved this article when I read it last month! 👍
    • 16 October 2021, 12:27
    • Source
  13. Jim avatar Jim
    I'm fine with either the progressive scan or the block-progressive loading Jon showed (not shown in the site you provided). LQIP is better than nothing when progressive is not available, but could add a bit more bandwidth.
    • 16 October 2021, 13:24
    • Source
  14. Jim avatar Jim
    As far as the site you linked, I agree 100%. People are will glance over the main subject so if it is loaded in first they may keep on scrolling before the rest of the image is loaded. Also why most CMS provide a way to crop thumbnail images to a specific area.
    • 16 October 2021, 13:26
    • Source
  15. Jim avatar Jim
    I am not the best fan of LQIP either but it's better than nothing when progressive is not available. Q < 30 can be useful doing a background - say where there is heavy blurring so that the image does not need a lot of kb or b to represent. Or very small thumbnails.
    • 16 October 2021, 13:35
    • Source
  16. Jim avatar Jim
    True, but there are still a number of developing countries that have very low mobile bandwidth. If you're targeting the world you also want to consider getting your page to load quickly in countries whose infrastructure has not kept up with demand.
    • 16 October 2021, 13:39
    • Source
  17. Jim avatar Jim
    That's why we need browsers to support JXL's progressive and responsive loading. So it can load the lower resolutions of the image (say rough equivalent to q 30) then stop until the user hovers over or clicks to see the larger image, then loads in the rest.
    • 16 October 2021, 13:44
    • Source
  18. Nicolas Hoizey avatar Nicolas Hoizey
    I prefer a single background color over the false promise of a LQIP, because I encounter too much LQIPs that don’t get replaced by the actual image (often on Medium).
    • 16 October 2021, 13:47
    • Source
  19. Jim avatar Jim
    I hate background image or using those hash color libraries. Even medium has had times where those scripts don't work right. If the image fails to load your left waiting, wondering if something will appear in the space.
    • 16 October 2021, 13:50
    • Source
  20. Nicolas Hoizey avatar Nicolas Hoizey
    Exactly why I don’t like LQIPs. Single color backgrounds are nice for the ambiance, without much promises.
    • 16 October 2021, 13:58
    • Source
  21. Anton avatar Anton
    1) As Jon notes, depending on the compression level, both are "the best". Caniuse notes have to be brief, and we expect people who really care about compression to dig deeper, but for most people, knowing that they are similar in quality (and better than WebP), is good enough IMO
    • 17 October 2021, 03:44
    • Source
  22. Anton avatar Anton
    2) JPEG-XL has features like lossless reencoding of older JPEGs and progressive decode, which is why we note that it has more features than AVIF.
    • 17 October 2021, 05:05
    • Source
  23. Nicolas Hoizey avatar Nicolas Hoizey
    OMG, I’m sorry, I understood the opposite, that the note said JPEG-XL had fewer features! 🤦‍♂️

    Sorry, sorry, sorry… 🙏
    • 17 October 2021, 09:37
    • Source
  24. Nicolas Hoizey avatar Nicolas Hoizey
    Both are the best if we consider a full range of compression levels, but as Jon also said (and I agree), most use cases are for compression levels where JPEG-XL is best.

    But I understand the note must be simple, nuance is difficult.
    • 17 October 2021, 09:39
    • Source
  25. Jon Sneyers 🔻 avatar Jon Sneyers 🔻
    Natural language could use some brackets for disambiguation. "JPEG XL competes with (AVIF which has similar compression quality but fewer features overall).", Not "JPEG XL competes with (AVIF which has similar compression quality) but [has] fewer features overall."
    • 17 October 2021, 09:45
    • Source
  26. Jon Sneyers 🔻 avatar Jon Sneyers 🔻
    Personally, I don't like to think of it as "competing", because competitions have winners and losers while here they are more complementary. I see AVIF as the new GIF, and JXL as the new JPEG and PNG. They each have their own strengths.
    • 17 October 2021, 09:48
    • Source
  27. Nicolas Hoizey avatar Nicolas Hoizey
    Good idea! 👍
    • 17 October 2021, 09:51
    • Source
  28. Nicolas Hoizey avatar Nicolas Hoizey
    That’s fair, indeed.
    • 17 October 2021, 09:53
    • Source
  29. Jon Sneyers 🔻 avatar Jon Sneyers 🔻
    I'd say AVIF focuses on consumer-grade fidelity (i.e. end-user delivery) and is great for animation. JXL focuses on still images and is suitable for both authoring workflows and web delivery.
    • 17 October 2021, 09:54
    • Source
  30. Nicolas Hoizey avatar Nicolas Hoizey
    That’s what I see in @addyosmani’s book (I know you were a contributor)
    • 17 October 2021, 10:09
    • Source
  31. Anton avatar Anton
    Oh that makes sense 😄 If I see more evidence that people are misunderstanding it, it might warrant rephrasing the note.
    • 17 October 2021, 10:35
    • Source
  32. Jyrki Alakuijala avatar Jyrki Alakuijala
    It's complicated.
    Resolution is another way to save data, often with more predictable behaviour than ulta-low quality.
    Developing countries can be more image centric in their internet use, and can have more text integrated into the images, requiring higher quality for reading.
    • 18 October 2021, 10:10
    • Source
  33. Jyrki Alakuijala avatar Jyrki Alakuijala
    Many developing countries (like Kenya) have a fast mobile net. Kenya is supposedly faster than USA.
    India is on average roughly 2x slower than Germany. That is about 3 years behind in development.
    • 18 October 2021, 10:40
    • Source
  34. Jyrki Alakuijala avatar Jyrki Alakuijala
    Thank you! Consider expressing thumbs up in Mozilla's Request for position and/or starring the JPEG XL bug on Chromium:
    github.com/mozilla/standa…

    bugs.chromium.org/p/chromium/iss…
    • 18 October 2021, 13:42
    • Source
  35. Anton avatar Anton
    I would probably also recommend JXL over AVIF, but they're both great, and we are already pushing people to use JXL by noting that it has more features. Saying that the compression is always better, is a dangerous path to go down, and I don't see how it would help anyone.
    • 18 October 2021, 23:46
    • Source
  36. Jon Sneyers 🔻 avatar Jon Sneyers 🔻
    Yes, I agree, and also things are still early in the sense that both avif and jxl encoders can still be improved. They're both ahead of older codecs, but by how much, nobody can really say definitively at this point.
    • 18 October 2021, 23:52
    • Source
  37. Anton avatar Anton
    I absolutely agree with your comments, but I also think the note accomplishes everything we wanted it to, which was basically just to say "if you don't care enough to research the topic even a little, then use JPEG-XL" :)
    • 18 October 2021, 23:53
    • Source
  38. Anton avatar Anton
    But thanks for the constructive feedback to both of you! Next time I revisit these tables, I'll keep it in mind :)
    • 18 October 2021, 23:58
    • Source
  • Older: Note from 14 October 2021
  • Newer: Note from 21 October 2021

Related contents with similar topics

  1. screenshot of JPEG XL vs AVIF for web use-cases

    Jake Archibald avatar Jake Archibald

    JPEG XL vs AVIF for web use-cases

    • Nicolas Hoizey
    • 22 October 2026
    • WebPerf, image, JPEG XL, AVIF
    • 5 reactions

    I'll go into full detail, with examples and benchmarks, but for those of you who don't have the time, here are [2 of] the headlines: For lossy photos…

  2. screenshot of The case against JPEG XL

    Gianni Rosato avatar Gianni Rosato

    The case against JPEG XL

    • Nicolas Hoizey
    • 14 September 2026
    • WebPerf, image, JPEG XL, AVIF
    • 7 reactions

    JPEG XL isn't useless; it is genuinely compelling technology for use cases beyond the Web. I'm just not personally convinced we need it in browsers…

  3. screenshot of The present and potential future of progressive image rendering

    Jake Archibald avatar Jake Archibald

    The present and potential future of progressive image rendering

    • Nicolas Hoizey
    • 16 October 2025
    • image, WebPerf
    • 4 reactions

    So if the browser manages to download 6 kB then stalls, then AVIF can produce a better result. But since the AVIF rendering is only two-pass, if the…

  4. screenshot of JPEG VS AVIF - The Battle of Compression

    kliksphilip

    JPEG VS AVIF - The Battle of Compression

    • Nicolas Hoizey
    • 25 September 2024
    • image, WebPerf, AVIF, JPEG XL
    • 2 reactions

    In this super thorough study I test one single HD image and come to vast sweeping conclusions about JPEG XL and AVIF. But that's still one image comparison…

  5. Note from 24 April 2024

    • Nicolas Hoizey
    • 24 April 2024
    • image, JPEG XL, Lighthouse, photography, WebPerf
    • 3 reactions

    Should I please Lighthouse with modern image formats, or my visitors with progressive rendering of large images in my photography site? 🤔

    screenshot of Lighthouse score in SpeedCurve, with a recommendation to use modern image formats

    Of course, this would be much easier with genaralized JPEG XL support, both modern and allowing progressive… 🤷‍♂️

If you want to share an error or suggest an enhancement of this content, please edit the source on GitHub.

© Nicolas Hoizey

Built with Eleventy