4.3K members online now
Learn to identify referral spam traffic, as well as best practices to reduce referral spam in your Google Analytics account
 
Guide Me
star_border
Reply

Self referrals

Visitor ✭ ✭ ✭
# 1
Visitor ✭ ✭ ✭

Hi,

 

I am having issues with self referrals. Here are some key points:

 

  • Desktop site is www.switzer.com.au and mobile site is m.switzer.com.au
  • I recently implemented GTM (although have been having issues for about 24 months - I only recently started managing this).
  • I have the GTM plugin and every page I check has the same GA code. All seems well.
  • (I think) I have set up cross-domain tracking in GTM (see screenshot)Screen Shot 2016-11-27 at 11.59.13 am.png 
  • We have a mobile site instead of a responsive site. Traditionally we had 2 GA accounts, one for mobile and one for desktop but I set up GTM with the same code across both site and measure all traffic in one GA account now. Again, I was having issues with self-referrals before I consolidated the accounts so don't believe this to be the issue

 

Please help!

 

Tom

1 Expert replyverified_user

Re: Self referrals

[ Edited ]
Participant ✭ ✭ ✭
# 2
Participant ✭ ✭ ✭

Hi Tom,

 

Cross-domain tracking is not needed in this case but you'll need to configure tracking across subdomains in GTM.

 

First of all:

 

1) You should remove allowLinker: true - it's not needed in this case.

2) You should remove auto link domains from your settings in GTM - it's not needed in this case.

 

Secondly:

 

1) In the Fields to Set of your Universal Analytics every tag, add the following setting:

 

Screen Shot 2016-11-27 at 05.52.51.png

When you set cookieDomain to auto, the following will happen with domains like www.switzer.com.au and m.switzer.com.au:

 

The recursive algorithm tries to write the cookie, starting from the top-level domain, and stopping once it succeeds. What should be left is the root domain, and thus the cookie will be available to all subdomains.

 

Basically, you should add "cookieDomain: auto" to every tag in your GTM container and everything will be fine.

 

2) Make sure you've added switzer.com.au to your referral exclusion list in Google Analytics:

 

referral exclusion.png

 

That's it. It should help you to fix the issue.

 

One more thing to keep in mind is that those self-referrals will not disappear overnight just because of the cookies.


However, this number should steadily decline (and you should see near 0% new users) until after 6 months when it should disappear entirely.

 

Hope this helps. Let us know how it goes.

Taavi

 

Re: Self referrals

[ Edited ]
Top Contributor
# 3
Top Contributor

To add to @Taavi Kalvi excellent info

Something i noticed is that switzer.com.au does not 301 redirect to www.switzer.com.au 
The site is accessible by both urls. Usually (but not always) for tracking purposes and SEO the non preferred

domain would be redirected to the preferred domain

 

eta.. usually you should also create a new View and add the following filter to io prepend the hostname to request uri's in reports
This will allow you to then differentiate in the reports, which domain a pageview happend on

  • Filter Type: Custom filter > Advanced
  • Field A: Hostname Extract A: (.*)
  • Field B: Request URI Extract: (.*)
  • Output To: Request URI Constructor: $A1$B1



Also when checking the site with Google Tag Assistant.. it gives an error for the GTM Container

Not sure why it saying that id is invalid though

missing-id.jpg

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

Self referrals

Visitor ✭ ✭ ✭
# 4
Visitor ✭ ✭ ✭

Thanks for your help Taavi,

 

Implementing this now. Will let you know how I go.

 

Tom

Self referrals

Visitor ✭ ✭ ✭
# 5
Visitor ✭ ✭ ✭

Thanks Bronwyn for your help.

 

The GTM has that error because it is a new GTM account. Because the new accounts have 7 characters in the account number it throws an error. It's a known issue apparently (although I wasted a lot of time figuring it out!) and the data is flowing successfully.

Self referrals

Top Contributor
# 6
Top Contributor

Thanks @Tom H, I was not aware of that, appreciate you posting back with that info!! :-)

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