Skip to main content

How to Exclude CookieYes Script from the NitroPack WordPress Plugin

Last updated on August 27, 2024

Overview

NitroPack is a WordPress plugin that optimizes website performance using techniques like caching and script optimization. However, NitroPack’s optimization can sometimes interfere with CookieYes’s functionality. This guide provides step-by-step instructions on how to exclude the CookieYes script from optimization by the NitroPack in WordPress, ensuring that CookieYes functions correctly without interference.

Steps to exclude CookieYes script from the NitroPack WordPress plugin

Step 1: Access NitroPack Dashboard

Log in to your WordPress admin Dashboard and navigate to NitroPack > Dashboard in the left sidebar.

WordPress Dashboard: Nitropack
Step 2: Open the NitroPack App

On the NitroPack Dashboard, scroll down and click the Go to app button.

Go to Nitropack App
Step 3: Access Exclusion Settings in NitroPack App

In the NitroPack App, go to the Cache Settings > Cache and scroll down to the Exclusions section.

NitroPack Dashboard
Step 4: Add CookieYes Scripts to the Exclusion List

To ensure that NitroPack does not optimize CookieYes scripts, add the following entries to the exclusion list:

  1. Exclude scripts from cookieyes.com
    Enter cookieyes.com in the Asset URL/Code to the exclusion list to prevent NitroPack from optimizing any scripts coming from this domain.
  2. Exclude scripts matching cookie-law-info
    Add cookie-law-info to the exclusion list to prevent any scripts with paths starting with this name from being optimized.
  3. Exclude scripts related to _ckyGcm
    Add _ckyGcm to exclude any scripts containing this pattern
List of script to exclude

Make sure to enter these exactly as shown, following the correct syntax.

Step 5: Save the Changes

After adding these scripts to the exclusion list, click the Save button. This ensures that NitroPack will exclude these specific scripts from optimization.

Conclusion

It is critical that you exclude the CookieYes script from NitroPack optimization to ensure the proper function of cookie consent management on your website while still benefiting from NitroPack’s performance enhancements. By following this guide, you’ve successfully configured NitroPack to ignore CookieYes scripts, allowing both plugins to work simultaneously without any conflicts on your WordPress site.

Remember that while this configuration optimizes the compatibility between NitroPack and CookieYes, it’s important to regularly check your website’s performance and functionality. As plugin updates occur, you may need to revisit these settings to ensure continued compatibility.

For further assistance, our dedicated support team are here to assist you.

Have more questions?

Reach out to us and we'll answer them.

Contact us