Available inall subroutines.

Emit an HTTP 103 early hint informational response to help the client start making preparations for processing the final response.

early_hints takes as a parameter headers in a text format. This function is only effective for clients connecting using HTTP/2 or later.

Although the early_hints function can be invoked from any VCL subroutine, invoking it in methods later than hit/miss/pass may not provide the benefits of the informational response. For example, if you call early_hints in vcl_deliver the browser will receive the early hints response at the same time as the main response headers.


sub vcl_recv {
if (fastly_info.is_h2 || fastly_info.is_h3) {
early_hints("link: </hinted.js>; rel=preload", "link: </hinted.css>; rel=preload");

User contributed notes


Do you see an error in this page? Do have an interesting use case, example or edge case people should know about? Share your knowledge and help people who are reading this page! (Comments are moderated; for support, please contact Fastly support)