Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.cookiechimp.com/docs/llms.txt

Use this file to discover all available pages before exploring further.

Add your website’s CookieChimp JS snippet in the <head> tag of your HTML, before the Adobe Launch embed code.
Do not deploy our HTML snippet through Adobe Launch. CookieChimp needs to run before any other script so it can block tags and set defaults before Launch initialises its extensions.
The CookieChimp script needs to be added at the top of the <head> section, so that it can run first, in order to ensure other scripts are only run based on consent. If other scripts are added before, they may set cookies and other storage items before consent is granted.
<script src="https://cookiechimp.com/widget/abc123.js"></script>
<script src="//assets.adobedtm.com/your-property/launch-XXXXXXX.min.js" async></script>
You need to replace abc123 with your website’s unique CookieChimp ID and the Adobe Launch URL with the embed code from your Launch property’s Environments page.

How does CookieChimp work with Adobe Launch?

Adobe Launch (now Adobe Experience Platform Tags) does not have a native consent mode like Google Tag Manager does, so consent is enforced inside each rule using a Data Element and a rule condition. CookieChimp exposes two things you’ll wire into Launch:
  • window.cookieChimpConsentString — a comma-separated string of the categories and services the visitor has consented to, e.g. essential,analytics,marketing,Google Analytics,Hotjar,Facebook Pixel. You read this from a Data Element.
  • cc:consentStringUpdated — a window event that fires once consent has been granted and again every time the visitor changes their preferences. You listen for it from a rule’s event.
Together, these let any Launch rule (a) wait for consent to be available and (b) only run when the matching category or vendor was accepted.

How do I block tags with Adobe Launch?

1

Create a Data Element for the consent string

In your Launch property, go to Data Elements and click Add Data Element.
  • Name: CookieChimp Consent String
  • Extension: Core
  • Data Element Type: Custom Code
  • Storage Duration: None (read it fresh on every reference)
Paste the following into the code editor and save:
var consent = window.cookieChimpConsentString || "";
return consent ? "," + consent + "," : "";
This Data Element returns the latest comma-separated list of consented categories and vendors, wrapped with leading and trailing commas. You’ll reference it as %CookieChimp Consent String% from your rule conditions.
Wrapping the value with commas is important. It lets you match ,Hotjar, exactly — without the commas, Launch’s Contains operator would also match a different vendor that happens to include Hotjar as a substring (e.g. Hotjar Surveys).
Keep Force lowercase value off. Vendor names in the consent string match the casing used in your CookieChimp Vendor Library, e.g. Google Analytics.
2

Add a custom event to listen for consent updates

Open the rule for the tag you want to gate (or create a new rule), and add an Event of type Custom Code under the Core extension.trigger() is a function Adobe Launch injects into Custom Code events. Calling it tells Launch to evaluate the rule’s conditions and run its actions.
The cc:consentStringUpdated event is dispatched on window after CookieChimp has read the visitor’s choices and rebuilt the consent string, so it’s safe to read window.cookieChimpConsentString from inside the listener.
3

Add a condition to gate the tag on consent

Add a Condition to the rule of type Value Comparison under the Core extension.
4

Save, build, and publish

Save the rule, add it to a Library, build the library, and publish to your environment as you normally would in Launch.Repeat the event and condition steps for any other rule that loads a tag requiring consent. The Data Element only needs to be created once and can be reused across every rule.
Your tags are now consent-aware. They will:
  1. Wait until CookieChimp has determined the visitor’s consent state.
  2. Only fire when the required category or vendor is in the consent string.
  3. Re-evaluate automatically whenever the visitor updates their preferences from the banner or privacy trigger.

How do I debug my Adobe Launch setup?

Adobe Launch ships with a debug mode that logs every rule evaluation to the browser console. Enable it by running the following in your DevTools console:
_satellite.setDebug(true);
Reload the page and you’ll see each rule’s events, conditions, and actions logged as they run. You can also inspect the consent string directly:
window.cookieChimpConsentString;
// => 'essential,analytics,marketing,personalization,Cloudflare,CookieChimp,Google Analytics,Hotjar,Facebook Pixel'
If a rule is not firing as expected:
  • Confirm the Data Element returns a non-empty string after consent is granted.
  • Confirm the vendor or category name in your condition matches what appears in the consent string exactly.
  • Confirm the CookieChimp snippet is loaded before the Launch embed code in your <head>.
If you are using the Adobe Experience Platform Web SDK (alloy), it has its own consent command that accepts an IAB TCF string or the Adobe consent standard. The pattern above — reading window.cookieChimpConsentString from a Data Element and listening for cc:consentStringUpdated — works for any Web SDK rule too: call alloy("setConsent", ...) from the rule’s action, mapping CookieChimp’s categories to the consent object Adobe expects. If you need help wiring CookieChimp into a specific Adobe Web SDK setup, get in touch and we’ll work through it with you.