What Are Resource Hints?
Resource hints are HTML attributes that tell the browser to prepare resources before they're needed. They can significantly improve perceived performance by reducing loading times.
Types of Resource Hints
Preconnect
Establishes early connections to important third-party origins.
``html
`
Use for:
Preload
Forces the browser to download critical resources immediately.
`html
`
Use for:
Prefetch
Suggests resources that might be needed for future navigations.
`html
`
Use for:
DNS Prefetch
Resolves domain names before they're needed.
`html
``
Impact on Core Web Vitals
LCP Improvement
Preloading hero images and fonts can reduce LCP by 20-40%.
FID/INP Improvement
Preconnecting to critical origins reduces blocking time.
Common Mistakes
Audit your resource hints with our free performance analysis tool.