Free to explore: filter winning sites by DR, traffic and niche  ·  Try the live explorer →

WebP and AVIF for SEO: what to use

Photo editing on a laptop with file sizes

Advice on WebP for SEO often implies that Google prefers the format and rewards sites that use it. There is no basis for that. Google Search’s own image documentation lists the formats it supports as “BMP, GIF, JPEG, PNG, WebP, SVG, and AVIF”. A JPEG is not penalised for being a JPEG, and a WebP earns nothing for being a WebP.

The same documentation gives the real reason to care: “images are often the largest contributor to overall page size.” Modern formats shrink that contribution. A smaller page loads faster, and speed is something you can measure and improve. So the question is not which format Google likes, but which one makes your pages lighter without breaking anything.

Using WebP for SEO: what the format actually changes

WebP’s case over JPEG and PNG is efficiency: similar visual quality in fewer bytes. The gain varies by image, by encoder and by quality setting, so be wary of anyone who quotes a single percentage saving as if it applied to your site. Test on your own images: export a representative sample at the quality you would actually publish, compare the files side by side at the size readers see them, and record the weight of each. That small exercise tells you more than any benchmark, because it uses your photographs, your encoder and your eye.

An image file size comparison

The effect on search is indirect. Lighter images mean fewer bytes before the main content appears, which helps loading metrics, which feed into the page experience signals Google uses. If your largest element is a hero image, its weight can decide whether that element loads quickly. Our guide to page speed and SEO sets out how much speed really matters for rankings, which is less than tool vendors suggest but more than nothing.

AVIF vs WebP for SEO

AVIF is the newer format, and web.dev describes its ambition plainly: it “aims to address every conceivable use case for raster images on the web: GIF-like animation, PNG-like transparency, and improved perceptual quality at file sizes smaller than JPEG or WebP.” Web.dev also reports that Netflix’s testing showed “significant reductions in file sizes when compared to JPEG or WebP.”

Picture element code with fallbacks

The catch has historically been support. According to web.dev’s guide to AVIF, the format was “only supported in Chrome and Opera since 2020, Firefox in 2021, and Safari in 2022”, whereas WebP support is “excellent across modern browsers.” AVIF support has caught up in current browsers, but older devices and some tools in your own pipeline may still lag.

JPEGWebPAVIF
Supported by Google SearchYesYesYes
Browser support (web.dev)Universal“Excellent across modern browsers”Chrome and Opera 2020, Firefox 2021, Safari 2022
File size (web.dev)BaselineLarger than AVIF“Smaller than JPEG or WebP”
Direct ranking effectNoneNoneNone

The last row is the one that matters. Every difference between these formats is a difference in bytes and compatibility, not in how Google treats the file.

Serve modern formats with a fallback

You do not have to choose one format for every visitor. The <picture> element lets the browser pick the first format it supports. Google’s image documentation makes one requirement clear: when you use <picture>, provide an img element as a fallback, with a src.

An image compression slider

The browser takes AVIF if it can, WebP if not, and the JPEG as a last resort. The img carries the alt text, width and height, so the fallback is also where your accessibility and layout stability live. Our guide to image alt text covers what to put in that attribute.

An image search results grid

Format is the smallest of your image wins

The received wisdom treats conversion to WebP as the headline fix. Often it is not. A 4,000-pixel photograph converted to WebP and displayed at 800 pixels wide is still far heavier than it needs to be. Resizing to the displayed dimensions, choosing a sensible quality setting and loading below-the-fold images only when needed usually save more than the format change alone.

Order the work accordingly. First serve images at the size they are displayed, with responsive srcset where layouts change. Then compress sensibly. Then defer offscreen images; our piece on lazy loading and SEO explains how to do that without hiding images from Google, and why the main above-the-fold image should not be lazy-loaded. Format conversion comes last, as the finishing step on images that are already right-sized. Done in this order, the format change compounds the earlier savings instead of disguising an oversized file.

A page weight report

If your report says the Core Web Vitals assessment failed and the largest element is an image, these steps are where to start. Our guide to a failed Core Web Vitals assessment walks through diagnosing which metric is the problem before you change anything.

A photographer exporting images

What to use, in short

For most sites, WebP is the safe default: broad support, real savings and simple tooling. AVIF is worth adding as a first choice inside <picture> when your build process can generate it, with WebP or JPEG behind it. Keep the original JPEG or PNG as the img fallback either way. If your CMS or image CDN can negotiate formats automatically, let it; the principle is the same, and you avoid hand-maintaining three versions of every file. What matters is that every visitor, and Google, receives a working image, and that the lightest version goes to the browsers that can use it.

One limitation to be honest about. There is no published measure of how much a format change alone moves rankings, and there is unlikely to be one, because the effect runs through speed and speed is one signal among many. You can measure the change in page weight and loading metrics directly. Judge the switch on those, not on rankings in the following week, which will move for reasons that have nothing to do with your images.

A practical check after the change: confirm that Google can still fetch and index the images you care about, particularly if image search sends you traffic. Make sure the fallback img has a real src, that image URLs did not change without redirects, and that your CDN serves the right content type for each format. A format migration that quietly breaks image URLs costs more than it saves.

Frequently asked questions

Does Google rank WebP images higher?

No. Google Search supports BMP, GIF, JPEG, PNG, WebP, SVG and AVIF. The benefit of WebP is smaller files and faster pages, not a format preference.

Is AVIF better than WebP for SEO?

AVIF can produce smaller files than WebP, according to web.dev, but its browser support arrived later. Serve it inside a <picture> element with a fallback.

WebP vs JPG for SEO: should I convert everything?

Convert where it reduces weight, but resize and compress first. A correctly sized JPEG can beat an oversized WebP.

Do I need a fallback image?

With <picture>, Google’s documentation says to provide an img element fallback with a src.

The takeaway WebP and AVIF do not rank pages; lighter pages load faster. Right-size and compress first, serve AVIF and WebP through <picture> with a JPEG fallback, and measure the result in page weight, not in rankings.