Akamai
Last reviewed: 2026-10-27 · Applies to: Akamai Property Manager (Ion/DSA), Fast Purge API
When to read this
When the app is behind Akamai. Vendor-neutral concepts: references/layers/cdn-concepts.md. Several Akamai specifics (tag header limits, default TTLs, cache-key customization) weren't verified in this skill's research; confirm them in the customer's property before relying on them.
How to detect
Terraform akamai_property/akamai_property_rules, .edgerc, property rule-tree JSON in the repo, response headers when debug Pragma is sent (X-Cache, X-Check-Cacheable, X-Cache-Key), server: AkamaiGHost.
Default recipe
- In the property, set the Caching behavior for HTML/API paths to honor origin headers (
CACHE_CONTROLorCACHE_CONTROL_AND_EXPIRES), so the origin's per-route policy applies. - Origin sends explicit headers per route:
Cache-Control: no-cache+s-maxage=…for public HTML;private, no-cacheorno-storefor personalized/sensitive. - Add a rule that bypasses cache (
NO_STORE/BYPASS_CACHE) for authenticated paths and session cookies. - Turn on Tiered Distribution.
- Use Fast Purge invalidate by tag for content changes; delete only for takedowns.
Rules and gotchas
- By default Akamai does not honor origin
Cache-Control/Expires; property TTL rules decide. A property with a long TTL rule on/*will cache personalized pages regardless of origin headers. Audit the rule tree. - When honoring origin headers,
Cache-Controlwins overExpires; originno-store/bypass directives override. - Akamai supports
s-maxagefor downstream CDNs: on conflict it caches usings-maxageand forwards both directives. - Fast Purge: invalidate marks stale (revalidate next request; can serve stale if origin is unreachable); delete forces a full refetch (more origin load; use for compliance/copyright takedowns). ECCU only invalidates.
- Cache tags: Akamai uses an
Edge-Cache-Tagresponse header; secondhand sources cite limits of 8,192 characters and 128 tags per object. Verify in current docs and stay ≤ 50 lowercase tags. - Fast Purge propagation is commonly cited at about 5 s.
- The "fast invalidate" behavior is deprecated; use the Fast Purge API.
Purge API
Fast Purge v3 endpoints exist for invalidate and delete by URL, CP code and cache tag, plus a rate-limit status endpoint. Use the Akamai CLI (akamai purge invalidate --tag product-123) or EdgeGrid-signed API calls from the CMS webhook handler; batch tags per request.
Status headers
Send Pragma: akamai-x-cache-on, akamai-x-cache-remote-on, akamai-x-check-cacheable, akamai-x-get-cache-key, akamai-x-get-true-cache-key to get X-Cache (TCP_HIT, TCP_MISS, TCP_REFRESH_HIT, …), X-Check-Cacheable and the cache key. Restrict debug Pragma handling in production if the property allows it.
Version notes
- Fast-invalidate property behavior deprecated in favor of Fast Purge.
- Tiered Distribution is GA in the GA rule format.
Verify
curl -s -o /dev/null -D - -H 'Pragma: akamai-x-cache-on, akamai-x-check-cacheable, akamai-x-get-cache-key' \
https://www.example.com/page | grep -iE 'x-cache|x-check-cacheable|x-cache-key|cache-control'
curl -s -o /dev/null -D - -H 'Cookie: session=x' -H 'Pragma: akamai-x-cache-on' https://www.example.com/account | grep -i x-cache