Update time: March 27, 2026
This guide explains how to integrate TrustArc with the Experience Cloud ID Service to manage cookie consent and control Adobe Analytics tracking behavior.
Expected Outcome
- The default is not to track
- If a user declines consent → Adobe Analytics tracking is disabled
- If a user accepts consent → Adobe Analytics tracking is enabled
What is TrustArc?
TrustArc, Inc. (formerly TRUSTe) is a privacy compliance technology company headquartered in Walnut Creek, California.
It provides software and services that help organizations manage privacy compliance and align with global regulations and best practices.
How It Works (Technical Overview)
When a user interacts with the cookie banner: A cookie_prefs_set event is pushed via dataLayer.push,consent preferences are stored in the cookie: cmapi_cookie_privacy, eg:
Value “2” in cmapi_cookie_privacy indicates analytics consent granted, This enables the following rule logic:
- For the First Page View trigger is event cookie_prefs_set, and cookie cmapi_cookie_privacy contains 2
- For Subsequent Pages or Events: Add a Rule condition: cmapi_cookie_privacy contains 2.
Implementation Steps
Step 1:TrustArc Cookie Consent Manager Setup
In Adobe Launch, install the Cookie Consent Manager extension,No additional configuration is required within the extension
Configure TrustArc Rules:
Use the Core – Library Loaded (Page Top) event, Set the order as low as possible to ensure early execution
Cookie Consent Manager – Managed Service Consent Script is use TrustArc-provided JavaScript
Step 2:Experience Cloud ID Service Configuration
Install the Experience Cloud ID Service extension in Adobe Launch,configure Opt-In settings::
Set Enable Opt-In = Yes, This ensures: No tracking occurs before user consent
Previous Permissions: is to set the tracking of the default Adobe products. Generally, it is not tracked by default. It is set to { aa: false, ecid: false}, which ensures that the data will not be tracked when page open, and it will be updated when the user agrees, such as { aa: true, ecid: true}, which allows tracking.
The code in the data element adobeServicesOptIn is:
“2” = Analytics consent granted
Step 4:Rule Configuration
There is an event cookie_prefs_set that is sent after the user click agree, and then written authorization informationinto the cookie, so you can use the event cookie_prefs_set and cookie cmapi_cookie_privacy to set:
- For the First Page View trigger is event cookie_prefs_set, and cookie cmapi_cookie_privacy contains 2
- For Subsequent Pages or Events: Add a Rule condition: cmapi_cookie_privacy contains 2.
First Page (No Page Reload Required)
To use cookie_prefs_set event, Google Data Layer Extension needs to be installed.
After installation, add the following configuration to the Rule event of the basic PV:
This allows: Tracking to start instantly after user consent,no page reload required
Subsequent Pages & Events
For all other Rules, Add condition:
Note: Regex needs to be checked.
This ensures: Only users who have granted consent are tracked, full compliance with privacy requirements
Step 5:Testing
When loading by default, previousPermission is false:





