Lesson 4.3

Prefetching and priority hints

The browser guesses at priorities from markup order and element type, and it guesses reasonably well.

7mAdvanced4.2k students

Overview

Ordering is a performance feature

The browser guesses at priorities from markup order and element type, and it guesses reasonably well. Hints are for the cases where you know better — the hero image below the fold in the DOM, the font needed for the first paragraph.

Prefetching the next likely navigation at low priority is close to free and makes the following click feel instant. Do it on intent signals like hover and viewport entry rather than for every link on the page.

A preload that is never used is a pure regression: you spent bandwidth ahead of things that were on the critical path, and the console will tell you so.

In this lesson you will:

  • Tell the browser what matters first
  • Prefetch the next navigation without stealing bandwidth
  • Avoid preloading things you never use

Resources

Previous Lesson
Prefetching and priority hints — React Performance Engineering — Vertex