Needless to say, if you want a robust implementation, interaction and co-operation with your site’s front-end developers is an absolute must. How this data is sent with a tag to Google Analytics.Īll three of these components are necessary, and all three require some understanding of how Google Tag Manager works, how tags and triggers interact with dataLayer, and how the Enhanced Ecommerce data is sent to Google Analytics.
How the 'ecommerce' object is compiled and pushed to dataLayer (or generated with a Custom JavaScript variable). The various data types that can be sent to GA ( Actions, Impression Views, Promotion Views). Implementing Enhanced Ecommerce requires an overview of the following components:
I don’t think there’s any irrelevant information to anyone working on the project, and it makes sense to understand the full complexity of the implementation rather than focus only on the things that are directly relevant to your work. If you are the person tasked with setting up EEC via the Google Tag Manager User Interface, you’ll want to focus on the following chapters (in order):Īs I said, I still wish you’d spend the time reading the entire guide.
However, don’t neglect to consult with all the stakeholders in the project! It doesn’t make sense for a developer to write code without understanding what the code is needed for. So, depending on what your role is in the implementation project, there might be only some chapters that are relevant for you. Also, sometimes I write douchy things like that. However, I fully acquiesce that the loquaciousness of my rhetoric might be tedious to some in all its verbose glory. Obviously, it would make sense if you read the guide from top-to-bottom. Subscribe to the Simmer newsletter to get the latest news and content from Simo Ahava into your email inbox! Include all the necessary details in every hit.Google Analytics Debugger and Chrome DevTools.Product-scoped Custom Dimensions and Metrics.Combining different data types in a single EEC hit.Send the data to Google Analytics using a Custom JavaScript variable.Send the data to Google Analytics using the Data Layer.Differences (and similarities) to Standard Ecommerce.
If you want to know how Enhanced Ecommerce works or how to map your site into relevant interactions, you’ll want to look at Google’s support center documentation. Much of it is already covered in Google’s excellent Enhanced Ecommerce Developer Guide, but there are plenty of gotchas that I might have covered in earlier articles (see the Further Reading chapter), or which I might not even have written down before.
There is a lot of information in this article. Thus, even though I will be talking about DOM scraping further on in the guide, the focus here will be on a setup where the front-end produces HTML documents and/or JavaScript that populates the Ecommerce values into the dataLayer without using DOM scraping or other client-side hacks to do the job. Whenever you’re working with dataLayer, for example, you’re investing into the stability of your data collection process. However, as we have hopefully learned over the years - GTM is a tool with which fastidiousness trumps fast. You could do everything by simply scraping the Document Object Model (DOM). Theoretically, you could implement Enhanced Ecommerce through Google Tag Manager without ever adding a single line of functional logic into the codebase of your web site.