Tracking setup
Warning
Please observe any legal requirements when activating third-party plugins that might collect users data.
To set up tracking insert your Google- and Facebook-keys here

Setting up tracking with google analytics
Google Analytics
Google Consent Mode v2
From Chainbox verison 5.2.19, Consent Mode V2 has been supported, with consent default denied until relevant cookies are accepted.
By integrating GA4 with both Google Consent Mode v2 and a consent provider, website owners ensure that they're collecting data in compliance with privacy regulations and respecting user preferences regarding data collection and processing.
Enhanced E-commerce Tracking in GA4
Enhanced E-commerce tracking utilizes a wider array of triggers to map user behaviour. Tracking still follows the users consent-profile, and will be denied by default unless user accepts cookies. The events are pushed through a datalayer array and served to a GTM integration.
Chainbox support to ways of working with enhanced e-commerce event tracking:
- Via GA4 integration: recommended for businesses that simply want the events to go directly to GA4.
- Via Google Tag Manager: recommended for businesses that events go to through Google Tag Manager (requires configuration in GTM).
Supported events
- view_item
- select_item
- add_to_cart
- remove_from_cart
- view_cart
- begin_checkout
- purchase
Need more events?
Contact support@chainbox.dk with specifications on the event you need.
Configuration ➜ Datalayer to GA4
Events are sent straight to GA4 using the normal GA4 configuration. Requires configuration of enhanced e-commerce in GA4.
Configuration ➜ Datalayer to GTM
Requires configuration of enhanced e-commerce in GA4.
- Under 'Tracking' click 'Edit' next to "Google Tag Manager".

- Key must contain the GTM key.
- Custom url (optional) can be added (remember to ➜ whitelist external domain in CSP)
- Click "Enable tracking" button to enable tracking (ATTENTION: This disables normal GA4 integration)
Warning
When you activate the GTM datalayer, GA4 integration will be disabled and events sent to GTM instead of the built-in GA4 integration. You should have GTM ready to recieve events before doing this, or you will loose data.