Reputation: 669
I have 10 website domains and these domains are masked and forwarding to one website hosting place, in one website hosting place i handled with url what page i should open when specific domain is hit. now i want to put google analytics code in one place where one website is hosted. when i generate a code for website from google analytics, it generate one website code at a time. and i want to add it generically for all 10 websites,
Explaining the problem statement: I have main domain named as abcd.com and other domains are cde.com,efg.com,ghi.com etc all cde.com,efg.com,ghi.com are redirecting with masking to abcd.com/id=123 or abcd.com/id=456 respectively.
my question is that if i create google analytics code for cde.com, and place it in abcd.com home page. it should work for all cde.com, efg.com,ghi.com etc sites. but unfortunately, i am unable to do.i have to create script seperately for all domains.
Upvotes: 0
Views: 250
Reputation: 1674
You can add a single GA code across the site. All hits will be sent to the database associated with web property UA-XXXXXX-Y
GA will associate the hits with whatever hostname appears on the user's browser URL bar.
In GA, under property UA-XXXXXX-Y
you can set up views for each domain:
Upvotes: 1