1. Home
  2. Guides
  3. How to Improve Core Web Vitals With Image Optimization

How images affect Core Web Vitals

Updated November 20, 2026

Images are the largest element on most pages, so they usually decide two of the three Core Web Vitals. Here is what to measure and what to change.

The short answer

For images, three actions matter most: make the main image light (right size, modern format, sensible quality), declare its dimensions in the HTML so the layout does not shift, and do not lazy-load it. Those steps address Largest Contentful Paint (LCP) and Cumulative Layout Shift (CLS) directly.

What Core Web Vitals measure

Core Web Vitals are three measurements Google uses to describe how a page feels to a visitor, based on real user data. The thresholds below are the ones Google publishes as "good", measured at the 75th percentile of visits:

MetricWhat it measures"Good" thresholdRole of images
LCP, Largest Contentful PaintWhen the largest visible element has loaded2.5 seconds or lessOften an image: very high
INP, Interaction to Next PaintHow quickly the page responds to taps and clicks200 ms or lessIndirect (heavy decoding competes for the main thread)
CLS, Cumulative Layout ShiftHow much the layout moves unexpectedly0.1 or lessImages without dimensions: high

Core Web Vitals are one signal among many; a fast page does not guarantee rankings, but a slow one hurts the visitor first.

Improving LCP with images

On many pages the LCP element is the hero image or the first large photo. To bring it under 2.5 seconds:

  1. Reduce the weight. Resize to the real display size with Resize image, then compress with Compress image. Going from a 1.8 MB original to 150 KB can save a second or more on a mobile connection.
  2. Use a modern format. WebP or AVIF typically cut a third to a half off a JPG of similar quality.
  3. Do not lazy-load the main image. Remove loading="lazy" from it. You can add fetchpriority="high" so the browser fetches it early.
  4. Do not hide it behind CSS or JavaScript. A background image set in a stylesheet is discovered later than an img tag in the HTML. Prefer the img element for important images.
  5. Serve the right size per device with srcset (see mobile optimization).

Improving CLS with images

A layout shift happens when an image loads and pushes the text down. The fix is simple: give the browser the dimensions before the image arrives.

<img src="photo.webp" width="1200" height="800" alt="Description">

With width and height set, browsers compute the aspect ratio and reserve the space. In CSS, max-width: 100%; height: auto; lets the image scale down while keeping that ratio. The same rule applies to images in cards, avatars and advertising slots: reserve the space.

A realistic example

Imagine an article whose first image is a 4000 × 2667 JPG weighing 2.4 MB, displayed in an 800-pixel column. Resized to 1600 pixels wide (twice the column, for sharp rendering on high-density screens) and saved as WebP at 80%, the same photo weighs roughly 150 to 250 KB. The result depends on the picture, but a reduction of 90% is common for camera originals. Add the two dimension attributes and remove lazy loading from that one image, and both LCP and CLS improve for the cost of a few minutes.

How to measure

  • PageSpeed Insights shows field data from real visitors (when your site has enough traffic) and lab data, and names the LCP element.
  • Search Console has a Core Web Vitals report grouping URLs as good, needing improvement or poor.
  • Browser developer tools (Lighthouse panel and Performance panel) let you test a change before publishing.

Field data lags by weeks, so after changing images, expect the report to update gradually rather than instantly.

What not to do

  • Do not compress so hard that photos look blocky: visitors notice that before they notice 100 ms.
  • Do not lazy-load everything blindly.
  • Do not chase a perfect score at the cost of the content. A useful page that scores "good" is the goal, not 100 out of 100.

For the full workflow, start with optimizing images for a website.

Tools for this

More guides