Cross-Domain Tracking for WooCommerce
Quick answer: The wizard's Cross-Domain Tracking checkbox doesn't currently modify your container. To track a visitor across two domains correctly in GA4, add both domains to the GA4 Configuration tag's "Configure your domains" field directly in GTM - this keeps a single session ID as visitors move between them.
Cross-domain tracking matters whenever a customer's journey crosses domains you own - a storefront on one domain and a hosted checkout, payment gateway, or headless frontend on another. Without it, GA4 treats the visitor as two separate sessions and attributes the purchase to a new, direct-traffic session instead of the original marketing source.
Manual setup steps
- In GTM, open your GA4 Configuration tag.
- Under Tag Settings, find "Configure your domains" and add every domain the customer journey spans (e.g. yourstore.com and checkout.yourpaymentprovider.com).
- Publish the container, then click any outbound link between the two domains in Preview mode and confirm a _gl linker parameter is appended to the URL.
- Complete a full test purchase across both domains and confirm in GA4's real-time report that it registers as one session, not two.
Note this configures the linker parameter inside GTM only - it doesn't change server-side session or cookie behavior on either domain, which is outside what a GTM container alone can control.
Frequently asked questions
Do I need this if my whole store is on one domain?
No - cross-domain tracking only matters when the customer journey genuinely spans more than one domain you control. A single-domain WooCommerce store doesn't need it.
What's the _gl parameter I see appended to links?
That's the linker parameter GA4 uses to pass a client/session identifier between your configured domains, so the second domain recognizes it as the same visit rather than starting a new session.
Does this affect Meta, TikTok, or other platform tags too?
No - the domain linking behavior described here is specific to GA4's native tag settings. Other platforms handle cross-domain identity differently, typically through their own pixel/cookie matching.