Comparison · AVIF vs JPG

AVIF vs JPG

JPG has been the photo format of the web since the 1990s. AVIF, based on the AV1 video codec, can store the same photo at a much smaller size and with HDR color, but it is slower to create and less widely accepted outside browsers.

Short answer

For photos on your website, AVIF often cuts file size by 40–50% compared with JPG at similar visual quality, and all current browsers display it. For anything leaving your site, such as email, printing, forms and messaging, JPG remains the format that works everywhere.

AVIF compared with JPG
AVIFJPG
AgePublished 2019Standardized 1992
CompressionLossy (also lossless), variable block sizesLossy, fixed 8×8 blocks
Typical artifactsSmoothing of fine textureBlocks, halos, color bleeding
TransparencyYesNo
AnimationYesNo
File size for photosOften 40–50% smaller at similar qualityBaseline
Color depth and HDRUp to 12-bit, HDR and wide gamut8-bit in practice, no HDR
Encoding speedSlowVery fast
CompatibilityCurrent browsers; mixed in apps and formsUniversal
Best forWebsite photos, HDR imagesSharing, printing, uploads, archives

How the results look different

The two formats degrade in different ways, and that affects how far you can push them. JPG’s fixed grid shows up as squares in skies and halos around high-contrast edges. AVIF picks block sizes to fit the content and filters the result, so pushed too far it looks smooth and clean but slightly waxy: skin, foliage and fabric lose micro-texture first.

In practice, this means AVIF can be compressed much harder before most people notice anything, which is where its size advantage comes from. For images where fine texture is the point, such as close-up product shots of materials, use a higher AVIF quality and compare side by side.

Beyond file size

AVIF can carry HDR photos and wide-gamut color, which JPG cannot represent. It also supports transparency, so cut-out product photos no longer need a separate PNG. JPG’s strengths are elsewhere: it is instant to encode, every image tool reads it, and people can open it anywhere you send it.

Which should I use?

Common situations:

  • Photos for your own website, especially large hero images: AVIF, via Convert to AVIF or Optimize AVIF
  • Photos attached to emails or posted to a chat: JPG
  • Prints, photo books and print shops: JPG
  • Upload forms with a KB limit: JPG, using Compress to exact size
  • An AVIF you downloaded and need to open in older software: AVIF to JPG

Switch between AVIF and JPG

Questions

How much smaller is AVIF than JPG?

For typical web photos, AVIF is often 40–50% smaller than a JPG of similar visual quality. The exact saving depends on the image and the settings: smooth images gain most, while very detailed images at high quality gain less.

Can I use AVIF instead of JPG everywhere?

Not yet. Browsers support AVIF, but many email clients, upload forms, print services and older programs don’t. Use AVIF on websites you control and keep JPG for files that travel to other people and systems.

Does converting JPG to AVIF improve quality?

No. AVIF compresses the JPG’s pixels, including any artifacts already there, and adds a small loss of its own. The benefit is a smaller file. Start from the highest-quality originals you have for the best results.

Why is AVIF so slow to create compared with JPG?

JPG encoding follows a fixed, simple recipe. An AV1 encoder searches through many block sizes and prediction options to find the most compact representation, which takes far more computation. Pixellin runs AVIF encoding in a background worker so the page stays usable.

More comparisons