Our website uses cookies.

Our website uses cookies to improve your user experience. If you continue browsing, we assume that you consent to our use of cookies. More information can be found in our Privacy Policy.

Online Tracking & Goals Using Google Tag Manager

18 Sep, 2019 Scott Ostermiller Digital

It’s not all smoke and mirrors.

 

One of the things I love most about digital marketing is the ability to track nearly everything a consumer does. At the same time, however, the fact that so much of your life and online activity is trackable may feel a little bit creepy. 

 

As a digital marketer, though, conversion tracking on any site is one of the most powerful tools in my arsenal in order to better target my customers and eliminate individuals who don’t fit in my target audience. 

 

One of the most common methods of tracking conversions through Google Analytics is by reaching a destination page, i.e. a “Thank You” page, order confirmation page or other. But with the advent of single-page apps (SPAs), the end goal of a page doesn’t always have a unique URL where you can easily tell Analytics that your goal has been achieved.

 

Enter Google Tag Manager. 

 

Possibly the greatest tool in a marketer’s toolbox for tracking on-site conversions without involving a web developer is Google Tag Manager (GTM). This is especially applicable in an agency setting like Fluid where even though we have our own in-house development team, we are constantly working with clients’ existing websites and have to install scripts and codes to be successful. It saves a TON of time and effort without having to go back and forth with emails, phone calls, etc. in order to get tracking implemented.

 

Tag Manager uses a series of triggers and tags to track specific elements on a page that are usually listed in the data layer in order to send data to Google Analytics that are useful in tracking conversions or other activity. Tag Manager can also fire tags associated with non-Google resources like Facebook, Twitter, LinkedIn, CrazyEgg and many others. 

 

Tags:

 

A tag is simply a miniature program (sometimes called a pixel) that connects to a compatible platform like those listed above and relays to your platform’s server to deliver whatever information you’re looking to track in order to help you better understand how visitors are using your website. Some of these tags are preprogrammed into GTM but may consist of HTML and/or javascript. 

 

Triggers:

 

No, we’re not talking about the ever-present idea of a “trigger” that elicits an emotional response from someone. However, it’s not that far off. A trigger is based on a page view, a click, an on-page element being visible, a form submission, a YouTube video interaction, a timer (they’ve been on the site X seconds), reaching a specific scroll depth or some other custom event that is programmed into the site. 

 

Every tag must have a trigger associated with it. Most basic tags just use a page view, though you can pick a specific page view if you want. In the screenshot below, you can see that I have the option of using “All Page Views” or “Some Page Views” where I can specify the circumstances of the page that I want to count. In this case, I decided I only wanted to count page views where the page path contains “/conversion-page-path”. By doing that, my tag will fire when someone visits the page “www.example.com/conversion-page-path” but not on “www.example.com/conversion”. 

 

Tracking in Google Analytics:

 

Let’s say you want to track conversions in Analytics that aren’t based on a destination page. You can have your web developer program events that occur when a specific action is achieved by installing a small snippet of javascript code. But what if you don’t want to worry about involving a developer?

 

An event in Google Analytics can bring through four pieces of data along with it: the event category, action, label and value. When you work with GTM, you can make these anything you want with the exception of value, which must be a numeric (usually monetary) value.  

 

The event category should be higher in your event hierarchy so you have multiple actions available under it. What categories you choose to use in Analytics will depend on the type of website you’re running. If you’re running a lead-generation site, you may choose to have a category of “Lead” and a variety of actions such as “Form Submission”, “Newsletter Subscription”, “Phone Call” or “Chat”. Then the label you choose may depend on where the lead occurred. However, to save you time, you don’t have to program an event for every time someone submits a form on every page. You can use a variable for that instead. 

 

For example, if you want to track phone calls without using a third-party tracker like CallRail, Call Tracking Metrics, etc., you can program a tag to be fired whenever someone clicks on a link whose HTML contains “href=tel:”. 

 

Here’s what that tag might look like:

But let’s say that I want to know the page where that phone call occurred. When I set up the Google Analytics event tag, I may set it up to look like this:

By doing this, I’ll get the event to come through with the category of “Lead” and action of “Phone Call” but the page path will come through as the label (remember the page path is simply the full URL without the domain name). 

 

You can do a very similar thing to track a button click on a specific page and create a unique goal for it. Or, if you have the same button on multiple pages you can make a Google Analytics tag that will trigger on any button click that matches your description and have it bring the page name/path through as your conversion label. The trigger for your button might look something like this:

Summary:

 

Nearly everything is trackable online. You just have to be creative enough to come up with a way to do it. Every website we build here at Fluid comes with full Google Analytics integration and tracking. However, if you’re working with a website that doesn’t make total sense from a coding standpoint, we can work with that, too.

Also check out...

17 Nov, 2018 Kayla LeFevre Fluid Culture

Getting Personal with Our Newest Fluidite

9 Oct, 2019 Alec Jackson Fluid Culture

5 Books That Have Changed My Life

6 Aug, 2019 Kayla LeFevre Creativity

A Strong Case Against Jargon

Want to hit a button?

It's just a harmless contact page.