Request to Recognize Edge Cache CDN in PageSpeed Insights and Lighthouse Reports
Hello Lighthouse/PageSpeed team,
I'm part of the team at Pressable, a managed WordPress hosting provider that uses WP Cloud as our infrastructure. WP Cloud utilizes a CDN solution called Edge Cache, which serves static assets from edge locations to improve performance.
We’ve noticed that PageSpeed Insights (and Lighthouse-based tools) often report “No CDN detected” for sites utilizing Edge Cache. This seems to be because Edge Cache delivers static assets using the customer's domain, rather than a subdomain like cdn.example.com or a third-party domain like *.cloudfront.net.
However, assets are being served from the edge, and this can be verified by checking the response headers. When an asset is served from Edge Cache, the response includes:
x-ac: 33.mdw _atomic_dca HIT
Where "x-ac" indicates edge cache server responding to the request, "33.mdw _atomic_dca" indicates the specific location and server number in that location that responded to the request, and HIT showing the cache status of that asset.
We’d like to request that the CDN detection logic be updated to check for this x-ac: HIT header as an indicator that CDN caching is active. This would help provide a more accurate performance report for the many WordPress sites hosted on our platform and others using WP Cloud.
Please let us know if further details or test cases would be helpful.
Thank you for your work on these vital performance tools!
We’ve noticed that PageSpeed Insights (and Lighthouse-based tools) often report “No CDN detected”
Where does Lighthouse or PSI say this? I'm not aware of us detecting the presence CDNs.
If you are referring to cache audit (uses-long-cache-ttl; "Uses efficient cache policy on static assets") - I think this is WAI. That audit only looks for static resources like fonts, css, scripts, images, etc. and flags if there is no cache control header. Even if being served from the CDN, the browser has to make the request again - it may be as fast as can be, but caching locally is faster.
Thanks for the follow up! We used a similar template when reaching out to the popular speed test sites so the "No CDN Detected" wording may not apply here. I know webpagetest.org specifically categorizes static assets into CDN or no CDN. We're just wanting to start a dialog to make sure our customers using Edge Cache aren't being told by speed test sites that they don't have a CDN when they do, even if it's not a conventional CDN (rewrites URLs to CDN-esque URLs).
It sounds like you're saying as long as the static assets have a cache control header set, there shouldn't be an issue. Can you confirm and then we can mark this closed. Let me know. Thanks!
Yeah as long as the cache header sets a TTL of 30+ days for the assets we consider, we ignore the request.
Excellent, I appreciate the feedback. Thanks so much!!