Click Below to Get the Code

Browse, clone, and build from real-world templates powered by Harper.
Tutorial
GitHub Logo

Resource Hints Explained | Preload, Preconnect, and Early Hints

Discover how resource hints like preload, preconnect, and Early Hints can dramatically boost web performance. Learn how each hint impacts key metrics like LCP and TTFB, with practical examples and implementation strategies to speed up page load and enhance user experience.
Tutorial

Resource Hints Explained | Preload, Preconnect, and Early Hints

By
Joseph Yoo
June 4, 2025
By
Joseph Yoo
June 4, 2025
June 4, 2025
Discover how resource hints like preload, preconnect, and Early Hints can dramatically boost web performance. Learn how each hint impacts key metrics like LCP and TTFB, with practical examples and implementation strategies to speed up page load and enhance user experience.
Joseph Yoo
Node.js Engineer

Resource hints like preload, preconnect, and early hints are essential tools for improving web performance, particularly when optimizing for metrics like LCP (Largest Contentful Paint) and TTFB (Time to First Byte). In this article, we walk through real-world examples, demonstrating the measurable impact of each hint.

Baseline: No Resource Hint

HTML File: no-preload.html
JavaScript File: loader.js

This setup loads an HTML file, which loads a JavaScript file, which then loads an image. Each step incurs its own latency.

Impact: Each asset waits for the previous to load before it begins, compounding latency.

Client-Side Preload

HTML File: client-preload.html

By adding a <link rel="preload"> tag, we instruct the browser to fetch the image early—even before the JS requests it.

Impact: The browser downloads the image in parallel with the JS file, saving one round-trip time.

Early Hints Preload

HTML File: eh-preload.html

This version moves the preload hint to the server using an HTTP 103 Early Hints response:

Impact: Resources start loading before the full response even arrives, outperforming client-side preload.

Client-Side Preconnect

HTML File: client-preconnect.html
JavaScript File: cdn-loader.js

In cases where only the domain of a resource is known, use preconnect:

Impact: Reduces DNS, TCP, and TLS setup times for third-party resources, typically saving 100–300ms.

Early Hints Preconnect

HTML File: eh-preconnect.html

Move the preconnect instruction to the server to get the benefits even earlier:

Impact: Provides the most aggressive latency reduction for third-party connections.

Key Takeaways

Focus your resource hints on LCP-contributing elements like large images, web fonts, or hero banners, and wherever possible, leverage Early Hints for the best performance. These optimizations not only improve load time and user experience but also contribute to higher search engine rankings. Just remember, more isn’t always better. Target only the assets that impact the initial user experience to avoid unnecessary overhead.

Resource hints like preload, preconnect, and early hints are essential tools for improving web performance, particularly when optimizing for metrics like LCP (Largest Contentful Paint) and TTFB (Time to First Byte). In this article, we walk through real-world examples, demonstrating the measurable impact of each hint.

Baseline: No Resource Hint

HTML File: no-preload.html
JavaScript File: loader.js

This setup loads an HTML file, which loads a JavaScript file, which then loads an image. Each step incurs its own latency.

Impact: Each asset waits for the previous to load before it begins, compounding latency.

Client-Side Preload

HTML File: client-preload.html

By adding a <link rel="preload"> tag, we instruct the browser to fetch the image early—even before the JS requests it.

Impact: The browser downloads the image in parallel with the JS file, saving one round-trip time.

Early Hints Preload

HTML File: eh-preload.html

This version moves the preload hint to the server using an HTTP 103 Early Hints response:

Impact: Resources start loading before the full response even arrives, outperforming client-side preload.

Client-Side Preconnect

HTML File: client-preconnect.html
JavaScript File: cdn-loader.js

In cases where only the domain of a resource is known, use preconnect:

Impact: Reduces DNS, TCP, and TLS setup times for third-party resources, typically saving 100–300ms.

Early Hints Preconnect

HTML File: eh-preconnect.html

Move the preconnect instruction to the server to get the benefits even earlier:

Impact: Provides the most aggressive latency reduction for third-party connections.

Key Takeaways

Focus your resource hints on LCP-contributing elements like large images, web fonts, or hero banners, and wherever possible, leverage Early Hints for the best performance. These optimizations not only improve load time and user experience but also contribute to higher search engine rankings. Just remember, more isn’t always better. Target only the assets that impact the initial user experience to avoid unnecessary overhead.

Discover how resource hints like preload, preconnect, and Early Hints can dramatically boost web performance. Learn how each hint impacts key metrics like LCP and TTFB, with practical examples and implementation strategies to speed up page load and enhance user experience.

Download

White arrow pointing right
Discover how resource hints like preload, preconnect, and Early Hints can dramatically boost web performance. Learn how each hint impacts key metrics like LCP and TTFB, with practical examples and implementation strategies to speed up page load and enhance user experience.

Download

White arrow pointing right
Discover how resource hints like preload, preconnect, and Early Hints can dramatically boost web performance. Learn how each hint impacts key metrics like LCP and TTFB, with practical examples and implementation strategies to speed up page load and enhance user experience.

Download

White arrow pointing right

Explore Recent Resources

Blog
GitHub Logo

Answer Engine Optimization: How to Get Cited by AI Answers

Answer Engine Optimization (AEO) is the next evolution of SEO. Learn how to prepare your content for Google’s AI Overviews, Perplexity, and other answer engines. From structuring pages to governing bots, discover how to stay visible, earn citations, and capture future traffic streams.
Search Optimization
Blog
Answer Engine Optimization (AEO) is the next evolution of SEO. Learn how to prepare your content for Google’s AI Overviews, Perplexity, and other answer engines. From structuring pages to governing bots, discover how to stay visible, earn citations, and capture future traffic streams.
Colorful geometric illustration of a dog's head in shades of purple, pink and teal.
Martin Spiek
SEO Subject Matter Expert
Blog

Answer Engine Optimization: How to Get Cited by AI Answers

Answer Engine Optimization (AEO) is the next evolution of SEO. Learn how to prepare your content for Google’s AI Overviews, Perplexity, and other answer engines. From structuring pages to governing bots, discover how to stay visible, earn citations, and capture future traffic streams.
Martin Spiek
Sep 2025
Blog

Answer Engine Optimization: How to Get Cited by AI Answers

Answer Engine Optimization (AEO) is the next evolution of SEO. Learn how to prepare your content for Google’s AI Overviews, Perplexity, and other answer engines. From structuring pages to governing bots, discover how to stay visible, earn citations, and capture future traffic streams.
Martin Spiek
Blog

Answer Engine Optimization: How to Get Cited by AI Answers

Answer Engine Optimization (AEO) is the next evolution of SEO. Learn how to prepare your content for Google’s AI Overviews, Perplexity, and other answer engines. From structuring pages to governing bots, discover how to stay visible, earn citations, and capture future traffic streams.
Martin Spiek
Case Study
GitHub Logo

The Impact of Early Hints - Auto Parts

A leading U.S. auto parts retailer used Harper’s Early Hints technology to overcome Core Web Vitals failures, achieving faster load speeds, dramatically improved indexation, and an estimated $8.6M annual revenue uplift. With minimal code changes, the proof-of-concept validated that even small performance gains can unlock significant growth opportunities for large-scale e-commerce businesses.
Early Hints
Case Study
A leading U.S. auto parts retailer used Harper’s Early Hints technology to overcome Core Web Vitals failures, achieving faster load speeds, dramatically improved indexation, and an estimated $8.6M annual revenue uplift. With minimal code changes, the proof-of-concept validated that even small performance gains can unlock significant growth opportunities for large-scale e-commerce businesses.
Colorful geometric illustration of a dog's head resembling folded paper art in shades of teal and pink.
Harper
Case Study

The Impact of Early Hints - Auto Parts

A leading U.S. auto parts retailer used Harper’s Early Hints technology to overcome Core Web Vitals failures, achieving faster load speeds, dramatically improved indexation, and an estimated $8.6M annual revenue uplift. With minimal code changes, the proof-of-concept validated that even small performance gains can unlock significant growth opportunities for large-scale e-commerce businesses.
Harper
Sep 2025
Case Study

The Impact of Early Hints - Auto Parts

A leading U.S. auto parts retailer used Harper’s Early Hints technology to overcome Core Web Vitals failures, achieving faster load speeds, dramatically improved indexation, and an estimated $8.6M annual revenue uplift. With minimal code changes, the proof-of-concept validated that even small performance gains can unlock significant growth opportunities for large-scale e-commerce businesses.
Harper
Case Study

The Impact of Early Hints - Auto Parts

A leading U.S. auto parts retailer used Harper’s Early Hints technology to overcome Core Web Vitals failures, achieving faster load speeds, dramatically improved indexation, and an estimated $8.6M annual revenue uplift. With minimal code changes, the proof-of-concept validated that even small performance gains can unlock significant growth opportunities for large-scale e-commerce businesses.
Harper