How to add a Privacy Controls and Cookie Solution to Bigcommerce

Built your website on BigCommerce and need to manage cookies? In this guide, you’ll learn when you need a cookie consent management system for BigCommerce and how to add iubenda’s Privacy Controls and Cookie Solution to your BigCommerce site.

Jump directly to How to add iubenda’s Privacy Controls and Cookie Solution to your BigCommerce site.

Yes, and here’s why.

If you have EU-based users and your website uses cookies (which it most likely does), you need to manage cookie consents according to the ePrivacy Directive and GDPR. This means you need to block cookie scripts and similar technologies until the user gives consent.

Also, for the consent to be considered valid, you need to make certain disclosures via a cookie banner and link to a more detailed cookie policy. See our getting started guide.

Need to add a privacy policy to your BigCommerce site? See the BigCommerce privacy policy integration guide.

What the solution supports

When you embed the Privacy Controls and Cookie Solution on your BigCommerce site, you get access to the full iubenda cookie management platform:

How to add iubenda’s Privacy Controls and Cookie Solution to BigCommerce

Not sure what privacy documents you need for your BigCommerce site? Take this quick quiz to see which laws apply to you and your business.

Once you’ve generated and customized your Privacy Controls and Cookie Solution, follow these steps to integrate it with your BigCommerce website:

First, head over to your iubenda dashboard and click on [Your website] > Privacy Controls and Cookie Solution > Embed.

How to add the Privacy Controls and Cookie Solution to BigCommerce

Here you can customize your banner and then click Copy to copy your Privacy Controls and Cookie Solution snippet.

How to add the Privacy Controls and Cookie Solution to BigCommerce

Next, open your BigCommerce admin panel and select Storefront from the left-hand menu.

How to add the Privacy Controls and Cookie Solution to BigCommerce

A drop-down menu will appear. Click on Script Manager.

How to add the Privacy Controls and Cookie Solution to BigCommerce

Click the Create a Script button on the right side of your screen.

How to add the Privacy Controls and Cookie Solution to BigCommerce

Fill in the form with the following settings:

  • Give the script a name (for example, “Privacy Controls and Cookie Solution” or “iubenda”)
  • Set Placement to Head
  • Set Location to All Pages
  • Set Script type to Script
How to add the Privacy Controls and Cookie Solution to BigCommerce

Paste the code you copied from your iubenda dashboard into the Script contents box and click Save.

How to add the Privacy Controls and Cookie Solution to BigCommerce

That’s it. You’ve successfully added the Privacy Controls and Cookie Solution to your BigCommerce site.

Few categories of cookies are exempt from the consent requirement. Therefore, almost all scripts that install or can install cookies must be blocked before consent is obtained.

Simplify your cookie-blocking process with auto-blocking

There’s a simpler option available for the prior blocking of cookies and trackers. Our auto-blocking feature automates the process, saving you time and effort.

If you prefer to manually tag your scripts that install or may install cookies, you can still follow the process below for step-by-step instructions and practical examples. However, we highly recommend considering the auto-blocking feature for a more streamlined approach.

Learn more about auto-blocking and how it can simplify your cookie-blocking process.

How to implement prior blocking via manual tagging on your BigCommerce site

Manual tagging is the method of prior blocking we’ll be using for the tutorial below. You can view other methods here.

To set up prior blocking, you need to make some minor changes to your site’s scripts. Here’s what to do:

  1. Identify the script/iframe for any additional services running on your website (e.g., Twitter follow button)
  2. Add some simple text to the HTML code (we’ll show you how below)
  3. Save

In this tutorial, we are going to block a Twitter follow button.

Not sure which services you need to block? If you’re using a cookie policy generated by iubenda, the services listed in your cookie policy are most likely the ones you need to modify now.

In your BigCommerce Themes panel, click Customize.

Then, in your Page Builder, find the script you need to modify (simply search for the service you want to block, in this case, the Twitter follow button) and click Expand HTML Editor to open the code editor.

Now, we’re going to change the script. To do this, we will make 3 simple changes:

  • Add this class: _iub_cs_activate to the script tags, and change the “type” attribute from text/javascript to text/plain
  • Replace the src with data-suppressedsrc or suppressedsrc
  • Specify the categories of the scripts/iframes with a special comma-separated data-iub-purposes attribute, e.g. data-iub-purposes="2" or data-iub-purposes="2, 3"

More about categories and purposes

Purposes are your legal reasons for processing the particular type of user data. Different scripts on your site will fall into different categories and serve different purposes. For example, Google Analytics may be used for Measurement, while the Pinterest button may be used for Experience enhancement (Purpose 3 below). Purposes are grouped into 5 categories each with an id (1, 2, 3, 4, and 5):

  • Necessary (id: 1)
  • Basic interactions & functionalities (id: 2)
  • Experience enhancement (id: 3)
  • Measurement (id: 4)
  • Marketing (id: 5)

For even more detailed info on categories and purposes, see our guide here.

Let’s take the Twitter follow button as an example:

We need to 1. Add the class and change the “type” attribute, 2. replace the src and 3. specify the categories.

The code structure should look like this:

Script modification example for prior blocking
<p>Twitter follow button:</p>

        <!-- please note type="text/plain" class="_iub_cs_activate" data-suppressedsrc="..." (manual tagging) and data-iub-purposes="3" (per-category consent) -->
<a href="https://twitter.com/iubenda" class="twitter-follow-button" data-show-count="false">Follow @iubenda</a>
  <script async type="text/plain" class="_iub_cs_activate" data-suppressedsrc="https://platform.twitter.com/widgets.js" data-iub-purposes="3" charset="utf-8"></script>

Now that you’ve made your changes, simply hit save, and you’re done.

Not sure if you’ve set up correctly? Check out the live example and FAQs below.

Live example

This is an example that shows everything we have described above. You can use this CodePen as a guide to see what happens before and after blocking scripts via manual tagging.

(see the example)

To demonstrate the cookie blocking feature, we’ve embedded a YouTube video and a Twitter follow button:
Follow @iubenda

Both scripts are blocked through manual tagging. Since both the YouTube video widget and the Twitter follow button are part of the Experience enhancement purpose (id 3), we’ve added data-iub-purposes="3" to their scripts so that the Privacy Controls and Cookie Solution can properly identify them for release.

Click on the Accept button, or just activate the “Experience enhancement” toggle, to release these scripts (refresh the page to return to the starting point).

How can I tell if I’ve set prior blocking up properly?

As you can see in the CodePen example, the YouTube and Twitter scripts do not load if you do not consent. (You can test this again by opening this link in incognito mode in your browser.)

After you have saved, open your site in incognito mode and check if the scripts you have blocked via manual tagging stay blocked until you consent.

For other blocking options, see Google Consent Mode as an alternative to prior blocking, Google Tag Manager to simplify the blocking of cookies, or the IAB Transparency & Consent Framework and how to enable it.

Good to know: BigCommerce-specific considerations

Keep these points in mind when using Privacy Controls and Cookie Solution on BigCommerce:

  • Script Manager is the recommended method. Use Storefront > Script Manager > Create a Script to add your snippet. Set placement to Head, location to All Pages, and script type to Script.
  • Google Tag Manager. If you already use GTM on your BigCommerce store, you can deploy your Privacy Controls and Cookie Solution snippet through GTM instead of Script Manager. See our Google Consent Mode with GTM guide.
  • Checkout pages. BigCommerce checkout pages have limited script support. Verify that your cookie banner loads correctly on checkout by testing in incognito mode.

Manage cookie consent for your BigCommerce website

Generate a cookie banner

See also

This site is registered on wpml.org as a development site. Switch to a production site key to remove this banner.