Analytics Guide: How to Setup Cross Domain Tracking for Google Analytics in 5 Steps
Contributor, May 28, 2018
If you own multiple domains and want to track a single user’s visit across them all, you should consider enabling multi-domain user tracking by adjusting your settings in Google Tag Manager.
In a case of a website with multiple subdomains, cross-domain tracking is not necessary since the default Google Analytics tracking code on your site is already enabled to function and report data across subdomains of a single website.
Conversely, a typical use case for this multi-domain user tracking is an eCommerce site with third-party shopping carts featured on separate domains.
Google recommends as a best practice to adopt a setup which features multiple views:
• One view of all the traffic in the cross-domain tracking setup.
• Separate analytics views for each domain.
If one does not set up cross-domain tracking, it could become problematic to view the conversion especially if it happens on multiple sites. The quickest way to implement cross-domain is by utilizing Google Tag Manager to edit the Google Analytics tag to enable this feature.
Five Easy Steps: Cross Domain Tracking in GTM for Google Analytics
Enter Google Tag Manager. Enter the Google Analytics tag and enable “Overriding” settings inside the tag. Overriding will give us access to additional configurations we can make to the tag.
Select the more settings option, then fields to set and then click add field option. For the Field Name we add ‘Allow Linker,’ and for “Value” we write “True.” Doing this will tell Google Analytics that we want to automatically modify links on our website so that when people click them, it will synchronize the Google Analytics cookie on the other site.
Add another field ‘CookieDomain’ and then ‘auto’ for value. Doing this will tell Google Analytics to automatically choose a cookie domain to use when we track users.
Select ‘Cross-Domain Tracking,’ and in the Auto Link Domains field, we need to enter the domains we want to track each separated by a comma.
Save the tag and publish the container.
Following these simple five steps will allow you to track conversions more accurately across multiple domains. From an implementation point of view, Google Tag Manager shortens our development time as well as provides you a quick debugging environment to make sure that the implementation is achieved correctly.
If you would like professional buy-side or sell-side consulting or assistance with your Google Analytics account, you can contact us.