Skip to main content
Comparison

Hydration vs Core Web Vitals: What's the Difference?

By ยท Updated ยท 6 min read

Hydration and Core Web Vitals Are Not the Same Thing

Hydration is a JavaScript runtime process: the browser receives pre-rendered HTML from a server or CDN, then a JS framework (React, Vue, Next.js) attaches event listeners and re-constructs component state so the page becomes interactive. Until hydration completes, buttons do not respond and forms do not submit, even though the page looks fully loaded.

Core Web Vitals are a set of Google-defined performance metrics โ€” Largest Contentful Paint (LCP), Interaction to Next Paint (INP), and Cumulative Layout Shift (CLS) โ€” that measure the user's perceived experience. They are measured signals, not a process. Hydration is something a page does; Core Web Vitals are measurements of how well a page performs for the user.

Mechanics: How Each One Works

Hydration unfolds in a fixed sequence. The server renders HTML markup and sends it. The browser paints visible content. Then the JavaScript bundle downloads, parses, and executes โ€” at which point the framework 'hydrates' the static HTML by binding its virtual DOM to the real DOM. On a large ecommerce product page with heavy component trees, this execution phase can take several seconds on mid-range mobile devices.

Core Web Vitals are measured by Chrome's real-user monitoring (field data) and by lab tools like Lighthouse and PageSpeed Insights. LCP records when the largest above-the-fold element finishes rendering. INP records the worst interaction latency across the page visit. CLS records unexpected layout movement. These metrics capture outcomes; hydration is one of many processes that can affect those outcomes.

The distinction matters for diagnosis. A slow LCP could come from a large server response, a render-blocking script, a slow image, or an unoptimized CDN โ€” none of which involve hydration at all. Blaming hydration for a poor LCP without isolating the cause leads to wasted engineering effort.

Where Hydration Directly Affects Core Web Vitals

Hydration has the strongest and most direct impact on INP. When the main thread is busy executing a large JavaScript bundle during hydration, click and tap events queue up. The browser cannot process them until the thread is free. This produces high INP scores โ€” sometimes hundreds of milliseconds above Google's 'needs improvement' threshold of 200ms โ€” even on pages that look ready.

Hydration also contributes to CLS when components inject or resize DOM elements during the hydration phase. An ecommerce header that renders a cart count or a promotional banner after hydration, without reserved space, shifts the layout. That shift is recorded as CLS. Hydration-induced CLS is distinct from image-related CLS but measured the same way.

LCP is less directly tied to hydration in server-side rendering setups, because the largest element is usually part of the initial HTML payload and paints before the JS bundle arrives. However, in fully client-side-rendered apps with no SSR, the LCP element does not exist until JavaScript runs โ€” so hydration is the gating event for LCP, and a slow bundle directly delays it.

Where They Diverge: Different Scopes, Different Owners

Core Web Vitals apply to every page on the web regardless of technology stack. A static HTML page with no JavaScript has Core Web Vitals scores. Hydration, by definition, only applies to pages that use a JavaScript framework with SSR or static generation. A plain HTML landing page, a Liquid-rendered Shopify page using no custom React components, or a server-rendered PHP page has no hydration phase.

The organizational scope also differs. Core Web Vitals scores feed directly into Google Search's page experience signals, which affect organic rankings and Search Console reports. Hydration performance is an engineering concern โ€” it shows up in JavaScript profiling traces, framework bundle analysis, and Time to Interactive metrics, but Google does not report a 'hydration score' anywhere. Teams track hydration cost through custom performance marks or React Profiler, not through Search Console.

Fixing hydration problems requires code-level changes: partial hydration, island architecture, deferred hydration, or reducing component tree size. Fixing Core Web Vitals problems can require any combination of infrastructure, image optimization, CSS, font loading strategy, server response time improvements, or JavaScript changes. The toolsets and responsible teams often differ.

How to Use Both Concepts Together in an Ecommerce Audit

Start with Core Web Vitals field data in Search Console or CrUX to identify which pages have real-user performance problems and which specific metrics are failing. This sets the priority. If INP is the failing metric on product pages, hydration is the first engineering suspect. If LCP is failing on category pages that use SSR, investigate image sizing and server response time before touching JS.

Once hydration is confirmed as a bottleneck via profiling, quantify the cost: measure the gap between First Contentful Paint and Time to Interactive. A gap above 3-4 seconds on mobile typically indicates a hydration problem worth addressing. Techniques like selective or lazy hydration reduce the JavaScript executed on initial load, which shortens main-thread blocking and improves INP directly.

Treat Core Web Vitals as the scoreboard and hydration optimization as one of several plays available. Neither concept replaces the other. A team that obsesses over hydration architecture without checking actual Core Web Vitals field scores risks optimizing for metrics that are not affecting rankings or user experience in practice.

Frequently asked questions

Does improving hydration automatically improve Core Web Vitals?

Not automatically. Faster hydration reduces main-thread blocking, which directly improves INP and can reduce hydration-caused CLS. But LCP, image-related CLS, and server response time are independent of hydration. Improving hydration is one input into Core Web Vitals scores, not a guarantee of passing all three metrics.

Can a page have bad Core Web Vitals with no hydration at all?

Yes. A static HTML page with unoptimized images, large fonts, or a slow server response can fail LCP. A page with injected third-party ads can fail CLS. A page with heavy synchronous JavaScript can fail INP. Hydration is a framework-specific concern; Core Web Vitals apply to all web pages regardless of stack.

Which Core Web Vitals metric is most affected by hydration?

INP is most directly affected. During hydration, the main thread is occupied processing the JavaScript bundle. User interactions during this period are delayed until the thread is free, producing high interaction latency. CLS is the second most affected metric when hydrating components shift layout. LCP is affected only in fully client-side-rendered apps without SSR.

How do you measure hydration cost separately from Core Web Vitals?

Use browser DevTools Performance panel or React Profiler to record a page load and measure the gap between First Contentful Paint and Time to Interactive. Custom performance marks (performance.mark) placed at hydration start and end give precise timing. Core Web Vitals tools like Lighthouse report outcomes; profiling tools report the hydration process itself.

Do Shopify stores need to worry about hydration?

Standard Liquid-rendered Shopify themes have no hydration phase. Hydration becomes relevant when stores add custom React or Vue components โ€” typically through Hydrogen storefronts or third-party headless setups. Shopify merchants running standard themes should focus Core Web Vitals efforts on image optimization, app script load order, and server response time instead.

MG
Written by

Matt is the founder of RunOctopus. He built All Angles Creatures from zero to page-1 rankings in reptile feeder insects in under 60 days using exactly this method โ€” turning a hard, entrenched niche into RunOctopus's proof store for programmatic SEO and AI search citation.

Connect on LinkedIn →

See what Otto would build for your store

Free architecture preview. No card required. Five minutes.

Generate Preview →