Google Analytics with GTM; is it possible that data will be duplicated? - google-analytics

I'm fairly new to Google Tag Manager, in the past I've just fired events straight to Google Analytics. What I'm wondering is this; is it possible that, if you use Google Analytics alongside Google Analytics tags in GTM, can you get duplicate data in Google Analytics?
For instance, let's say I have a Pageview tag in GTM, as well as GA on the webpage as normal. Would this count as two pageviews? (ie. one from standard GA, one from the GTM tag)
I've looked around for an answer, but maybe it's just a stupid question!

If both track to the same property you'd get two pageviews in that Ga property.
However there is a good chance that both pageviews would end up in different sessions; GTM creates a random name for the Google Analytics tracker, while the tracker within the page would track to the standard tracker (t0; read about naming trackers here), unless configured otherwise.
IMO it is not a good idea to mix GTM and inline trackers with the same property, since it's hard to be sure that both use the same configuration. And yes, your pageview will be counted twice.

Related

Is there a common list of areas to check while comparing GTM and analytics.js data in Google Analytics?

I have a website where we're working on migrating from analytics.js to GTM, so we've created a new temporary property for verifying that GTM is working as per expectations. The existing analytics.js code sends data to an older property.
I see a lot of cases where many users simply don't appear in the GTM tracking data, and we've also done multiple pageview audits to confirm if all pages are tagged properly. There's always a gap of 10-15% in the user comparison, and 20-25% in the pageview comparison.
Has anyone worked on any similar situation where GTM tracking shows lesser data than normal analytics.js tracking?

Switch from Google Analytics to Tag Manager

I have site which run on Google Analytics for some time( more than 1 year), now I want to use Google Tag Manager. If i remove Google Analytics from site, and start tracking with tag manager, there is a risk of losing data?
It's really hard to give a helpful answer to that - if you manage a seamless switch between GTM and inline GA code, and have set up everything correctly then you will not lose data. Is there a risk you make mistakes ? Probably.
I recommend to integrate GTM alongside GA and set up your GA tags so that they track to a test property. Then you can compare both properties to make sure that you track actually the same things. And that point you can throw out the inline GA code and switch to GTM (if you implement the tracking id as a variable in GTM it will be as simple as changing a single variable).
But remember to actually remove the inline code, else you will end up with double pageviews.

Switch to Tag Manager, will Enhanced Ecommerce still work?

I've successfully implemented Google Enhanced Ecommerce on one of my websites, where I also have a Google Universal Analytics tracking code. Now we want to change to Google Tag Manager, thus replacing the UA tracking code with the Tag Manager Code (correct?)
Will this affect the Enhanced Ecommerce tracking in any way? Or can I just replace the tracking snippet and the ga('create')-parts with the Tag Manager-snippet?
You need a correctly set up dataLayer (which rather more complicated since you need info on product impressions etc). Documentation is here:
https://developers.google.com/tag-manager/enhanced-ecommerce#enable
Then you create a news Analytics Tag (just a pageview or event, there is no need for a separate transaction tag) and select "Enhanced Ecommerce" with the "Use datalayer" option in the advanced settings.
GTM will pick up the values from there datalayer and do the rest for you.
So yes, you can get this to work, but it requires a lot of preparation for the correct datalayer implementation. Simply replacing the GA code with the GTM code will do very little except breaking your tracking.

Conversions in GA stopped being attributed to UTMs when we switched to Google Tag Manager

Previously, we had implemented Traditional e-commerce analytics (_gaq) using _trackTrans, _addItem, etc. We had several years of data in GA that correlated conversions with our Ad campaigns, based on UTM source, campaign, medium.
When switching over to Google Tag Manager, we did the following things:
• Removed the _gaq code related to e-commerce (transactions & addItem)
• Kept the rest of the GA code related to page tracking, events, and custom variables
• Implemented the Google Tag Manager javascript + a GTM data layer that included our new E-commerce information (Google Tag Manager data layer)
• Configured a "Tag" in GTM for "Order Completed" for Google Analytics, set to Universal Analytics (Configured with our UA- property identifier, etc.). Tag type= Universal Analytics; Tracking ID= our GA environment, Track Type = "Page View" , Enable enhanced e-commerce feature = true, Use data layer = True; Fire on "Order completed"
Upon switching over, we indeed see E-commerce numbers come through, but there's something off about the recording of these conversions correctly back to the campaigns. It appears that while some are attributed back, not all conversions are counted correctly as being from the ad campaign they originated from.
What went wrong here? After thorough reading of the GTM documentation, we were led to believe that it would "just work" but it appears that GTM and GA don't know how to communicate with each other regarding UTM information, and as a result GA tracks conversions but fails to attribute them to right session (that is, ITS session information that contains the correct UTM for that user).
We found a very scant amount of information about this on the internet-- but some people suggest setting all the UTMs are "Variables" in GTM, and then passing them as fields in the Tag firing back to GA. Is that necessary? It seems like these two technologies should work together with less friction.
Please advise.

Google Tag Manager + Google Analytics v just using GA: any reason to use just GA?

I am using Google Tag Manager on all my sites now to implement Google Analytics and future proof them for any other scripts.
I am putting GTM in my boilerplate.
Is there any reason this might not be good practice?
Any reason why a website (that needs GA) should avoid Google Tag Manager?
Most websites will require some sort of Javascript code added in the future for affiliate tracking, various analytics and having GTM installed will allow for easy installation of any such JS code easily.
Or, as Google puts it: "Why wait months for site code updates? Google Tag Manager lets you launch new tags any time with a few clicks, so you never miss a measurement or marketing opportunity."
Since GTM does not come with a service level agreement you could (very very tenuously) argue that GTM adds an additional point of failure. And if one wanted to be pedantic one could point out that not all ways of analytics tracking work with GTM (if you track serverside via the measurement protocol).
But real life argument, there is none (IMO).
There might be pages that do not greatly profit from GTM (or any other Tag Management) if all you do is to deploy a single analytics tag to track pageviews. But the second you need to track an event or pass data GTM is already worth it.
This is not meant to be merely opinion based, it's more that in 2,5 years of using GTM on large sites I have been unable to find any scenario where the tag management code has caused any technical problem or interfered with existing code. On the other hand I do not write click handlers or submit handlers anymore, I have a boilerplate template for a container tag in which I just have to replace values for a few macros before I import it to GTM and have tracking up and running, I can set data fields with much less trouble than via the code... so I think there is a real technical argument to make in favour of GTM, and none against it.

Resources