Conversion Tracking Installation with GTM Lesson 5 (GTM for Beginners)

After installing GTM correctly and migrated our existing tracking with the help of our tag plan, it is now time to track our conversions.

In this 5th lesson of our GTM for beginners series, let’s learn how we can measure the success of our site by installing conversion tracking. This is a step by step guide on the proper installation and configuration of the Facebook Conversion Pixel and Google Ads pixel.

đź”— Links:

Take the Quiz:

Introduction To Google Tag Manager 2019 | Lesson 1 (GTM for Beginners)

How to Install Google Tag Manager (2019) | Lesson 2 (GTM for Beginners)

Analytics Audit and Tag Planning | Lesson 3 (GTM for Beginners)

Google Analytics Tracking Migration with GTM | Lesson 4 (GTM for Beginners)

🎓 Learn more from Measureschool:

🔀 GTM Copy Paste

🚀Looking to kick-start your data journey? Hire us:

đź“š Recommended Measure Books:

đź“· Gear we used to produce this video:


In this fifth lesson of our GTM for beginner series, we’re going to find out how we can install conversion tracking with the help of Google Tag Manager. All and more, coming up.

Hello there and welcome back to another video of teaching you the data-driven way of digital marketing. My name is Julian, and we are on our fifth lesson of our GTM for beginner series. Now in the last lessons, we have already installed Google Tag Manager, plan out our migration and then migrated all our existing tracking over to Google Tag Manager. So we now have data flowing into our account. And this is already great data because we know where the user is coming from and what he’s doing on our website. The crucial part that is actually still missing is did the user take the action that we want him to take and this is commonly referred to as conversion tracking. This is very important data that we need to forward on to our paid traffic sources, for example, Google Ads or Facebook Ads because we want these tools to know if the user, the user that they sent us actually converted. And that way we can find out how effective were our ads so did the traffic that these platforms actually sent us turned into paying customers, for example. Now, in order to do conversion tracking, you actually need to install a tracking code on a specific website, or when the user actually does the conversion action. And with Google Tag Manager, we can do this pretty easily. But before we learn all about this, if you want to test your knowledge right after this video, then head over to we have a little bit of a quiz prepared for you. So pay close attention because we got lots to cover so let’s dive in.

In this, as we want to install conversion tracking on this demo shop. But first of all, what our conversions? They are simply how we define success on our website. What is the interaction we want our users to take? So in order to install conversion tracking, we need to pick one interaction that we would define as conversion. For an e-commerce shop, this is pretty easy because we want the user to actually buy products. So let’s see what a conversion would look like. Let’s conduct a test conversion. I’m going to put something into my cart and simply go through the checkout process.

And once I place the order, I have taken the action that we want our users to take. And I get to this page, the auto received page or the thank you page, which only people can get to that actually went through the checkout and purchase the product. So this is the action that we want our users to take. How would we measure this? The interaction that we can easily measure is a page load or a page view. And the page view can take as a measurement is if the user has actually reached this thank you page.

This is interaction we can pick up with Google Tag Manager and then send it on to our tools. Conversion Tracking works differently in different tools. So for example, for Facebook, we need to install a certain pixel. For Google ads, we would need to define a conversion here under our conversion report. And in Google Analytics, it’s actually a little bit more diverse. You can configure a destination goal, an event code or e-commerce tracking, which is specialized for eCommerce shops. But this is a bit more complicated and we have some tutorials on this channel if you want to set us up for your store. We won’t be doing this in this lesson. Let’s concentrate on Facebook and Google Ads for now. So for Facebook Ads, we can go up to the pixel setup here and we have done this in our previous lesson. I’m going to install a facebook pixel manually which will give us some HTML code we have installed this last time. Then on the next section here we can actually install and track events.

And these are specialized interactions that we can send over. One of these interactions is the purchase event. And if you read closely through the documentation here you will get all the information that we need in order to send this over. I’m not going to send over any kind of event parameters for now just to keep it simple. And we’re just going to send over the signal that a purchase has happened on our store. What we will need to do is deploy this kind of code on our page. Before we get started let’s document this in our tag plan here so we’re going to deploy a Facebook conversion pixel.

Description is purchase event and as the notes, I’m going to put in the page that we actually are deploying this on which is the page right here.And then we can also put in a new tick box once we activate this. With that information present, let’s go ahead and install this in Google Tag Manager. Now in Google Tag Manager itself, if we look at our already deployed tags, we see that they all are firing on the all pages trigger, which is a built-in trigger that deploys our tracking codes on every page where Google Tag Manager is installed. Now obviously you don’t want to deploy this conversion action on every page. We want to deploy it only on this order receipt page because then the user has taken the action that we wanted him to take. So let’s first work on our trigger and we’re going to build a special trigger for this that only fires on our thank you page. Let’s go over to triggers and then new and under the trigger configuration, we can choose when our trigger or rule should be evaluated. So every time the page view happens, every time a click happens, and many other events that we are good to in later lessons. For now, we already said that when the user lands on the page when the page actually loads, we want to evaluate whether the users actually on the thank you page. And that’s why we’re going to choose the page view trigger type. And this will determine when the trigger is actually evaluated. So here’s the page view event. But we want to not deploy this on all page views but only on some. And this will give us the chance to further restrict or define our trigger to only fire on certain circumstances. So underneath here, we have some rules that we can define. First of all, we will need to choose a variable and right here we have the page hostname, page path, page URL, referral present in order for us to evaluate against. You don’t need to understand everything about them. But right now the page URL is when we want to determine if the user is actually on this page. So we can build a rule that if the page URL contains and there are other matching options, some go more detail, and you can get more specialized with it. But contains will do for now. If the URL contains, let’s look at the URL, checkout/order received, for example, if that’s the case, then I want to deploy my tag.

Now, why didn’t I use, for example, the equals option or another option right here or copy this whole URL? Well, there are some dynamic values in this URL. So for example, this changes every time we have a new order, this is the order number that actually comes up. So we would need to possibly go through more test conversions in order to find this out. But check out received or order received is a pretty unique part of the URL. And the user would actually not be able to get here through a random link on the website. He would need to go to the checkout and convert in order for him to get to this order, receive page. So it’s pretty unique and this is what we going to use for our trigger. Let’s give this all a name this fires on the page view event. And once we get to our purchase section. Let’s save this.

And we have now defined our trigger when we want to deploy our tag. Now we get to the actual tracking code that we want to deploy. And we go over to the text on the facebook pixel. We have seen this little tracking code right here. It actually works in combination with the tracking code that we have deployed last time. So right here we have our Facebook tracking code. And only if this upper part is deployed, we will be able to deploy our code right here. Since we always do this on all the pages is the old pages trigger, we can say that we wouldn’t need to repeat ourselves in the next tag. But what we want to make sure is that this fires actually before our tag fires. There are different methods of doing this and an easy way is to use a tag priority option which would give priority to this tag, the higher the number is. So if you put in 100 here, for example, then this tag would fire earlier than all the other tags that have a lower priority. So I’m going to implement this for our tag and update this. Let’s save this. And now build our new tag, which doesn’t have a tag template available. So there is no tag template right here. But we can utilize custom HTML tag where we can enter our little code that we have copied here.

Whoops. So here we go. We don’t have to put a tag priority this time into this field as it’s when it’s empty, lower than the other tag priorities that have a number in them. So this will fire after our initial Facebook ads code and we can now attach simply a trigger which is our page view purchase trigger. Now let’s give this all a name and save this. And now we can try it out by going into the preview mode. And once we are in it, we can go back to our page, reload that, and right now we are on the thank you page. So it’s expected for our code to fire.

So here we have our debug console and we see our Facebook Ads event, the purchase event fired just fine on this thank you page. Obviously, you should do multiple checks. Let’s do a little bit of Q&A and go into our facebook pixel helper. We see our purchase event fired right here. And in Facebook itself, it’s always important that your data is actually received. So when we go back to our facebook pixel right here, we can actually go to test events and this will put Facebook into this listening mode. And if we go back to our page and just reload this, our Facebook ads purchase event will fire again. And we see here that we now have a new purchase code that was sent over just now. So this seems to work just fine and our conversions are now tracked and properly installed with the Facebook Ads. The heavy lifting , in this case,is simply to build the right trigger in order to fire this on the thank you page. And since we have done this now and we have this trigger available, we can actually reuse it. That’s a big advantage of Google Tag Manager to stay flexible and deploy also our Google Ads conversion tracking. And we have another video on this but it basically works the same, you have a purchase pixel once we have configured everything you’ll be able to get the configuration data right here and be able to implement it into your Google Tag Manager account. I’m just gonna for completion sake also make this available in our tag plan with this configuration, and let’s also put this on to a new checkbox. And now we going to use this data to simply build our new tag. This time, Google obviously has a template available. Here’s a Google Ads conversion tracking template where we simply need to put our conversion ID in. That’s something we have saved here and our conversion label. The other fields we can live on touch for now. And we simply reuse our trigger that we have built before for our purchase tracking. Let’s gives this all a name.

And try this out by refreshing our preview and debug mode, and refreshing our page. And again, we can now see that our Google Ads conversion purchase pixel has also fired on this thank you page. Obviously, we should also look into our other tools. We have the tag assistant here that shows us that Google Ads tracking works. And you should also be able to see incoming data in your Google Ads account,. Although you wouldn’t need to go through an actual Google ad in order for it to show up in the conversions right here.

So I won’t to this for now but it shows the case that we can really utilize our firing trigger over and over again, if we had a new tool that we want to connect to this conversion. Now, as always, if you have tested this thoroughly, our conversion tags are firing correctly on this page. If you go to another page they actually, hopefully not firing. Yes, that’s the case. So these are not firing because the conditions of our trigger, which we can see by choosing event, and clicking on them right here, we see that our page URL does not contain other received. And therefore this whole trigger failed. And our tag is not deployed which we want. Only if you go through the checkout and get to the order receipt page, our conversion tracking fires correctly. So once you’re sure and done your Q&A, we are ready to deploy our tracking. Let’s click on the submit button and give this all a name.

And then we are ready to publish a new version to all our users. And it’s now deployed on our website. So this is how you can deploy conversion tracking with the help of Google Tag Manager.

All right, so there you have it. This is how you can do conversion tracking with the help of Google Tag Manager and forward this on to your paid traffic sources, but also Google Analytics if you wanted to. We have more tutorials on this channel where you can find out how to send different conversion data to different tools, but also how to install conversion tracking if your case is not an online shop, like we have it right here. But as always, if you want to test your knowledge right after this video, then head over to where we have a little bit of a quiz prepared for you to see if you understood everything or if you have any knowledge gaps and need to recap or go back in this video to understand it. And if you want to follow along with the next lesson, then be sure to subscribe to our channel right over there. Because we’re bringing new videos just like this one. We have maybe the next tutorial already linked up up there so you know where to go afterwards. Now as always, my name is Julian. Till next time


Leave a Comment