Tools / Blog

WebP or AVIF: Which Image Format Should You Actually Use

Both formats promise smaller images than JPG. AVIF wins on size, WebP wins on everything else being simple. Which one you should use depends less on the compression numbers than on what happens to the file afterwards.

The short version

WebP is the safe default for a website in 2026. AVIF is worth the extra trouble when images are the point of the page — a photography portfolio, a property listing, a product catalogue — and when you control how they are served.

How much smaller, really

Published comparisons put WebP at roughly 25 to 35 percent below JPG at equivalent visual quality, and AVIF at roughly 40 to 50 percent below JPG. Those figures are averages across mixed test images, and your results will vary more than the numbers suggest.

The variation follows the content. AVIF pulls furthest ahead on photographs with smooth gradients — skies, skin, out-of-focus backgrounds — where its more sophisticated prediction has room to work. On small images, flat graphics, and pictures dominated by sharp edges and text, the gap narrows considerably, and sometimes closes entirely.

The practical implication: do not assume the percentage. Convert a representative sample of your own images with the image converter and compare the actual file sizes before committing to a format across a whole site.

Browser support

This used to be the deciding argument and mostly is not any more. Every current version of Chrome, Firefox, Safari and Edge reads both formats. The remaining gaps are in older installations and in software outside the browser — desktop image viewers, older versions of Office, some content management systems, and email clients.

That last category matters more than people expect. An AVIF image in an email newsletter will fail to display for a meaningful share of recipients. Email is where old software goes to survive.

Encoding speed

AVIF is markedly slower to encode. On a phone, converting a batch of large photographs to AVIF can take several times longer than the same batch to WebP. This is the cost of the more thorough compression, and it is a genuine consideration when the conversion happens on the user's own device rather than on a server farm.

If you are converting fifty holiday photographs on a phone, WebP will finish while AVIF is still working. If you are preparing a dozen hero images for a site once, the extra minute does not matter.

Transparency and animation

Both formats support transparency, so both can replace PNG for logos and graphics with transparent backgrounds. Both also support animation and can replace animated GIF, usually at a fraction of the size — though tooling for animated AVIF remains thinner.

A decision you can actually apply

The bigger saving is usually not the format. A 4000-pixel-wide photograph shown in an 800-pixel column carries about twenty-five times more pixel data than it needs. Resizing first with the image resizer saves far more than any format choice, and the two savings compound.

What about JPEG XL

JPEG XL is technically excellent and has an unusually appealing feature: it can losslessly recompress existing JPG files, shrinking them without any further quality loss. Browser support, however, has been contested, with Chrome removing then partially revisiting it. Until that settles, it is not a format to build a public site on.

The practical workflow

Resize to the largest dimension the image will actually be displayed at. Then convert, checking the output size against the original rather than trusting the format's reputation. The image compressor handles both steps together and will tell you when a conversion gained nothing, which happens more often than the marketing for any of these formats suggests.

Frequently asked questions

Is AVIF always smaller than WebP?

No. AVIF is usually smaller on photographs with smooth gradients, but the gap narrows on small images, flat graphics and pictures with sharp edges or text, where the two can be comparable.

Can every browser open WebP and AVIF?

Every current version of Chrome, Firefox, Safari and Edge reads both. Support is weaker outside the browser, particularly in email clients and older desktop software.

Which format should I use for a logo with transparency?

WebP is a good choice, since it supports transparency and compresses better than PNG. Use PNG if the logo is small and must be reproduced exactly.