Image Optimization in 2026: Formats, Right-Sizing and Honest Savings Estimates
Last updated:
Image optimization is the practice of delivering each image at the smallest byte size that keeps it looking right — the right format, the right pixel dimensions, and only when it is needed. It matters because images are the page weight: in the HTTP Archive’s Web Almanac 2024, the largest image on the median mobile page weighs 135 KB, and images are the largest-contentful-paint element on 68% of mobile pages. This guide covers the format choices that matter in 2026, the oversized-image problem, the free wins (dimensions, lazy loading), and how to read the savings column of the Live Image Optimization Audit honestly. For everything else a page loads, see its family member, the Page Performance Audit — that tool times every resource; this one’s article is about images only.
Images are the page weight
Ask what makes pages heavy and the honest answer is: pictures. The Web Almanac 2024 media chapter puts the median mobile page’s largest single image at 135 KB — and the distribution has a long tail: at the 75th percentile the largest image is 404 KB, at the 90th it is 1,002 KB, nearly a megabyte for one file. Pages carry many small images and at least one large one, and the large one is usually the one the visitor is staring at while the page loads.
That is not a coincidence: the same chapter finds images are the element responsible for Largest Contentful Paint on 68% of mobile pages. LCP is the moment the main content becomes visible — the moment the page starts feeling loaded. If your hero image is a 900 KB JPEG where a 250 KB WebP would look the same, you have not shaved a statistic; you have delayed the single moment your visitor judges you by. Image optimization is performance work with unusually direct payoff.
Format choices in 2026
The format map is now stable enough to memorise. For photos: AVIF compresses best and WebP is close behind — Google’s WebP compression study measured WebP at 25–34% smaller than JPEG at equivalent quality, and AVIF typically improves on WebP again. For screenshots, diagrams and anything with sharp edges and few colours, PNG (or lossless WebP) stays right; JPEG blurs exactly the edges those images exist for. For logos and icons, SVG — vector text, tiny and resolution-independent — beats every raster format. Animated GIF is the one format with no remaining excuse: a video file (MP4/WebM) shows the same motion at a fraction of the bytes.
Adoption is moving, slowly. The Almanac records JPEG’s share of all images falling from 40% in 2022 to 32% in 2024, with AVIF at about 1% — the modern formats win on merit but the long tail of old pipelines wins on inertia. The pragmatic 2026 default is a <picture> element: AVIF first, WebP second, the original JPEG or PNG as the universal fallback, as in the code sample below. Every modern browser picks the first format it understands, so nobody is left behind — and the audit tool flags every JPEG/PNG that could take this path. 
The oversized-image problem
Format is the visible debate; sizing is the bigger bill. Bytes grow with pixel count, so an image served at twice the linear size it is displayed at carries roughly four times the data the slot can show — and the classic production mistake, shipping the 2,000-pixel original into a 400-pixel slot, wastes about 96% of the file. Content systems do this by default: one upload, one big file, every slot from thumbnail to hero served the same bytes.
The fix is mechanical: generate several widths at upload time and let the browser choose with srcset and sizes. A phone on a slow connection takes the 400-wide candidate; a retina desktop takes the 800; nobody takes the 2,000 unless the slot is genuinely that big. The audit’s demo page shows the pattern in the wild: Wikimedia Commons serves a 1,280×853 photograph (394,540 bytes) into a 500×333 slot — a 2.56× oversize — alongside its right-sized 500-pixel sibling. Serving at most 2× the display size (enough for retina) is the rule of thumb the audit flags against.
Width, height and layout shift
The cheapest fix in this entire guide costs zero bytes: put width and height attributes on every img. Browsers use the pair as an aspect ratio, reserving exactly the right box before the image file arrives. Without them, the box starts at zero height and every image that lands shoves the text below it downward — the layout shift that Cumulative Layout Shift (CLS) measures, and that readers experience as losing their place mid-sentence.
Two details people get wrong. First, the attributes do not need to match the file’s true pixels — 800×450 for a 1,600×900 file is fine, because only the ratio is used; CSS still controls the rendered size. Second, this applies to responsive images too: srcset changes which file loads, not the box it lands in. The audit flags images with missing dimensions because it is the one finding that is always free to fix and never has a downside.
Lazy loading rules
loading="lazy" tells the browser to postpone an image until it is about to enter the viewport. For below-the-fold images — gallery rows, footer logos, article thumbnails three screens down — that is pure win: bytes the visitor may never need are never fetched, and the first screen loads against less competition. Native lazy loading is in every modern browser; no library is required.
The rule has one sharp edge: never lazy-load the hero. The first, largest image is usually the LCP element (68% of mobile pages, per the Almanac), and lazy loading deliberately delays exactly that fetch until the browser has laid out the page and noticed the image is visible. Heroes get the opposite treatment: fetchpriority="high", no lazy attribute, and ideally a preload when the image is not discoverable early. The audit’s lazy check is a labelled heuristic — any image after the first with no loading attribute is flagged as probably eager — because a server-side fetch cannot see where the fold falls on your screen.
Estimates vs measurements: reading the savings column honestly
The audit prints an "estimated save" per image, and the word estimated is load-bearing. The number is arithmetic, not a conversion: JPEG→WebP at 30% and PNG→WebP at 26% come from Google’s published study; the resize figure assumes bytes scale with pixel count and caps delivery at 2× display size; per image the tool takes the larger of the two (never the sum — no double counting) and caps it at 90% of the file. Your encoder, your quality setting and your image content will move the real number in both directions. Treat the column as a ranking — biggest opportunity first — then convert one image and compare real bytes before you trust it.
The score, by contrast, uses only flags, never estimates: starting at 100, a single image over 1 MB costs 8 (max −24), over 500 KB costs 4 (max −16), oversized costs 3 (max −15), legacy format 2 (max −12), missing width/height 2 (max −10), missing alt 1 (max −5), missing lazy loading 1 (max −5), and total image weight over 2 MB costs 10, over 5 MB costs 20. Bands: 90+ Excellent, 70–89 Good, 50–69 Needs work, below 50 Poor. Two more honesty notes the tool page repeats: the checker sees the images a server sends IT — no cookies, a desktop user agent — and srcset totals are upper bounds, because a real browser downloads one candidate per slot, not all of them.
Try it yourself: one image, three formats, right-sized
<!-- Serve each browser the smallest sufficient file -->
<picture>
<source type="image/avif"
srcset="hero-800.avif 800w, hero-1600.avif 1600w"
sizes="(max-width: 800px) 100vw, 800px">
<source type="image/webp"
srcset="hero-800.webp 800w, hero-1600.webp 1600w"
sizes="(max-width: 800px) 100vw, 800px">
<img src="hero-800.jpg" width="800" height="450"
alt="…" fetchpriority="high">
</picture>