How to Optimize Core Web Vitals and Page Speed to the Maximum

How to Optimize Core Web Vitals and Page Speed to the Maximum

SEO & Performance

Jan Sebastián Kostlán · 15 March 2024 · 6 min read

How to Optimize Core Web Vitals and Page Speed to the Maximum

Why loading speed and layout stability matter for search visibility, and how to work towards a PageSpeed Insights score above 95.

Why does Google focus on Core Web Vitals?

Speed and responsiveness are part of the visitor experience. Core Web Vitals measure loading, interaction and layout stability through LCP, INP and CLS. Slow loading and unexpected layout shifts can make a website harder to use.

1. Largest Contentful Paint (LCP)

LCP measures when the largest visible element appears, usually a heading or hero image. Aim for less than 2.5 seconds.

  • Images: use WebP or AVIF and fetchpriority="high" for the critical hero image.
  • Preloading: preload critical fonts and CSS.
  • Server rendering: Next.js can send rendered HTML without waiting for client JavaScript.

2. Interaction to Next Paint (INP)

INP measures responsiveness when a visitor clicks, opens a menu or types into a search field. Aim for less than 200 milliseconds and reduce expensive work on the main thread.

3. Cumulative Layout Shift (CLS)

Images and videos without explicit dimensions often cause layout shifts. Set their width, height or aspect ratio so the browser can reserve space.

A fast website saves visitors time and supports a smoother path to completing their task.

Conclusion

Performance optimization is ongoing work. Get in touch if you would like help reviewing your website's Core Web Vitals.

Have a question about this article?

Get in touch →