Addingwell
Complete technical guide: the Shopify infrastructure plugin. Installation, GA4 DataLayer, checkout Custom Pixel, GTM injection, adblocker bypass, cookie restore, attribution cookies, DataLayer Monitor.
1Role / Purpose
Addingwell is the infrastructure plugin that automates the entire technical layer of Shopify tracking:
- Automatic GA4 DataLayer injection (11+ e-commerce events)
- Custom Pixel for checkout events (begin_checkout, purchase)
- GTM injection on every page of the store
- Adblocker bypass through a first-party CDN proxy
- Cookie restore to work around Safari ITP
- Hosting for the sGTM server (server-side GTM)
Addingwell replaces every manual DataLayer setup. No custom code is needed in the theme for tracking.
2Architecture
What Addingwell installs automatically
Shopify Store ├── GA4 DataLayer (every page) │ └── 11+ standard e-commerce events ├── Custom Pixel (checkout) │ └── begin_checkout + purchase ├── GTM Web Container (injection) │ └── Script injected on every page ├── CDN Proxy (adblocker bypass) │ └── First-party domain for the scripts ├── Cookie Restore (Safari ITP) │ └── First-party cookie restoration └── sGTM server └── Custom domain + configurable region
Where it sits in the stack
Shopify
→ Theme layer
→ Cookiebot bridge → Shopify Privacy API
→ Addingwell
→ GA4 DataLayer + DataLayer Monitor (custom pixel)
→ GTM Web
→ Cookiebot CMP (Consent Mode v2, EEA + UK)
→ GA4 tag → sGTM
→ Meta Pixel → sGTM
→ Google Ads tag → sGTM
→ sGTM (Addingwell server)
→ GA4 (server)
→ Meta CAPI (server)
→ Google Ads Enhanced Conversions (server)
→ Attribution cookies (fbp, fbc, gclid, wbraid, gbraid)Benefits
- Zero theme configuration — everything is automatic
- Works with every Shopify theme
- No custom Liquid code needed for tracking
- Updates itself when Shopify changes its APIs
- Native support for multi-currency markets
3Installation
Create an account and install
- 1Create an account on addingwell.com (active billing required)
- 2Install the Shopify plugin from the Addingwell App Store
- 3In the plugin settings, enable the features below
Features to enable
| Feature | Role |
|---|---|
| GA4 DataLayer | 11+ automatic e-commerce events |
| GTM injection | GTM on every page of the store |
| Checkout Custom Pixel | Checkout events (begin_checkout, purchase) |
| Adblocker bypass | CDN proxy, works around blockers |
| Cookie restore | Safari ITP bypass, long-window attribution |
Configure the checkout custom pixel
- 1Shopify Admin > Settings > Customer Events
- 2Add custom pixel > paste the code Addingwell provides
Permission: Not required
The Custom Pixel uses the "Not required" permission. It relies on Google Advanced Consent Mode through GTM, not on the Shopify Privacy API. Never change this permission.
Configure the sGTM server
- 1Create the server in the Addingwell dashboard
- 2Custom domain: tags.my-store.com (your subdomain)
- 3Recommended region: Europe multi-region
Configure DNS (custom domain)
The custom domain (e.g. tags.my-store.com) serves as both the sGTM endpoint and the CDN proxy for GTM. It is what makes first-party tracking possible (adblocker bypass, Safari ITP).
| Type | Name | Value |
|---|---|---|
| CNAME | tags | provided by Addingwell |
The exact CNAME value appears under Addingwell > Server > Custom Domain when the server is created. DNS propagation: a few minutes to 48h depending on the registrar.
4GA4 DataLayer
Injected e-commerce events
| GA4 event | Page | Description |
|---|---|---|
| page_view | All | Page load |
| view_item_list | Collection | Product list view |
| select_item | Collection | Click on a product |
| view_item | Product | Product page view |
| add_to_cart | Product / Collection | Added to cart |
| remove_from_cart | Cart | Removed from cart |
| view_cart | Cart | Cart view |
| begin_checkout | Checkout | Checkout started (Custom Pixel) |
| add_shipping_info | Checkout | Shipping details entered |
| add_payment_info | Checkout | Payment details entered |
| purchase | Thank you | Purchase confirmed (Custom Pixel) |
Structure of an event
dataLayer.push({
event: "view_item",
ecommerce: {
currency: "EUR",
value: 49.90,
items: [{
item_id: "SKU-001",
item_name: "Premium T-Shirt",
price: 49.90,
quantity: 1
}]
}
})Quick check
- 1Open the browser console on the store
- 2Type dataLayer and inspect the events
- 3Browse: page → collection → product → cart
- 4Check page_view, view_item_list, view_item, add_to_cart
This structure is generated automatically by Addingwell. No custom dataLayer.push() is needed.
5Checkout Custom Pixel
The Shopify checkout is isolated (iframe). Addingwell uses a Custom Pixel to capture the checkout events.
Captured events
- begin_checkout — the purchase process starts
- purchase — purchase confirmed, with transaction_id, value, items
Permission: Not required
The Custom Pixel uses the "Not required" permission. That is deliberate: it relies on Google Advanced Consent Mode through GTM, not on the Shopify Privacy API. Never change this permission.
Checkout event flow
Shopify Checkout (iframe)
↓
Addingwell Custom Pixel
↓
dataLayer.push({ event: "purchase", ... })
↓
GTM Web Container
↓
GA4 → sGTM → DestinationsGTM injection
Addingwell injects the GTM Web snippet automatically on every page of the Shopify store.
- No need to edit theme.liquid
- Optimised injection (async, non-blocking)
- Works with every theme
- The snippet updates itself
- Supports the CDN proxy for adblocker bypass
GTM injection through Addingwell is the recommended method. Do not inject GTM by hand into the theme when Addingwell is installed.
Adblocker bypass
Normal request (blocked) browser → googletagmanager.com ✗ (adblocker) Request through the CDN proxy (passes) browser → cdn.mystore.com → googletagmanager.com ✓
- First-party CDN proxy on the store domain
- GTM/GA4 scripts are served from the same domain
- Adblockers do not block first-party requests
- Recovers 15-30% of otherwise lost data
6Cookie Restore / Attribution
The Safari ITP problem
Safari ITP caps JavaScript first-party cookies at 7 days (or 24h in some cases). Tracking identifiers (_ga, _fbp, _fbc) expire far too quickly.
The Cookie Restore solution
- Addingwell intercepts the cookies before they expire
- The cookies are rewritten through a server-side endpoint
- Server-side cookies are not affected by ITP
- Lifetime restored to its normal value (2 years for _ga)
Impact
Without cookie restore, Safari attribution is capped at 7 days. With it, the attribution windows return to their normal length.
Attribution cookies (1P)
Attribution cookies are persisted first-party by Addingwell (cookie restore). They survive Safari ITP and browser purges, which is what makes attribution reliable.
| Cookie | Platform | Usage |
|---|---|---|
| _fbp | Meta | Browser ID: identifies the browser for CAPI matching |
| _fbc | Meta | Click ID: captures the fbclid from Meta ads |
| _gcl_aw (gclid) | Google Ads | Click ID: Google Ads conversion attribution |
| _gcl_gb (gbraid) | Google Ads | Click ID: cross-device attribution (app→web) |
| _gcl_gw (wbraid) | Google Ads | Click ID: web-to-app attribution, iOS 14.5+ |
These cookies are read and forwarded automatically by the sGTM to their respective destinations. Addingwell's cookie restore rewrites them first-party through the custom domain, working around Safari ITP (7 days → full lifetime).
7DataLayer Monitor
The DataLayer Monitor is a Shopify Custom Pixel that adds an observability layer over the tracking. It instruments dataLayer.push() and gtag(), loads the Addingwell snippet, and provides real-time debugging tools.
Features
| Feature | Description |
|---|---|
| dataLayer instrumentation | Intercepts every dataLayer.push() for logging and auditing |
| gtag() instrumentation | Captures gtag() calls (config, event, consent, set) |
| Styled console | Structured, colour-coded logs in the DevTools console |
| Duplicate audit | Detects events sent more than once (configurable window) |
| PII masking | Masks sensitive data (email, phone) in the console logs |
| Debug mode | Enabled with ?awdebug=1 in the URL: verbose logs |
| Page context push | Publishes reliable page_location, page_referrer and page_title from init.context |
| Shopify Customer Events | Subscribes to the standard Shopify events and logs them |
| Addingwell loader | Loads the Addingwell snippet inside the custom pixel context |
Installing the Custom Pixel
- 1Shopify Admin > Settings > Customer Events > Add custom pixel
- 2Name: "AW × BE. DataLayer Monitor"
- 3Permission: "Not required" — the pixel uses Google Advanced Consent Mode through GTM
- 4Data sale: "Not a data sale"
- 5Paste the DataLayer Monitor script (v3.0.0)
- 6Connect the pixel > Save
Debug mode is enabled by adding ?awdebug=1 to any store URL. Verbose logs appear in the DevTools console with colour-coded badges per event type.
Only one checkout pixel active
This custom pixel replaces the default Addingwell checkout pixel. Never run both at once: that causes duplicates.
8Configuration
Prerequisites
- Active Addingwell account (billing required)
- Shopify store connected
- GTM Web Container ID (GTM-XXXXXXX)
- Custom domain configured for the CDN proxy and sGTM (recommended)
Configuration steps
- 1Install the Addingwell app from the Shopify App Store
- 2Connect the store in the Addingwell dashboard
- 3Enter the GTM Web Container ID
- 4Enable the CDN proxy (adblocker bypass)
- 5Enable Cookie Restore (ITP bypass)
- 6Create the sGTM server + configure the custom domain DNS
- 7Verify the GTM injection on the store
sGTM configuration
| Parameter | Value |
|---|---|
| Custom domain | tags.my-store.com (a store subdomain) |
| Region | Europe multi-region (recommended) |
| DNS | CNAME: value provided by Addingwell |
9Verification
Phase 1: Addingwell infrastructure
- 1Addingwell plugin active in Shopify (Apps > Addingwell)
- 2GA4 DataLayer present — type dataLayer in the console
- 3Checkout custom pixel configured in Addingwell
- 4Cookie restore active — shopify_y field present in the DataLayer
- 5First-party sGTM requests visible in Network (custom domain)
- 6sGTM custom domain answers with status 200
Verify the DataLayer
- 1Open the browser console on the store
- 2Type dataLayer and inspect the events
- 3Browse: page → collection → product → cart
- 4Check page_view, view_item_list, view_item, add_to_cart
- 5Complete a test checkout → check begin_checkout and purchase
Verify GTM
- Open GTM Preview Mode
- The events must appear in the debug panel
- Check that the ecommerce variables are populated
Verify the CDN proxy
- Open the browser's Network tab
- GTM/GA4 requests must point to the custom domain
- No direct request to googletagmanager.com
Verify the attribution cookies
- DevTools > Application > Cookies
- Check that _fbp, _fbc and _gcl_aw (gclid) are present
- The cookies must carry the store domain (first-party)
10Troubleshooting
Check:
- 1Addingwell app installed and connected
- 2Store active in the Addingwell dashboard
- 3No conflict with another DataLayer script
Check:
- Custom Pixel active under Settings → Customer Events
- Permission = "Not required"
- No JS error in the checkout console
- Check that the purchase trigger exists in GTM
- Check that the sGTM request answers 200
Check:
- GTM Container ID correct in Addingwell
- No manual GTM snippet in the theme (conflict)
- Addingwell app enabled
Check:
- Cookie Restore enabled under Addingwell > Settings
- Check the shopify_y field in the DataLayer
- Check the sGTM custom domain DNS records
- sGTM custom domain answers with status 200
Check:
- Cookie restore disabled in Addingwell
- sGTM custom domain not configured
- The cookies must appear under DevTools > Application > Cookies with the store domain
Check:
- Check that only one checkout custom pixel is active (DataLayer Monitor OR the Addingwell pixel, not both)
- Check in GTM that an event does not have two active triggers
- Use ?awdebug=1 to see the duplicate audit in the console
Check the layer you just set up
Scan the store: 41 checks read what it now sends to GA4, Meta and Google Ads.