Skip to content
Performance & Accessibility

Hydration Cost and Islands, Done Properly

The work browsers do to make server-rendered HTML interactive, and architectures that reduce it.

MediaScaleUp Editorial Team 2 min read 14 views
Hydration Cost and Islands, Done Properly

What is at stake

Hydrating a whole page blocks the main thread, hurting responsiveness even when the page looks ready.

The playbook

  1. Ship less JavaScript to the client
  2. Hydrate only interactive components
  3. Defer non-critical hydration
  4. Measure Interaction to Next Paint in the field
  5. Consider static rendering for content pages

Where it goes wrong

Avoid:

  • Client-side frameworks for static content
  • Hydrating entire pages by default
  • Blocking the main thread on load
  • Judging speed by first paint alone
What to do and what to avoid with hydration cost and islands, side by side
Good practice against the usual mistakes, from the sources listed below.

The numbers behind it

Published figures for Hydration Cost and Islands
MeasureFigure
Hydrationclient JavaScript attaches behavior to server-rendered markup
Costhydration work delays interactivity
Islandsonly interactive parts are hydrated
Streamingserver rendering can send HTML progressively

Getting outside help

When to hand it over: Bring in help when pages look ready but respond slowly.

Where this comes from

The figures and practices above come from the sources listed.

Working on something like this?

We take on Performance & Accessibility work for teams who want it done once, properly. Tell us what you are building and we will tell you honestly whether we are the right studio for it. Start a project.

Where to go next

Spotted something wrong? Report an error on this page. We correct on the page and say what changed.

All services

The work behind this article, and what it costs.

MediaScaleUp Editorial Team

Articles here are researched, written and checked by the MediaScaleUp studio team before they are published, and dated when they are reviewed.

Keep reading

More in Performance & Accessibility