Tracking Funnels With Google Analytics Enhanced Ecommerce Tracking
Articles,  Blog

Tracking Funnels With Google Analytics Enhanced Ecommerce Tracking


– [Voiceover] In this
video, I’m going to show you how you can build your own customized funnel into Google Analytics with the help of the Enhanced Ecommerce
Tracking Functionality of Google Analytics
and Google Tag Manager, and I’ll show you how
to do all this, although you don’t have Google Analytics running on an ecommerce website. All and more coming up. So, let’s dive in. (electronic dance music) Hi there and welcome to another video of measureschool.com, where we teach you the data-driven way of digital marketing. My name is Julian, and in this video, I’m going to show you
how you can build such a funnel into Google Analytics with the help of the Enhanced Ecommerce
Tracking feature, although you don’t have Google Analytics running on an ecommerce website. So, most people think of visualizations of a funnel as the goal
funnela that you can define in your Google Analytics
and see how many people gone through each step. I don’t have one set up
right here, but normally, you could define them
within your goal settings, and define each funnel step that you want to register in your Google Analytics and see it in this Funnel
Visualization Report. Unfortunately, funnels
only work with page views. So, you would need to have
very distinct pages to lead your user through, and at the same time, they’re not very flexible when it comes to the analysis of these funnels. So, for example, you
can’t really segment them to draw further insights
out of the different users that go through this tunnel, but not long ago, Google
Analytics introduced the enhanced functionality
of the Ecommerce Tracking that gives you a lot of
different reports that are new to Google Analytics
if you are running an ecommerce website. Now, really what this does is just put some labels on very specific
ecommerce functionality, such as product and to
check out or purchases. So, we want to bend the rules a little bit and build such a funnel visualization for our purposes as well, even though we don’t run an ecommerce website, and have the benefit of seeing how many people went through this funnel but also being able to build a segment
of the people who dropped out and being able to use our custom segments in this view as well. In order to show you
all this, I’ve made up a little example. So, we have here an offer page, which will be our first page that the user will see, and this represents our first funnel step. Then the second funnel
step would be the click of this button, and the third funnel step would be the fill out of this form and also submitting this form. So, we’ll get a accurate representation of how many people have viewed an offer how many click that
button and how many people submitted our form. So, let’s set this up with the
help of Google Tag Manager. In our Google Tag Manager
account, we have a normal pageview tag, and now
we want to first of all send these interactions
over to Google Analytics. So, the first thing that we wanna track is has somebody viewed this offer, and we will do this all
through Event Tracking. So, let’s send over an Event
when somebody viewed this page. Let’s go into Google Tag
Manager, build a new tag, which will represent our
GA tag for our Enhanced Ecommerce Tracking
Funnel, and this will be the Step Number One, which
will fire on the offer viewed. We’ll choose Google Analytics,
choose Universal Analytics, and we already have our tracking ID saved in a variable, which
is Google Analytics ID. Now we can go as a
check tab, choose Event, and we can freely choose
our Category Action Label. In our case, I will send
in Enhanced Ecommerce Tracking Funnel Events. This will be our Step Number
One, which will happen on the page view of the offer. Now, I will set this Non
Interaction hit to True because it will fire upon our page view, and we don’t want it to
affect our bounce rate. So, let’s set this to True,
and click on Continue. As the trigger, we will
simply make up a new trigger, which will be our Offer Viewed, which will fire on the
Page View and only on some page views, where the page path equals offer. Let’s create this trigger, create this tag, and try this all out. Let’s go into our preview
in (mumbles) mode, go to our page, reload our page, and we see upon our
page view that our offer event has fired and we should also be able to see that in our real
time reporting under Events, and be sure to click the
Events Last 30 Minutes, which will show all the
events that have come in. We have here our EE
Funnel Step Number One. So, this works as expected. Now the next step that we
wanna track is actually to click on this button. I have already prepared
a trigger for this. Now, if you wanna know how
I prepared this trigger, then go back to our button,
click Tracking Video. That will explain how to set this up. We’ll just proceed and connect
this trigger to our tag, which will be a modified
tag of our first tag here. We’ll copy this and set
this up to number two, which will be our Button Clicked, and that change our Event Values around. This will be Step Number
Two, and this will be the Apply Now button. In Non Interaction, hit
can now be set to False, because this is actually a hit that would affect the bounce rate,
and we can go with continue and choose the right
trigger, which we already have prepared as the Apply Now button. Let’s create this, try out this step as well. We have a problem here. The variable click ID is not defined, should have caused me
to always enable before we build our event triggers. So, we’ll do this and I’ll
also do this for the form. Now we should be able to refresh. Yes, and let’s go back, reload our page, and I click on this Apply
button with the command key pressed so it opens up in a new tab. We see our fifth event
is the gtm.linkClick which fired our funnel step number two, and we should also be able to see that in our Active User Event Report
of the real time reporting. Here we go. Step Number Two successfully fired. Now, all we need to do
is track the third step, which is this form submission, and again, I have a trigger already prepared for this in our Google Tag Manager account. If you want to know how to set this up, please follow Event Tracking video. All we need to do now is go into our tags and connect it up to a tag. So, let’s copy one of these events again, rename them and change the action step to number three. So happen under Form Submit, and create this tag. Whoops, I forgot to
change the actual trigger, which we still needed to do. So, let’s try that. That should do it. Refresh, now we’ll go back
to our Contact Us page and fill out the form with some test data and click the Send button, and I will click the Escape key right afterwards so our browser doesn’t forward us on. Here we go. We have our 5th form submit with our Funnel Step Number three that gets in over to Google Analytics. Let’s check that out. You see here our third funnel
step that was registered. So, now we have all the
interaction at least gathered within Google Analytics and we could already figure out a funnel with all the data that we
have in the event report now, but what would be the step to actually go from the raw event data to a checkout behavior report that we could actually use. Well first of all, we need to prepare our Google Analytics account. So, in the Admin section, you can go to your Ecommerce settings and although you don’t have an ecommerce
site like we have there, you can go ahead and
build your funnel steps. All you need to do is
Enable Ecommerce Tracking, Enable Enhanced Ecommerce Tracking and then add your funnel
steps right there. These are just labels. So, you can name them whatever you want. Just be sure that they
are in the right sequence so the first one would be
your first funnel step, in our case Offer. The second one would be Apply Now, and funnel step, you
wouldn’t enter because this is a special
transaction that would be sent over to Google Analytics. So, you don’t need to define the last or the final or the goal funnel step but only the real steps that lead up to the actual conversion. Once you have done that,
you can submit everything, and prepare your Google
Tag Manager account to send in the right data. All we need to do is install enhanced ecommerce tracking variables, and we would need to model the ecommerce object as it is explained
in the Developer resources of Enhanced Ecommerce
Tracking Specifications. So, for example, we have here data layer that pushes an ecommerce
object into the data layer, which then can be picked
up by Google Tag Manager and forwarded on to Google Analytics. Now, there’s a lot of data
in here that is unnecessary for our purposes. Really, all we need is
the ecommerce product, and we need to tell Google Analytics that this is our first funnel step. So, I’ve prepared actually
these three variables that you would need or
four or five variables that you would need already
in a tag template for you, which you can download under measureschool.com/eefunneltracking. Once you have downloaded the file, all you need to do is go
into the Admin section and import the Container. We’ll choose our Container
File, which is our EEfunnel Tracking-dot-
Jason, and we can merge that in with our existing Container. Let’s continue this. This will generate four
new variables here. Let’s confirm this and you can take a look what has been added. It’s three funnel steps here. You could have three or four or five. The first one would just
return our ecommerce product with the action field step one. The second one is the
same, just with step two, and the third one is a
special ecommerce data layer that signalizes the
purchase or the conversion to the Enhanced Ecommerce
Tracking Feature. So, what we necessarily need
is an ID for this purchase. So, I’ve just used the built-in
variable, Random Number to generate an ID for this conversion. So, once you have that all set up, you just need to build in these variables to the correct tags. So we will go into our tags and for the first funnel step here, we’ll choose the Enhanced settings. Let’s go under More
Settings, and we have here Ecommerce Features, and we can Enable Ecommerce Features, and we will not use the Data Layer but read the data from a variable, which is our EE Funnel Step Number One. Let’s save this. Alright second step, do the
same for our second step, and this time choose our
second step variable. Same for the third step, where we choose our special purchase variable. So, let’s refresh this
and try this all out. Let’s go back to our offer
page and reload this. Now our event gets sent over. Unfortunately, we won’t
be able to see that in our real-time reporting. We will also not be able to see it in our Tag Assistant but have another plug-in here called the GA Debugger, which will show us the
data that has been sent over in the Developer Tools. So, let’s open them up. Go into our JavaScript console, and we see all the data that gets sent into Google Analytics,
and the first step here, we would send it over page view because we viewed that page. The second one would be our event. So, we have here our event actions, but they are specially decorated with an enhanced ecommerce tracking action and ecommerce step number one. So, this data has been
sent over correctly. What happens when we click
the Apply Now button? I do this with the Command key pressed. We get more data that has been sent in. This time, our e-c-action is to check out and our e-c-step is number
two, and then again, when we go ahead on our Contact Us page, fill that out with some demo data. I’ll open up the Developer
Tools to JavaScript Console, so we see what happens. We have here our page view, and let’s see once we click the Send button if something gets sent over, and here we go. We see our third funnel
step being sent over with the action this time purchase and the ID which is a
randomly generated number. So, if everything is sent in correctly, you will be able to check your Enhanced Ecommerce Tracking Reports, which are under Conversions, Ecommerce. Then you have Shopping
Analysis and Checkout Behavior, which will feature your three steps that the user needs to take in order to get to the last step,
which is our conversion. Now, all the other reports
won’t be filled correctly. At this point, we have
bent Google Analytics to our will of making it work with our non-ecommerce website. I think this is a great
proof of concept how you can take the great functionality
that is now built in to Google Analytics
with the Enhanced Ecommerce Tracking Report and really
customize it to your needs, although you are not
running this specifically on an ecommerce website,
and with this report, you can segment your funnel. You could also build a segment from people who don’t reach the last step, which can be super actionable, because you can actually choose to remarket to these people through AdWords as well. So, I hope you found this video useful. Remember that you can
download our tag template at measureschool.com/eefunneltracking to install (mumbles). (electronic dance music) And that’s (mumbles)
with this week’s video of measureschool.com. If you wanna download the Tag Template that we have prepared for you to recreate this whole funnel tracking
without having to go through all the steps, you will be able to download a template at measureschool.com/eefunneltracking and if you have any
questions, please leave them in the comments below and we’ll try to answer them as soon as possible. My name is Julian. Till next time. (electronic dance music)

40 Comments

  • ianman6

    Very helpful! But how do I find out what the variable name for the ID should be if I'm tracking an actual transaction? Say, for a Magento store? I would put 'ID': TRANSACTIONID, but how do I find the correct variable name for what goes in the place of TRANSACTIONID?

  • Francesco Ragusa

    Hi Julian, alway thanks for your great work. Soon I'm going to become your student in MeasureSchool!!
    I've a question. How can I track, like Step 1, "add to cart" event using Woocommerce?

  • Andrew Cummins

    Hey Julian,

    Great video! I'm using woocommerce, if I want to do the same but track the purchase funnel e.g. from adding to cart to order complete, would I follow a similar process? Would be awesome if you could do a similar video for ecommerce 🙂 Have found many of your videos very useful, keep up the good work!

  • Emile Pukander

    Do you see any cons in tracking the button clicks instead of the different pages in the funnel? Let's say you're using a validation in your form (the user has for example forgotten to type in a required field) and if he clicks the button it will fire the next step when the case is that the customer is till on the same page?

  • Stefan

    it will be really interesting of doing all the data defining stuff which you referred in your download-file. i think this is the most confusing part of all

  • Martin Hamilton

    How would I track which customers completed these steps? If they opt into my email list before entering the funnel is there any way to do this? Otherwise I should set all this up within my autoresponder series right?

  • BJ Lee

    If you have different campaigns or funnels, how do you track them all separately? Or how do you segment? Is thise in the Label for "Event Tracking Parameters" in the tag?

  • Real Estate

    Hi, great videos! im trying to create a custom conversion event on facebook base on the click botton on my landing page i set up google tag following your video but im missing how to connect that event to facebook so i can fire the facebook custom conversion picel when customers click on the botton lp in my site.
    Any input will be greatly appreciated!

    Keep rocking with your videos very helpfull 🙂

  • LegionXV

    Avoid to set the confirmation page as part of the checkout funnel saved my life. Analytics refused to collect data until I removed it! Not sure If Google documentation says something about it.. It's definitely NOT EASY to troubleshot errors using the enhanced e-commerce reports + GTM + dataLayer. Plus the recorded results are not in-realtime, so you can't be sure about why data doesn't display eventually – datalayer error? GTM error? Google servers slow? – What do you think about it Julian?

  • moowtjekw

    If you have more "offer" or product pages, all with different URLs, how can I tag those pages? All those pages have the button "book now".

  • Khrystyna Grynko

    hi Julian, thank you very much for your videos.

    When i set "non-interaction hit " to True i have no events in my real-time reports… is it ok ?

    Thank you

  • Ali Raza HDM

    Very Informative video,
    Dear i need some information. How to create Apply Now Button Trigger. Please if you have posted video already on this please share link in comments.

  • Daniel C

    Hello Julian. If I need two funnels on my website, how can I do this. In both cases I need the enhance ecommerce functionalities

  • Bryan Garabrandt

    Hello Julian. Am I correct to assume that in order for the funnel steps to work properly, the data layer for Measuring Checkout Steps has to be on each page of the checkout process with the correct step number in the actionField?

  • Vladimir Cuk

    Hi Julian! Is it possible to make two separate funnel in Ecommercee / Checkout behavior in GA? I added separate event in dataLayer for two separate funnel process, but I see only one.

  • Mark Mottershead

    Hi Julian – Is it possible to create multiple funnels using this methodology given that I am testing out multiple paths to the sale?

  • Erik Blatter

    Hi Julian. Two questions:

    1. Why do you choose the Track Type "Event" for the Step 1 Tag? Wouldn't it work, if you choose Page View as Track Type?

    2. Is it possible to trigger a tag only once in a session? I have configured the funnel for a Onlinestore where the user will enter the store basket several times during his session. In detail: From the store basket he gets to the login page and after the login he gets back to the store basket agin. Yet that fires the Tag for the Step "Store Basket" two times. Any idea how to fix that?

  • Sumesh Karancherry

    i have multiple products in my ecommerce site for example under the products page i have product 1, Product2 , product 3…etc, if a user clicks on any one of the products and then add to cart on the product page. how can tis be tracked

  • Arthur Bonavita

    Hello Julian,
    congrats for your videos !
    I need to track a one step checkout page, do you have some idea of how can i do it ?
    I'm having some troubles because all the steps are on the same url page… i'm kind of lost to figure out how to do it.
    Do you have some tip or advice ? Or anyone else who is reading this comment!?

    Thank you !!!

    Arthur ;D

  • Malak Lopez

    Hi Julian, you’re a life saver! Quick question, do I need to take these steps to create a funnel if I already have advanced eCommerce setup successfully in my eCommerce site? I’m thinking yes, since the checkout and shopping funnels show up after I toggle advanced eCommerce on, but don’t have data being sent to them whenever a step is completed. If this is not true and adv eCommerce tracking Auto tracks checkout and shopping funnels, will firing those tags and adding the json step data to the data layer interfere with what google is tracking? Thanks for your help!

  • Samantha Chan

    Thanks for the video! Everything works great for me on desktop but I can't figure out why it's not tracking the same on mobile. For mobile, events fire and show on GA but it's not showing under EE. Any idea why?

  • Leo Nobu

    Hey Jason, I'm receiving the following issue in the Variable Unknown variable 'Random Number' found in another variable. Edit the variable and remove the reference to the unknown variable

  • juan david calle duque

    Hi Jason, first, thank you for the information, I did what you did in this video but the shopping and checkout behavior report, did not show anything, could you be so kind of explain what is missing?

  • Thomas Quigley

    Hi Julian! Thank you for the videos they are great! I am still having difficulty setting up the product views and shopping behaviour in my analytics account. I want to eventually segment my products by catalogue. Do you have a video that might help?

  • Ivan Spajic

    Hm. Is there a way to do step 4 without pushing the random number ID? It's creating problems for the woocommerce reporting because it's overwriting their ID. On the other hand, my trigger is a simple pageview on the Thank you page.

  • Jan Badertscher

    Hi Julian. Great Video!
    Any reason you use JS Variables to execute the Ecom datalayer pushes, instead of custom HTML tags with triggers for a particular step?
    In my opinion, having 3 JS variables for each step, the code of each variable will always run, on any page, which is a big overhead for clients. I would rather create 3 HTML tags with the Ecom codes, then define triggers to make them run only on the particular step, and read the Ecom variables that we push into the DL with regular variables…
    Is there an advantage in the way you're doing it that I'm missing or failing to undestand?
    Best,
    Jan

  • Kunkyu Lee

    Thank you for your youtube. However, I have one problem. I followed your direction, but GTM doesn't seem to catch traffics of mobile web (m.domain.com), just desk-top events. How do I catch events in mobile web.

  • navid mosleminiya

    Hi Julian, thanks for your video – There is one problem and it seems google have changed the ui of the GTM and I can not assign the java variables to the tags cause there is no "more settings" in the new versions how can I further continue the process?

Leave a Reply

Your email address will not be published. Required fields are marked *