Network & PerformanceBaseline · Newly

Preload Scanner and fetchpriority Attribute

Mental Model

The Preload Scanner scans raw HTML bytes in parallel with the main parser to start network fetches early. fetchpriority="high" elevates an LCP image above non-blocking scripts in the transfer queue.

Interactive Simulator

LCP Prioritization: Default vs fetchpriority='high'

Lines of Code
Before
1
After
2
Reflows / Browser Cost
Before
Post-Layout promotion
After
Immediate High priority
BeforeLCP image without explicit priority
<img src="/hero.webp" alt="Product" />
<!-- Queued at Low priority until Layout -->
Lines: 1Reflows: Post-Layout promotionDependencies: None

Delayed behind defer/async scripts.

After (Native)fetchpriority='high' on LCP image
<img src="/hero.webp" alt="Product"
     fetchpriority="high" decoding="sync" />
Lines: 2Reflows: Immediate High priorityDependencies: 0 JS

Scheduled as soon as the Preload Scanner parses it.

Under the Hood

Treat the Preload Scanner as an airport baggage advance scout: while the main HTML parser is stuck at security behind a blocking <script>, the scanner sprints ahead through the raw byte stream and puts critical luggage on the conveyor belt early.

  1. As soon as the first HTML packets arrive, a dedicated thread (Preload Scanner) extracts <link>, <script>, and <img> tags before DOM construction completes for the Browser Rendering Pipeline.
  2. By default, Blink queues images at Low priority and only promotes in-viewport images to High after the first Layout pass.
  3. fetchpriority="high" assigns High priority in the HTTP/2 or HTTP/3 queue immediately upon HTML discovery, while fetchpriority="low" demotes carousel slides out of the way.
HTML
<!-- Discovered in the first TCP window; queued ahead of deferred scripts -->
<img
  src="/hero-banner.avif"
  width="1200"
  height="640"
  fetchpriority="high"
  decoding="async"
  alt="Dashboard overview"
/>

Problem Genealogy

  • 2008 (Preload Scanner): Workaround for synchronous <script> tags stalling downstream resource discovery.
  • 2016 (<link rel="preload">): Early discovery for resources hidden inside CSS/JS, frequently abused by pasting 12 preload tags in <head> and saturating the connection.
  • 2023+ (fetchpriority Baseline): Fine-grained relative priority control without duplicating preload tags.

Production Pitfalls

Production Pitfall
  • Client-injected LCP images: The Preload Scanner cannot see images mounted dynamically by React/SPA bundles until an Event Loop task executes JS, by which time your LCP budget is already half-spent.
  • Overusing fetchpriority="high": Marking 10 images as high cancels prioritization benefits and delays critical stylesheets.
When Not to Use
  • When not to use fetchpriority="high": Never apply it to below-the-fold images or secondary web fonts; for cross-page navigation speedups, use Speculation Rules instead.

Connections & Logical Next Steps

What This UnlocksBaseline · Widely
Content Security Policy Nonces and strict-dynamic
Security & Accessibility

The browser HTML parser and preload scanner evaluate script nonces before executing fetched scripts.

What This UnlocksBaseline · Widely
DOM & CSSOM Construction
Rendering Pipeline

Preload scanner discovers blocked CSS and JS assets before the main parser stalls.

What This UnlocksBaseline · Newly
103 Early Hints
Network & Performance

103 Early Hints feed the same speculative preload queue before the HTML parser even starts.

What This UnlocksBaseline · Widely
Font Loading & CLS Mechanics
Network & Performance

Preloading critical WOFF2 subsets starts font downloads before CSSOM parsing finishes.

What This UnlocksBaseline · Widely
HTTP/2 & HTTP/3 Multiplexing
Network & Performance

The preload scanner queues concurrent asset fetches that rely on multiplexed streams.

What This UnlocksBaseline · Widely
Import Maps & Browser-Native Module Resolution
Web APIs

Nested import-map subgraphs still require modulepreload links so the preload scanner fetches deep dependencies early.

What This UnlocksBaseline · Widely
Responsive Images & Decoding
Network & Performance

The HTML preload scanner evaluates srcset, sizes, and fetchpriority before CSS layout runs.

What This UnlocksBaseline · Widely
Streaming SSR & Progressive Flushing
Network & Performance

Flushing <head> early lets the preload scanner fetch CSS and JS while the server awaits DB queries.

Under the HoodBaseline · Widely
Browser Rendering Pipeline (Critical Rendering Path)
Rendering Pipeline

Governs availability of critical resources (CSS, fonts, LCP hero image) prior to first Paint.

Often Confused WithExperimental
Speculation Rules & Prerendering
Network & Performance

Preload scanner prioritizes current-page subresources, while Speculation Rules prerender next-page navigations.

Often Confused WithBaseline · Widely
ES Modules and Live Bindings
JS Runtime

Nested ES module imports cannot be discovered by the HTML preload scanner without modulepreload hints.

Mechanical Comparisons