Core Web Vitals Optimization: LCP, INP, and CLS in 2026

Core Web Vitals are the three field metrics Google uses to score real-user experience: Largest Contentful Paint (LCP), Interaction to Next Paint (INP), and Cumulative Layout Shift (CLS). They're a soft ranking factor on their own but a strong proxy for the engagement signals that matter more.

Last updated: · By SEO Smart Engine Team

LCP under 2.5s

Almost always image-bound. Preload the hero image, serve it in AVIF or WebP, set explicit width/height, and host it on a CDN with HTTP/3. Defer everything that isn't above-the-fold.

INP under 200ms

INP replaced FID in March 2024. The fix is the same as for long tasks: break up JavaScript work, debounce input handlers, and move heavy logic off the main thread with Web Workers where possible.

CLS under 0.1

Reserve space for every image, embed, and ad. Avoid injecting content above existing content. Use font-display: optional or matched fallback font metrics to prevent FOIT/FOUT shift.

Measure in the field

Lab tools (Lighthouse) lie. Use Chrome UX Report (CrUX) data and a RUM tool like web-vitals.js to capture real visitor metrics segmented by device and country.

In-depth guide

A longer, practitioner-level breakdown of core web vitals optimization - written for readers who want the full picture, not just the summary above.

Why Core Web Vitals matter beyond the score

Core Web Vitals are Google's attempt to quantify perceived user experience with three field metrics. On their own they are a modest ranking signal - a tiebreaker at best when two pages are otherwise equal in authority and relevance. But their real value is as a leading indicator for the engagement metrics that do move rankings significantly: dwell time, pages per session, and return-to-SERP rate.

A page that fails Core Web Vitals fails on real user devices, and those users leave. Google reads the leaving. The Web Vitals number is a proxy Google gives you so you can fix the problem before the behavioral penalty compounds. Treat the metrics as diagnostic gifts, not as compliance checkboxes.

There is no 'passing score' that unlocks a ranking boost. There is a continuous relationship where better field metrics correlate with better engagement, which correlates with better rankings. Optimize as far as your engineering budget allows and stop when the marginal minute of engineering time no longer produces a measurable engagement lift.

LCP under 2.5 seconds: the image problem

Largest Contentful Paint is almost always determined by the hero image or the largest above-the-fold text block. In 90 percent of failing cases, it is the image. Compress the hero image to AVIF (fall back to WebP for older browsers), preload it in the head with a fetchpriority=high attribute, set explicit width and height, and never lazy-load it. These four changes together resolve most LCP failures.

Server response time is the second most common LCP contributor. Time-to-first-byte over 600 milliseconds means the LCP metric is already burning budget before your HTML arrives. Cache at the edge (Cloudflare, Fastly, Vercel Edge), use HTTP/3 where supported, and locate your origin near your primary user base. Static rendering (SSG) or edge SSR beats origin SSR for LCP in almost every case.

Render-blocking resources are the third. Every synchronous script and stylesheet in the head delays paint. Inline the critical CSS for above-the-fold content, defer non-critical CSS with media=print + onload, and defer or async every non-critical script. The waterfall in Chrome DevTools shows you exactly which resources are blocking - fix them in priority order.

INP under 200 milliseconds: main thread hygiene

Interaction to Next Paint measures the worst interaction latency across a session, weighted toward the 98th percentile. It is a harsher metric than the old First Input Delay because it captures continued interactions, not just the first one. Failing INP almost always means the main thread is blocked by long JavaScript tasks.

The fix is to break up long tasks. Any function that runs longer than 50 milliseconds should be split with yield points using scheduler.yield() or setTimeout(0). Modern React 18 and beyond include useTransition for exactly this purpose. Audit with Chrome DevTools Performance tab - any task longer than 200ms is a candidate for splitting.

Third-party scripts are the second most common INP killer. Every analytics tag, chat widget, and ad script runs on the main thread by default. Partytown moves them to a Web Worker where they cannot block interactions. Not every script is Partytown-compatible - test individually - but the ones that are usually move INP from 400ms into the 150ms range with no other changes.

CLS under 0.1: reserving space in advance

Cumulative Layout Shift measures unexpected movement of content after the initial render. Every image without width and height attributes causes a shift when it loads. Every ad slot without a reserved container causes a shift when the ad renders. Every font swap from a fallback to a web font causes a shift because the character widths differ.

The fixes are all about reservations. Set width and height (or aspect-ratio) on every image and video. Reserve a minimum height for every ad container. Use font-display: optional to avoid the swap, or match your fallback font's metrics to your web font's metrics using font metric adjustment properties.

Client-side content injection is the CLS trap that bites teams late in the launch cycle. A cookie banner that appears 800ms after paint shifts everything below it. A newsletter modal that pushes the hero down does the same. Either render these immediately in the initial HTML, or overlay them without displacing content.

Field vs lab data: the gap that confuses everyone

Lighthouse runs a lab test on a simulated device with throttled network. It produces a score. Chrome User Experience Report (CrUX) aggregates real Chrome users' field measurements. It produces different numbers. Google's ranking uses field data, not lab data. Optimizing for the Lighthouse score without checking field data can lead you to invest in the wrong problems.

A common pattern: Lighthouse shows 100/100 in a lab test but CrUX shows a 65th percentile LCP of 4.2 seconds. This usually means your users are on slower networks or devices than Lighthouse simulates, or your CDN performs worse in some geographies than the Lighthouse test location. Investigate the CrUX segmentation - device category, connection type, country - to find the failing cohort.

The tools: PageSpeed Insights shows both lab and field data side by side. web-vitals.js instruments your own site to capture real user metrics in your analytics. Search Console's Core Web Vitals report shows CrUX data aggregated per URL group. Use all three. The truth is in the intersection.

The 30-day CWV recovery playbook

Week one: baseline. Pull CrUX data for your top 20 templates (home page, category page, product page, article page, checkout, and so on). Note the 75th percentile LCP, INP, and CLS for each. Screenshot the results so you can measure progress against a fixed reference.

Weeks two and three: image and script optimization. Deploy AVIF/WebP hero images with preloading, defer all non-critical third-party scripts, remove unused JavaScript bundles, and audit render-blocking CSS. This phase alone typically shifts LCP by 30 to 50 percent on failing templates.

Week four: measurement and iteration. Re-pull CrUX data (which lags by 28 days, so the improvements may not fully register yet). Instrument web-vitals.js to see the leading indicator. Any template still failing after phase one needs template-specific investigation - server rendering strategy, JavaScript framework configuration, or third-party integration audit.

Frameworks and CWV: what actually helps

Server-side rendering (SSR) helps LCP by removing the render wait. Static site generation (SSG) helps more by removing the server wait too. Client-side rendering (CSR) frameworks with no SSR fallback typically fail LCP on content-heavy pages because the browser has to download the JavaScript, execute it, fetch the data, and render before the largest paint happens.

Next.js, Nuxt, SvelteKit, TanStack Start, Remix, and Astro all provide SSR or SSG out of the box. Migrating from a CSR-only setup to one of these frameworks is one of the highest-leverage CWV improvements available, and it also fixes JavaScript SEO issues in the same project.

Framework choice matters less than configuration. A poorly configured Next.js app can perform worse than a well-configured CSR app. The magic is in the specific patterns - avoiding client components where server components suffice, using dynamic imports for below-the-fold interactive widgets, using the Image component for automatic responsive images. The framework provides the tools; the team has to use them.

Free tools to apply this

FAQ

Do Core Web Vitals affect ranking?

Yes - Google confirmed they're a ranking signal in their Page Experience update, though the effect is small compared to relevance and authority.

What's a 'good' INP score?

Under 200ms at the 75th percentile of real visits. Between 200ms and 500ms is 'needs improvement'.

Why does my Lighthouse score differ from CrUX?

Lighthouse is a lab test on a single device. CrUX is real visitors across all devices and connections - it's the score Google actually uses.

Related topics

Continue building topical authority with these related guides.