Static + Dynamic Caching Mode

Created at:

Static + Dynamic caching mode uses proprietary learning algorithms to monitor freshness and maximize the CDN capabilities of your sites.

Incapsula auto-optimizes HTTP headers to cache all available static resources and non-changing dynamically generated resources.

Incapsula differentiates between static and dynamic resources according to the following HTTP headers:  

  Static Dynamic
Max-age ≠ 0 = 0
Cache-Control public no-cache / private / must-revalidate / proxy-revalidate/ no-store
Last-Modified More than 24 hours Less than 24 hours
Vary Accept-Encoding

Anything except Accept-Encoding

(e.g User-Agent)

  • If a resource is determined as static based on 'Last-Modified' and no caching TTL is available, the proxy will set a TTL as a fraction of the date in 'Last-Modified'. The calculation is 1 hour per 1 day  for up to 24 hours.
  • Incapsula only considers resources as Dynamic if they are configured with the suitable HTTP headers, mentioned above, or if all of these headers are missing.
  • Please note that Incapsula will only return RFC compliant headers.


    Non-Compliant Format example:    Last-Modified: Wednesday, 08-Mar-2017 12:39:13 GMT 

     RFC Compliant Format:                     Expires: Wed, 08 Mar 2017 12:46:13 GMT


For more information regarding HTTP headers, please follow this article.


Incapsula's algorithms only analyzes Dynamic resources without the required HTTP headers to examine if they can be served from the cache even though they are set as Dynamic and caches them accordingly. 

Resources configured as Dynamic according to their HTTP headers are not analyzed by Incapsula's algorithms. 


The time period option (in minutes, hours, days or weeks) determines how often the cache is refreshed. 



1.   Resources which match the rules that were configured in the "Advanced Caching Rules" are not implemented in the learning algorithms. 

  •  If a resource matches both of the rules (Never cache/ Always cache), the "Never cache" rule will override the "Always cache" rule. 


For additional information regarding "Advanced Caching Rules", please follow this article.


2.   Comply with "no-cache" and "max-age":


"no-cache" is an HTTP request header which instructs the web server not to return cached content. "max-age" is an HTTP request header which instructs the web server not to return content which is over a certain age.

When the "Comply with no-cache and max-age" option is checked, these headers will be considered and the learning algorithms won't be implemented.

3.   Comply with "Vary"


"Vary" is an HTTP response header which indicates that certain content varies per user, and therefore should not be cached.

When the "Comply with  Vary" option is checked, this header will be considered and the learning algorithms won't be implemented.


For more information: Site performance settings

Was this article helpful?
3 out of 3 found this helpful
Have more questions? Submit a request


Powered by Zendesk