Same image, different widths
- Markup
srcsetwithwdescriptors, plussizes
Responsive images let the browser pick the right file for each screen. See srcset, sizes and picture with working code, plus the loading hints and SEO notes.
Responsive images are images that adapt to the device: you give the browser several files, using srcset and sizes for different resolutions or the picture element for different crops, and it picks one. Google recommends always keeping a src fallback, because some browsers and crawlers don't understand srcset or picture.
Four quick questions, then a straight answer.
From your answers, this is quietly costing you traffic and nobody has the hours to chase it. Scaplet finds every affected page, drafts the fixes and tracks how AI answers mention you.
A data platform shipped 46 fixes without a ticket.
This looks handled. Re-check after a redesign, a migration or a big content push; that is when it breaks.
Your site is small and you have the time. Work through the steps on this page, starting with the pages that get the most traffic.
srcset with w descriptors, plus sizessrcset with x descriptors, no sizes<picture> with <source> elements and a final <img>srcset lists the files and their intrinsic widths using the w unit, not px. sizes tells the browser how wide the image slot will be under each media condition. The browser works out the first true condition, takes that slot width, and loads the srcset file that matches, or the first bigger one.sizes and ignores the rest, so order them with care.50vw, but not a percentage.<meta name="viewport" content="width=device-width"> in the head, since some mobile browsers otherwise load at a larger viewport width.<img
srcset="elva-fairy-480w.jpg 480w, elva-fairy-800w.jpg 800w"
sizes="(width <= 600px) 480px, 800px"
src="elva-fairy-800w.jpg"
alt="Elva dressed as a fairy" />In MDN's example the 800px file is 128KB and the 480px file is 63KB, so the narrow screen saves 65KB for one image. Across a page of images that adds up.
<picture> wraps <source> elements and a required <img>. Each source has a media condition and the first one that is true is used. The <img> with src and alt is the default when none match, and the fallback for browsers without <picture>.<picture>
<source media="(width < 800px)" srcset="elva-480w-close-portrait.jpg" />
<source media="(width >= 800px)" srcset="elva-800w.jpg" />
<img src="elva-800w.jpg" alt="Chris standing up holding his daughter Elva" />
</picture>width and heightloading="lazy"fetchpriority="high"web.dev also recommends the CSS img { max-inline-size: 100%; block-size: auto; } so images never render wider than their container while keeping their aspect ratio.
src, because some browsers and crawlers don't understand srcset or <picture>.src in these formats: BMP, GIF, JPEG, PNG, WebP, SVG and AVIF. Match the file extension to the file type.5 questions people ask next, answered from the sources on this page.
It's an image the browser can load at different sizes, resolutions or crops depending on the device. HTML does this with srcset and sizes on img, or with the picture element.
srcset with sizes switches between sizes or resolutions of the same image. picture lets you serve different crops or formats, using media conditions on source elements.
Yes. Google recommends a fallback URL in src because some browsers and crawlers don't understand srcset or picture, and MDN says the img element with src and alt is required inside picture.
No. web.dev says images below the fold can use loading="lazy", but a hero image above the fold shouldn't.
Google Search supports images in src in these formats: BMP, GIF, JPEG, PNG, WebP, SVG and AVIF.
The free audit reads robots.txt, sitemaps, status codes, canonicals, redirects and structured data.