ImageMay 8, 2026 ยท Updated Oct 13, 2026 ยท 3 min read

How to Choose the Right Image Format for the Web

JPEG, PNG, WebP, AVIF or SVG: we measured all of them on 24 standard test photos and six screenshots. At equal quality WebP saved about 26% and AVIF about 37% against JPEG; lossless WebP halved PNG screenshots.

Frog, photographer, model โ€” illustrating How to Choose the Right Image Format for the Web
๐Ÿ–ผ
Try the Image Converter
Free, no signup
โ†’
DG
Derek Giordano
Designer & Developer
In this guide
01Five Formats, Two Kinds02Measured: Photos and Screenshots03Choosing by Content04Browser Support

Five Formats, Two Kinds

Lossy formats (JPEG, lossy WebP, AVIF) throw away detail the eye is unlikely to miss; lossless formats (PNG, lossless WebP, lossless AVIF) keep every pixel; SVG is not pixels at all but drawing instructions. The choice comes down to what is in the image.

Measured: Photos and Screenshots

We encoded the 24 photos of the Kodak test suite (768ร—512, lossless originals) with Pillow 12.1 (libjpeg-turbo, libwebp, libavif). For each photo we took JPEG at quality 75 and 85, then found the lowest WebP and AVIF quality that matched the JPEG's structural similarity (SSIM, on luminance). The sizes below are therefore at equal measured quality (October 13, 2026; scripts in our test folder):

Format at equal SSIMSize vs JPEG q85 (median)Range across 24 photosSize vs JPEG q75 (median)
JPEG100% (82 KB)โ€“100% (60 KB)
WebP74%67-90%73%
AVIF63%51-70%62%

So WebP saved about a quarter and AVIF about three-eighths against JPEG, and AVIF came out roughly 14% smaller than WebP. The commonly quoted "AVIF is 30-50% smaller than WebP" did not hold here. Results vary with the image and the encoder settings; SSIM is one quality measure among several.

Screenshots behave differently. On six 1280ร—800 screenshots of our own pages, lossless WebP was 32-53% smaller than an optimized PNG (median 49.5%) with identical pixels, while JPEG at quality 85 ranged from 20% smaller to 20% larger than the PNG and blurs text edges.

Choosing by Content

ContentUseFallback
PhotosAVIF or WebPJPEG
Screenshots, UI, diagrams with textLossless WebPPNG
Logos, icons, simple illustrationsSVG (optimize with SVGO)PNG
Transparency in a photo-like imageWebP or AVIF (both have alpha)PNG
Short animationsA muted, looping <video>GIF only where video cannot play

Serve the modern format with fallbacks using <picture>:

<picture>
  <source srcset="photo.avif" type="image/avif">
  <source srcset="photo.webp" type="image/webp">
  <img src="photo.jpg" alt="..." width="1600" height="900">
</picture>

Browser Support

MDN's image format guide lists AVIF in Chrome 85, Firefox 93, Safari 16.1 and Edge 121, and WebP in all current browsers; caniuse puts global support at 96.3% for AVIF and 97.1% for WebP (data of October 13, 2026). The fallback in <picture> covers the rest at no cost.

Our Image Converter writes PNG, JPEG, WebP, BMP and GIF but not AVIF; for AVIF use an encoder such as Squoosh, libavif or Sharp in your build.

Frequently Asked Questions

Should I still use JPEG in 2026?+
As the fallback, yes. At equal SSIM on 24 test photos, WebP was a median 26% smaller and AVIF 37% smaller than JPEG, and both work in every current browser, so serve AVIF or WebP first and JPEG in the <img> fallback.
Is AVIF ready for production?+
Yes, with a fallback. MDN lists AVIF in Chrome 85, Firefox 93, Safari 16.1 and Edge 121, and caniuse puts global support at about 96%. List it first in <picture>, then WebP, then JPEG.
When should I use PNG over WebP?+
Mostly as a fallback or where a tool cannot read WebP. Lossless WebP keeps every pixel too and was 32-53% smaller than an optimized PNG on our six screenshots.
Try it yourself

Use the Image Converter โ€” free, no signup required.

โšก Open Image Converter
DG
Derek Giordano
Written by the creator of Ultimate Design Tools. BA in Business Marketing.