I’ve flipped on Early Hints for our site, and they do appear to be working. What’s confusing to me, though, is that it’s only sending a subset of our Link header as early hints, and not every resource specified in the Link header.
The page is https://app.gusto.com/login.
Using @M4rt1n 's wonderful tool https://code103.hotmann.de/, you can see that the 103 Early Hint contains 3 resources (3 webfont files).
However, the problem is that the Link header on the 200 response actually contains 2 more resources (2 images):
So what gives? Does Cloudflare have an algorithm for determining what it thinks should be included in a 103 and what isn’t? The 2 images definitely are included in a valid way because Chrome acts on them as soon as it gets the 200 response back.
Thanks for using my tool! Nice to hear it is useful for others
Very good decision on dynamic pages.
Yes, that’s what I see after some manual checks as well. I have also debugged my tools again to see if it is properly working and it is. That’s the actual result the tool gets.
I can see they are in the link-header, but I can not confirm that I see these two additional headers being fired as an early hint.
Could be multiple things.
I noticed that when I debug it manually and request the whole response header I first get the HTTP/2 103 (Early Hint) then afterwards a HTTP/2 403 (Forbidden). Do you trigger less link-headers in case of a 403?
Why does the 403 happen? My application is go-based, but therefore was blocked by Cloudflare and as a Workaround I made it identify as curl - ‘curl/h0tmann’ to be precise. Curl mostly is getting rated as “bot”, or “crawler” and therefore forbidden, specially on logins.
So the question is: where is it getting blocked and can you turn it off for testing purposes?
Maybe less link-headers are getting set when a 403 is triggered. If so we see 5 link-headers in the browser, but just 3 when requested by my tool.
BTW: same result with curl itself.
Beside that something might block curl it also could be my IP, which is a server-ip which therefore might get blocked.
Cloudflare might choose which resources will benefit from getting triggered as early hints, but I am not aware of any of those practices. But I also have to say: things change quickly and ATM my ressources are very short, so bearly no time to get informed.
something else, I have not considered.
Here the command for curl, so you can test on your own from other IPs:
I assume the request was blcked by Cloudflare (check Firewall etc.) as in the headers no cf-cache-status appears, but in the browser I see: cf-cache-status: DYNAMIC