๐Ÿ–ฅ๏ธ Web Dev

How Browsers Render Pages โ€” DOM, CSSOM, Paint, Composite

๐Ÿ“… Jul 5, 2026 โฑ 4 min read

"What happens between HTML arriving and pixels appearing?" โ€” the question that reveals whether performance advice is memorized or understood.

The pipeline

  1. Parse HTML โ†’ DOM (pausing at sync scripts!)
  2. Parse CSS โ†’ CSSOM โ€” CSS is render-blocking: no pixels until it's ready
  3. DOM + CSSOM โ†’ Render tree (visible elements with computed styles)
  4. Layout (reflow): calculate every box's position and size
  5. Paint: fill in pixels โ€” text, colors, shadows
  6. Composite: layers assembled on the GPU

Why this explains all the advice

Seeing it live

DevTools โ†’ Performance โ†’ record a page load: parse, layout (purple), paint (green) laid out on a timeline. Rendering tab โ†’ "Paint flashing" highlights repaints as you interact โ€” watching a janky animation light the whole screen green is the lesson that sticks.

โ† All Articles