MyBB Internal: One or more warnings occured. Please contact your administrator for assistance.
WebPagetest Forums - wpt reports no max-age and expire headers when they exist

WebPagetest Forums

Full Version: wpt reports no max-age and expire headers when they exist
You're currently viewing a stripped down version of our content. View the full version with proper formatting.

I'm testing a website behind Akamai, downstream cacheability for static objects is explicitly set to a fixed value of 7 days (the same as the edge TTL), I can see the cache-control: max-age and expires headers correctly being set but wpt reports they are missing, for example:

FAILED - (No max-age or expires) -

But if you look at that URL you can see that a) it is being cached on the CDN, and b) both cache-control: max-age and expires headers are present with correct values:

accept-ranges: bytes
cache-control: max-age=604800
content-encoding: gzip
content-length: 83
content-type: image/x-icon
date: Wed, 29 Apr 2020 22:09:03 GMT
etag: "1000000009c22-13e-593c5e768bd7c"
expires: Wed, 06 May 2020 22:09:03 GMT
last-modified: Mon, 30 Sep 2019 14:18:03 GMT
status: 200
vary: Accept-Encoding
x-akamai-staging: ESSL
x-cache: TCP_HIT from

So I don't understand why wpt report those headers as missing from the request. This is the full test result:

NOTE: This test is against the CDN staging network, so if someone wants to test from their browser please check the test script for the IP address to be used.

Thanks in advance.

I think I have the same problem for this url, WTP doesn't find a max-age or expires header:
FAILED - (No max-age or expires) -

While on the detail page you can see those headers...
Request 22:
Response Headers:

status: 200
set-cookie: __cfduid=da8d102f34c8cbf8c095db07cc4c740d11591793743; expires=Fri, 10-Jul-20 12:55:43 GMT; path=/;; HttpOnly; SameSite=Lax; Secure
cf-cache-status: HIT
expires: Sat, 20 Mar 2021 10:42:06 GMT
vary: Accept-Encoding
last-modified: Thu, 12 Dec 2019 13:40:43 GMT
date: Wed, 10 Jun 2020 12:55:43 GMT
cf-ray: 5a133f8f2f220746-FRA
expect-ct: max-age=604800, report-uri=""
content-encoding: br
age: 7092817
strict-transport-security: max-age=15768000
cf-request-id: 033fe60d7c00000746da9ee200000001
server: cloudflare
etag: W/"28f1-59981e44ed59b"
cache-control: max-age=604800
content-type: image/svg+xml
:status: 200

Report's links:
Any idea ? false positive ?


I had not noticed that the explanation is right there at the end of the Performance Review page in the Glossary:
Quote:Cache Static
Applicable Objects: Any non-html object with a mime type of "text/*", "*javascript*" or "image/*" that does not explicitly have an Expires header of 0 or -1, a cache-control header of "private", "no-store" or "no-cache" or a pragma header of "no-cache"
What is checked: An "Expires" header is present (and is not 0 or -1) or a "cache-control: max-age" directive is present and set for an hour or greater. If the expiration is set for less 7 days you will get a warning. If the expiration is set for less than 1 hour you will get a failure. This only applies to max-age currently.
Reference URL's