Cache
After your site connects to , edge nodes determine whether to cache resource files based on your cache configuration rules. When an edge node caches a file, can serve subsequent requests for the same file directly from the edge. This reduces back-to-origin requests, delivers content faster, and lowers latency. If the requested content is not cached or has expired, retrieves the latest data from the origin server.
Features
Control cache behavior for your site. The recommended workflow is to start with default cache rules, apply global settings, create cache rules for fine-grained control, and then manage cached content.
Default cache rules
Feature | Description |
Edge Security Acceleration (ESA) caches static resources from the origin server at the point of presence (POP) nearest to each client, reducing latency. Each POP includes a caching component. When a request or origin response passes through a POP, the component caches origin resources and assigns a time-to-live (TTL). |
Global cache configurations
Feature | Description |
When enabled, development mode temporarily bypasses the caching components of Edge Security Acceleration (ESA) and forwards all static resource requests directly to your origin server, so you can verify content changes in real time. | |
Browser cache TTL controls how long browsers keep resources in their local cache. By default, ESA honors the origin's | |
Edge cache TTL controls how long Edge Security Acceleration (ESA) PoPs cache origin resources. When a client requests a stale resource, the ESA PoP retrieves the latest version from the origin and caches it again. Set TTL for static resources by directory or file extension to reduce origin load and speed up delivery. | |
Configure how POPs handle query strings when generating cache keys. Stripping the | |
Query string sorting makes Edge Security Acceleration (ESA) sort URL parameters before cache lookup or request forwarding. Requests with identical parameters are treated as the same resource regardless of parameter order, which improves the cache hit ratio. |
Cache rules
Feature | Description |
You can configure a unique cache policy for each cache rule to set different browser cache TTLs. | |
To set a cache time-to-live (TTL) for specific requests, such as those based on file extensions or request header features, you can create custom rules. This lets you configure cache settings that are different from the global edge cache TTL policy. | |
When an origin server returns a non-2xx status code, Edge Security Acceleration (ESA) points of presence (POPs) can cache the status code and respond directly to subsequent requests within the cache validity period. This reduces repeated origin requests and lowers the load on the origin server. | |
Define rules based on query strings, HTTP headers, or cookies to generate custom cache keys that unify the cache identity for similar requests, improving hit rates and reducing response time and bandwidth consumption. |
Purge and prefetch
Feature | Description |
Cache purging clears cached resources from points of presence (POPs), forcing them to retrieve the latest content from your origin server. Purging many resources at once increases origin server load. | |
The prefetch feature caches origin server resources on Edge Security Acceleration (ESA) POPs so that first-time requests are served from the edge without returning to the origin, improving cache hit ratio. |
Advanced cache
Feature | Description |
Edge Security Accelerator (ESA) caches origin server resources on globally distributed nodes at different tiers, delivering content from the nearest location to reduce latency and origin load. | |
Cache reserve reduces origin traffic by consolidating origin requests through a top-level cache POP. ESA routes requests through this POP, which provides persistent storage to prevent less popular files from being evicted by frequently accessed content. |
Feature support by plan
The following table describes the cache features supported by each plan.
Feature category | Feature item | Free (CNY 0/month) | Basic (CNY 9.9/month) | Standard (CNY 375/month) | Advanced (CNY 3,600/month) | Enterprise (Contact Sales) |
Global static content delivery | ||||||
Cache analysis | ||||||
Edge cache layer | ||||||
Edge cache layer + regional cache layer | ||||||
Edge cache layer + Smart Cache Layer | ||||||
Edge cache layer + regional cache layer + Smart Cache Layer | Contact sales for on-demand customization | |||||
Cache Reserve | Contact sales for custom solutions | |||||
Cache purge | 1,000 purges | 10,000 purges | 50,000 purges | 100,000 purges | 500,000 purges | |
50 purges | 100 purges | 1,000 purges | 1,000 purges | 2,000 purges | ||
100 purges | 1,000 purges | 1,000 purges | 2,000 purges | |||
2,000 purges | ||||||
50 purges | 2,000 purges | |||||
2,000 purges | ||||||
5 purges | 50 purges | 80 purges | 125 purges | 200 purges | ||
Instant Prefetch | 10,000 entries | 50,000 entries | 100,000 entries | 500,000 entries | ||
Scheduled Prefetch | ||||||
Cache configuration |