One of the most important tools in the arsenal of internet marketing is data, and few tools can give you the insights you need like Google Analytics.  When you want to collect data insights from multiple websites, but you want that data funneled into one account for easy viewing, than you want to setup cross domain tracking.  It might sound difficult but in reality it is very quick, simple and easy.

There are multiple reasons people use cross domain tracking.  One way people use cross domain tracking is using third party shpping carts for ecommerce sites.  Other people use cross domain tracking for monitoring multiple top-level domains, or collect data from subdomains into a single analytics account.


Step 1: Setup your Google Analytics account

Go to Google and type in Google Analytics.  Go to the top right and hit “Access Google Analytics.”  Follow all the steps necessary to get your account setup.  When you start up your Google Analytics account you’ll be able to enter domains and with those steps you’ll find a that you’re given a code snippet with your tracking ID.


Step 2: Edit Tracking Code (Primary Domain)

Now before you go into your website’s header and insert the code Google gave you, you need to edit that tracking code first.  Take your code and open up your text editor.  Look at your code and find the “create” in the tracking code.


ga (‘create’, ‘UA-XXXXXXX-Y, ‘’)’

After you’ve found the create section you’ll want to the following changes.  You’ll be adding a lot and all the changes in the example below are in bold.


ga (‘create’, ‘UA-XXXXXXX-Y, ‘auto’, {‘allowLinker’: true});
ga(‘require’, ‘linker’);
ga(‘linker:autoLink’, [‘’] );

Now before you go entering your code make sure you replace the UA-XXXXXX-Y with your own tracking ID number, as well as replacing the sample url with your own.  If you have more than three domains you’ll need to add the urls from the other domains in the following format.


ga (‘linker:autoLink’, [‘’, ‘’]  );


Step 3: Edit Tracking Code (Second Domain)


The steps needed are similar to the ones above but you want to switch out the domain with your initial domain.  Again the changes are in bold.


ga (‘create’, ‘UA-XXXXXXX-Y, ‘auto’, {‘allowLinker’: true});
ga(‘require’, ‘linker’);
ga(‘linker:autoLink’, [‘’] );


Step 4: Setting Up Reporting

When you look at Google Analytics your domain won’t show, instead Google by default only shows the page path.  Since the actual full url isn’t listed you won’t actually know which domain the report is talking about.





The way to switch this so you can see what domain is actually being reported on is two things.

1) Copy your Reporting View

2) Create an Advanced Filter

Follow these steps when prompted from the dropdown menus, or when asked to select an option

Filter Type: custom filter > Advanced

Field A: Hostname Extract A (.*)

Field B: Request URI Extract (.*)

Output To: Request URI Constructor: $A1$B1
Click Save to setup the filter.