Site performance settings

Created at:


It's a well-known fact that a web site's speed and responsiveness have a significant impact on its user experience. Poor site performance can cause both new and veteran users to become frustrated, and the competition is always just a click away.

Incapsula supports several performance-boosting features which are fully configurable, so that you can fine-tune your site's performance according to your specific needs.

Incapsula's performance-related features include the following:

  • A caching mode that determines an overall caching policy
  • Advanced caching rules for specific resources
  • File compression and minification
  • TCP connection management
  • Advanced settings


Some Performance features are only available within paid plans. We recommend that free users upgrade their plan in order to enjoy the full benefits of performance enhancement.

Features that are limited to paid plans are marked with (Paid Plans Only).

Performance Settings



To access Performance settings, log in to your account on the Incapsula site, click the  Settings.jpg  tab, and then click the Performance option in the left-hand menu. After any change to settings, click the Save.jpg button on the top-right.


Content Caching

Incapsula maintains a global Content Delivery Network (CDN). This is a large set of globally distributed data centers (also known as Points of Presence or PoPs) providing high availability and optimizing performance and user experience. The following configuration options allow you to determine how your site's content is cached and refreshed.

Caching Mode


The following caching modes are supported:

  • Disable Caching – no caching is performed; all content is transferred from your web server.
  • Static Only – only content that has been marked by the site's developer / web server as static (using standard HTTP headers) will be cached.
  • Static + Dynamic (Paid Plans Only) - Incapsula applies a learning algorithm, which dynamically profiles the site and identifies what content should be cached. If a change in the site is identified, re-learning is triggered. The time period (in minutes, hours, days or weeks) that you set for this option determines how often the cache is refreshed.
  • Aggressive – All site content is cached. The time period (in minutes, hours, days or weeks) that you set for this option determines how often the cache is refreshed. This mode is recommended only for a site that contains no dynamically updated content.


You may be familiar with an older version of this feature called Acceleration Mode, which was previously found under General Settings. The possible modes were:

  • Off – now implemented as the Disable Caching mode.
  • Standard - now implemented as the Static Only mode.
  • Advanced - now implemented as the Static + Dynamic mode.



Purging the Cache

Purging the Entire Cache

After a major change to your web site, such as a version update, you may want to clear all caches immediately, without waiting for the caching period to expire.

To purge the entire cache:

1.     Click the Purge_cache.jpg button. The following dialog appears.


2.     Click  Continue.jpg  to clear the cache.


Purging a Specific Resource (Paid Plans Only)

After a small, localized change, such as a change to a single page or image, you can clear the cache for the specific resource changed.

To purge a specific resource:

1.      Click Purge_specific.jpg. The following dialog appears.


2.     Select one of the URL rule options (URL is, URL contains, URL starts with or URL ends with).

3.     In the second box:

        For the URL is rule, enter a complete URL (e.g. "/intro/settings/logo.png")
        - OR -
        For one of the other rules, enter a partial URL string that will be matched as a prefix, midfix or suffix of the URL, depending on the rule.

4.     Click Purge_II.jpg.


Advanced Caching Rules (Paid Plans Only)


You may want to define explicit exceptions to the caching rules that are defined by the overall caching mode. You can define specific URL or group of URLs which should always be cached, or should never be cached.


An advanced caching rule contains a URL string-matching rule (the first box in the image above) and a partial URL string (the second box in the image above).

The following table summarizes the six types of advanced caching rules.

String-Matching Rule

String Example


Doesn't Match

URL is





URL is not





URL starts with





URL ends with






URL contains





URL does not contain






"Always Cache" Rules

To define a URL or group of URLs that should always be cached:

1.     In the "Always cache the following resources" section, click Add_URL.jpg. The following line appears.


2.     Click the drop-down arrow of the URL rule box. The following options appear:

 3.     Enter a partial URL string in the second box. 

           All of the URLs that match the rule will always be cached.

4.     Enter the time period and unit (minutes, hours, days or weeks) which determine how often the cache will be refreshed.


"Never Cache" Rules

To define a URL or group of URLs that should never be cached:

In the "Never cache the following resources" section, click Add_URL.jpg.


The URL rule definition is the same as above. (Note that for a "Never cache" rule, there is no caching period and therefore no need to enter the cache duration value).

All of the URLs that match the rule will never be cached.

Editing and Removing Cache Rules

To edit a URL rule, click the Pencil.jpg icon to the right of the rule.

To remove a URL rule, click the X.jpg icon to the right of the rule.

Precedence among Caching Rules

Since there may possibly be conflicts between the advanced caching rules and the logic dictated by the caching mode, the following order of precedence is applied to the various types of rules:

  1. "Never cache" advanced rules
  2. "Always cache" advanced rules
  3. The Caching Mode
  4. Cache directives sent by the web server (in HTTP headers)


If there is a conflict between the caching durations defined in the Caching Mode and in Advanced Caching Rules, the longer period of the two will be applied.

The same goes for a conflict between the caching rule of a certain resource and one of its sub-resources.

Content Optimization

The next group of settings controls options for timing of the cache refresh, content compression and TCP connection management.


Asynchronous Validation


Once a certain resource caching period expires, the cache will be refreshed upon the subsequent request for this resource. There are two ways in which a resource cache can be refreshed:

  • If the Async Validation option is checked, the first request after the cache period expires will cause the resource to be retrieved from the cache with no delay and the cache will be refreshed asynchronously.
  • If the Async Validation option is not checked, the first request after the cache period expires will trigger a refresh of the cache and the request will be delayed until the resource cache has been refreshed.

Content Minification


Content minification can only be applied to cached Javascript, CSS and HTML content and therefore this option is disabled when caching is disabled. Minification removes characters that are not necessary for rendering the page, such as whitespace and comments. This makes the files smaller and therefore reduces their access time. Check each of the file types you wish to minify.

Image Compression (Paid Plans Only)


Image compression can only be applied to cached images and therefore this option is disabled when caching is disabled. Image compression can be applied to JPEG and PNG images. Compression makes the files smaller and therefore reduces their access time. Check each of the image types you wish to compress.

When compression is enabled, image meta-data is omitted with no impact on quality, and the image data is compressed, which in certain cases may affect quality.

In the case of JPEG compression, there are two possible modes you can choose:

  • Progressive Image Rendering – the image is rendered with progressively finer resolution, potentially causing a "pixelated" effect until the final image is rendered with no loss of quality. This option reduces page lead times and allows images to load after the page is rendered.
  • Aggressive Compression – a more aggressive method of compression is applied with the goal of minimizing the image file size, possibly impacting the final quality of the image displayed.

"On-the-Fly" Compression


When this option is enabled, text files are compressed with the gzip utility before being transferred, and then unzipped within the browser (all modern browsers support this feature). This applies to all text files (Javascript, CSS and HTML), even those which are not cached.

TCP Pre-Pooling (Paid Plans Only)


By default, a web session may open and close many TCP connections dynamically throughout the session, causing a certain overhead and reducing performance. When the TCP Pre-Pooling option is enabled, it attempts to maintain several TCP connections constantly open throughout the session, thereby improving performance. Not all web sites support this behavior, so it will be applied only when possible.


Advanced Settings

Handling Cache-Related Headers

Cache Headers allows us to ensure certain HTTP headers that are required by the customer's systems is not dropped when traffic is going through Incapsula.Capture1.PNG


The following options allow you to control HTTP features that may interfere with Incapsula's caching behavior, thereby reducing performance. These are triggered by HTTP request and response headers that instruct the web server or client not to cache certain content. These headers are often used incorrectly and unnecessarily, and therefore Incapsula allows you to override them.

Because the use of these headers is often due to misconfiguration of web applications, the default behavior is to ignore them, but you can change this behavior using the setting below.


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; otherwise they will be ignored (the default behavior).

Once this option is enabled, Incapsula takes into consideration the first time the content was served to the client. After the value in the max-age passes, the content will be served directly from the server and then will start the countdown from the beginning according to the value of the original max-age.

Comply with "Vary: User-Agent"


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

When the "Comply with  Vary: User-Agent" option is checked, this header will be considered; otherwise it will be ignored (the default behavior).


 Use shortest caching duration in case of conflicts

Usually when there is a duration conflict between caching rules or modes the longest duration is used. When this box is checked Incapsula will use the shortest duration in case of conflict. 


Prefer 'last modified' over eTag

When this box is checked Incapsula will prefer using ‘Last Modified’ values (if available) over eTag values (recommended on multi-server setups). 

Disable client side caching

When this box is checked content will only be cached on the Incapsula proxies and not on client browsers.

Caching HTTPS traffic

When Incapsula caching mode is set to Static + Dynamic, the default caching behavior for HTTPS is as follows:

  • Only the following resources may be cached heuristically: images, css files, JavaScript files, and resources defined with the Cache-Control: public header.
  • Resources that include explicit caching directives against caching, as defined in the resources themselves using the Cache-Controlor Expires HTTP headers, are not cached.
  • HTML files are not cached.
  • Asynchronous validation is not used.

Caution: If you override this default behavior by setting an explicit Advanced Caching Rule for the site to cache HTML files, you can introduce the risk of returning HTML resources that contain personal information, such as PII, ePHI, and PAN data.

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


Powered by Zendesk