Images · Image loading
Image missing size attributes
An image on this page has no width or height attributes, so the page jumps as the image loads and the content moves down.
How this page is built
The image below has no width or height attributes. Until it loads, the browser does not know how much space to keep for it, so the text below moves down when it appears.
Why it matters
When an image has width and height attributes, the browser can reserve the right amount of space before the file arrives. Without them, the layout shifts as the image loads.
Unexpected movement is annoying for visitors and can make them click the wrong thing. It is measured by Cumulative Layout Shift, one of Google’s Core Web Vitals.
How to check it
Crawl tools and Lighthouse report images without size attributes. The performance panel in browser developer tools shows layout shifts and the elements that caused them.
How to fix it
Add width and height attributes that match the image’s real proportions. Keep the image responsive with CSS such as max-width: 100% and height: auto, which uses the attributes to work out the aspect ratio.