AdWords is now Google Ads. Our new name reflects the full range of advertising options we offer across Search, Display, YouTube, and more. Learn more

Analytics
1.7K members online now
1.7K members online now
Learn how to set up goals and Ecommerce tracking, verify accuracy of attribution traffic sources, and discuss funnel visualization, Multi-Channel Funnels, the Goal Flow Report, and Enhanced Ecommerce
 
Guide Me
star_border
Reply

UTM codes and cross domain tracking

Visitor ✭ ✭ ✭
# 1
Visitor ✭ ✭ ✭

I have a landing page on domain A and I will be using a UTM code to bring visitors to that landing page. Once that visitor is ready to enroll we have an enrollment site on a different domain, domain B, that we present through an iframe on domain A. Can I carry over and capture the UTM code on domain B? Is this possible through cross domain tracking in Analytics? Thanks!

2 Expert replyverified_user

UTM codes and cross domain tracking

Top Contributor
# 2
Top Contributor

Hi @Amanda H cross domain tracking should take care of traffic atrribution in your case - no need to transfer UTM parameters as with cross domain tracking GA does that for you in a way.

 

Kind regards,

Zorin

Web analyst @ escapestudio.net

UTM codes and cross domain tracking

Visitor ✭ ✭ ✭
# 3
Visitor ✭ ✭ ✭

Hi Zorin,

I have a problem.

 

I have two domains configured with the cross-domain.
www.DominioA.com
abcd.DominioB.com (Booking Engine)
The selection of the Booking Engine uses analytics.js
Now both domains have the same code:

<Script> (function (i, s, o, g, r, a, m) {i [ 'GoogleAnalyticsObject'] = r i [r] = i [r] || function () {(i [r] .q = i [r] .q || []). push (arguments)}, i [r] .l = 1 * new Date (); a = s.createElement (o), m = s.getElementsByTagName ( o) [0]; a.async = 1; a.src=g; m.parentNode.insertBefore (a, m)}) (window, document, 'script', '// www.google-analytics.com/ analytics.js', 'ga'); ga ( 'create', 'UA-XXXXXXX-X', 'self', { 'allowLinker': true}); ga ( 'require', 'linker'); ga ( 'linker: autoLink', [ 'www.DominioA.com', 'abcd.DominioB.com']); ga ( 'send', 'pageview'); </ script>

 

This is the user-flow:
1 The user lands on site A.
2 The user clicks on a button and goes on the B domain.
3 On domain B, the user purchases and unleashes events.

 

The events of domain B do not have the source / medium for Adwords and UTM campaigns (facebook-email etc.). While presenting the source / medium for natural research and referrals.

The respective domains have been excluded from the google analytics, as well as the roots.

Everything seems configured perfectly, but the advertising does not have the source / medium.

Do you have a solution?
Have you already had any problems like that?

Re: UTM codes and cross domain tracking

Top Contributor
# 4
Top Contributor

Hi @Federico G :-)

 

With the tracking code on both sites, the cookieDomain in the code snippet should be set to auto not self

ga('create', 'UA-XXXXXXX-Y', 'auto', {'allowLinker': true});

Also, do you have a cross domain tracking View created with the appropriate filter?

 

once the cookieDomain in the tracking code has been fixed on both sites, are you able to please provide a link to the website page that has the button that gets clicked?

 

Thanks
Bronwyn

Bronwyn Vourtis, Google Analytics Top Contributor
Was my response helpful? If yes, please mark it as the ‘Best Answer.’ Learn how here

UTM codes and cross domain tracking

Visitor ✭ ✭ ✭
# 5
Visitor ✭ ✭ ✭

HI @Bronwyn V
Thanks a lot !!!
this is the url:
goo.gl/kfUtak
You can click on "book now"
I have excluded the domains from "Referral exclusion list" on google analytics.
I do not need filters, because I do not care to separate the traffic. It's okay to see everything together.

The problem is that one user comes from UTM and Adwords and click on "book now" Analytics create a new session (none) / (direct)

thank you so much

UTM codes and cross domain tracking

Visitor ✭ ✭ ✭
# 6
Visitor ✭ ✭ ✭

@Bronwyn V
the events generated by the second domain  have all source/medium - (direct)/(none)
Thanks again

Re: UTM codes and cross domain tracking

Top Contributor
# 7
Top Contributor

Thanks for posting back @Federico G :-)

 

I'm curious about the cross domain tracking .
It seems to have crossdomain tracking setup on both sites using the autolink method,

however the initial site also seems to be using the non autolink method too by attaching

the clientID as a query parameter to the URL as it crosses over to the booking site, rather than using

the usual _ga=

 

This is also generating an error on the main site:

Unknown method name: '_createAsyncTracker', 

ga undefined

There are also other query parameters on the url once arriving at the booking site.

 

I would test the following on the main domain

<!-- Google Analytics -->
<script>
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');

ga('create', 'UA-48432998-2', 'auto', {allowLinker: true});
ga('require', 'linker');
ga('linker:autoLink', ['www.montaltointoscana.com', 'webhotels.passepartout.cloud'], true, false);
ga('send', 'pageview');
</script>
<!-- End Google Analytics -->

 

with the following on the booking domain.

<!-- Google Analytics -->
<script>
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');

ga('create', 'UA-48432998-2', 'auto', {allowLinker: true});
ga('require', 'linker');
ga('linker:autoLink', ['www.montaltointoscana.com', 'webhotels.passepartout.cloud'], true, false);
ga('send', 'pageview');
ga('create', 'UA-96849775-1', 'auto', 'Passepartout'); ga('Passepartout.send', 'pageview'); </script> <!-- End Google Analytics -->

Just out of curiosity, when on the booking domain, do they get sent/redirected back to the main domain 

via any form submissions or similar?

Bronwyn Vourtis, Google Analytics Top Contributor
Was my response helpful? If yes, please mark it as the ‘Best Answer.’ Learn how here

UTM codes and cross domain tracking

Visitor ✭ ✭ ✭
# 8
Visitor ✭ ✭ ✭

Hi @Bronwyn V
I have try the code.

The codes have been entered by the respective agencies. (site agency and booking engine)
Unfortunately, however, the Events on the "booking engine" still have (none) / (direct) or (montaltointoscana.com) / (referral)

In one case I managed to get a source / medium for natural research. UTM link from mail with clean browser (cache and cookies removed).

Do you have any other suggestions?
thank you so much
Federico

UTM codes and cross domain tracking

Top Contributor
# 9
Top Contributor

Hi @Federico G :-)

Where does the url for that link come from/how is it generated?
When i look at the link itself, its just an anchor link # not a link leading to the external booking site (as such)

Bronwyn Vourtis, Google Analytics Top Contributor
Was my response helpful? If yes, please mark it as the ‘Best Answer.’ Learn how here

UTM codes and cross domain tracking

Visitor ✭ ✭ ✭
# 10
Visitor ✭ ✭ ✭

- The user from AdWords do not generate source/medium
- I put the UTM link in an email and sent it to testers.
Opening the link directly from the email, the UTM activates normally on the first site.

- The link above has developed the company that created the site. I suppose it's a javascript.
Could it be this link, to block the source/medium?

Thanks so much
Federico