Link

prefetch

Suggests fetching and caching a resource that is likely to be needed by a later navigation.

Code examples

Good example
<link rel="prefetch" href="/checkout">
Suggests fetching a page that is likely to be the next navigation.
Avoid this example
<link rel="prefetch" href="/critical-current-page.css">
Uses a next-navigation hint for a resource required by the current page.

Recommendations

  • 01
    Prefetch likely next-step resources
    A wrong prediction wastes data and can compete with current page work. Use evidence from common navigation paths rather than guessing broadly.
  • 02
    Use preload for the current page
    Prefetch targets a later navigation. A resource needed by the current page may instead need preload or its normal loading element.
  • 03
    Expect browser discretion
    Prefetch is a hint. The browser can delay or ignore it based on network conditions, user settings, or resource policy.

Related documentation