Rendering

Hydration

The browser attaches interactivity to server-rendered HTML so buttons and forms actually work.

SSR and SSG give you HTML that looks right but is 'dead' — clicking a button does nothing until JavaScript loads and wakes the page up. Hydration is that wake-up: the framework walks the existing HTML and wires up event handlers and state. Analogy: the server ships a printed photo of your app, and hydration turns the photo back into the live app. This is why you sometimes see a page that looks ready but won't respond for a beat, and why 'hydration mismatch' errors appear when the server's HTML and the client's don't line up (a common bug AI-generated code trips over with dates, random values, or user-specific content).

Related terms