By default, WisePops maintains the size of each one of our cookies under 3 KB. This is a compromise we choose from experience. We keep your visitor's history long enough without adding too much weight to your requests.

Unfortunately for some cases this is not enough. When other services that rely on first-party cookies are installed together with WisePops, the cookies total size might exceed the maximum headers length of your server. This will cause your visitors to see 413 errors.

WisePops can be configured to reduce its footprint on your requests. There are 2 different solutions.

Use local storage instead of cookies

This is the preferred method. With this option, WisePops will rely on the browser's local storage instead of cookies. The data of your visitors is still attached to your own domain, but won't be added to the requests made to your servers anymore. When the option is activated, WisePops will take care of migrating the cookies we previously created to the local storage.

However, the local storage is not cross-subdomain. With this option enabled, what happens on www.example.com is invisible for app.example.com. Let's consider the condition: "Exclude visitors who already saw 1 popup during the session". If a visitor sees a popup on www.example.com, then go to app.example.com, WisePops will think that the visitor just arrived on your website. If you need your different sub-domains to be connected together, please consider the next solution.

To activate the local storage, copy and paste the following code between your setup code and the closing </script> tag:

wisepops('options', {
  browserStorage: true
});

The script containing your WisePops setup code and this option should look like this:

Reduce the WisePops' cookie max size limit

Another solution is to change the cookie max size limit. WisePops uses this limit to trigger the cleanup of the oldest data about your visitor. When this size is reached, WisePops will "forget" that your visitor saw some popups. The ones he saw the longest ago.

This solution is less elegant than the first one, but do preserve the ability to share the data about your visitors across sub-domains.

To change the default cookie max size to 1 KB, copy and paste the following code between your setup code and the closing </script> tag:

wisepops('options', {
cookieMaxSize: 1024
});

The script containing your WisePops setup code and this option should look like this:

Don't hesitate to contact us if you have any question.

Did this answer your question?