Upcoming LunaMetrics Seminars
Boston, Apr 6-10 Los Angeles, Apr 13-16 Atlanta, Apr 27-30 Washington DC, May 11-15

Archive for the ‘Google Tag Manager’ Category

Using Google Tag Manager for Visitors Without JavaScript

gtm-noscript-blog

Sometimes, it can be useful to track browsers that do not execute JavaScript, whether we’re tracking hits, email click throughs, or other image tags. This can help your organization gauge how many users cannot make use of JavaScript-powered features, determine if things like headless browser-based bots are frequently scraping your site, and understand more about the differences in what Google Analytics records versus what your server logs might show.

Fortunately, Google Tag Manager has some fantastic built-in features to make doing this a snap, and you may not even realize that it’s already implemented on your site! (more…)

Defining Audiences with Google Analytics Custom Dimensions

Defining Audiences with Google Analytics Custom Dimensions

In 2012, Sayf introduced you to 20 useful ways to use custom variables. He provided five custom variables for each of the four main website types: Content Sites, Ecommerce Sites, Lead Generation Sites, and Self Service Sites.

These are all still applicable today, even though we refer to these custom data definitions as custom dimensions and metrics in Universal Analytics instead of custom variables.

Rather than provide you with 20 more ideas for custom data – my goal is to instead inspire you to take another perspective on custom dimensions. Whether you are redesigning your website, deciding on content for a landing page, or creating advertisements for digital or traditional media, it truly pays off to know exactly who your target audiences are. (more…)

Tracking Page Prints with Google Tag Manager

blog-print-gtm

Do you have pages on your site that users may try to print? For example, retail companies with brick-and-morter stores may be interested in knowing if users are printing out product details, coupons, or directions pages. Or publishers may want to know if users are printing their articles.

This can all be tracked with event tracking in Google Analytics. It requires some code (provided below) which is easy to implement in Google Tag Manager in about 10 minutes. Seriously.

(more…)

Extending the Functionality of Google Tag Manager Variables

blog-gtm-variable2

When you create a Custom JavaScript Variable, Google Tag Manager forces you to use an interesting pattern:


    function() {
      return ... // return something
    }
  

In your Variable, you can add whatever JavaScript you wish, but you must return something. Typically this is a string or number, or sometimes an array or object.

However, Custom JS Variables can return anything, even functions, and you can pass arguments into those functions to get different results. (more…)

Making Google Tag Manager Work Together with On-Page Tracking

blog-onpage-tracking

Transitioning to Google Tag Manager, but still have a lot of hard-coded tracking on your website? Many of our clients find themselves in this very situation.

Or you may have the opposite problem, where you’ve been tracking pageviews through code on your site, and now you want to add PDF tracking through GTM.

With the robust and customizable applications of GTM, it is clear why so many companies make the switch; but if your website already contains a large amount of hard-coded tracking, such as event tracking or custom dimensions/variables, recreating those new tags in GTM might take some time – leaving your website in a limbo of utilizing both GTM and on-page scripts.

This is okay, and for many, a necessary step in the process of completely transitioning to GTM. It is crucial, however, to understand the impact and functionality of GTM tracker names in order to continue to receive quality data during this period. (more…)

LunaMetrics Top 10 Blog Posts from 2014

blog-top-ten-blogs

A new year brings new opportunities, new chances for self-improvement, and inevitably, reflection on the previous year. I’ve pulled out some of our most trafficked and most popular blog posts from the past year and listed them below.

It’s no coincidence that the categories of the posts are reflective of LunaMetrics as a company. There are entries from our main focuses on Google Analytics, Google Tag Manager, and the broad world of Search.

There are simple explanations of complicated topics, new ideas to ponder, and ways to make your life easier. As 2015 gets underway, you can expect more great content from our expert LunaMetricians. (more…)

Where Should The Google Tag Manager Snippet Be Placed?

blog-gtm-snippet

Perhaps this sounds familiar: Your team has just decided to start transitioning to Google Tag Manager. However, you’re stuck on where you need to place the container code.

Traditionally, you’ve placed the Google Analytics immediately before the closing head tag, or perhaps it’s even still in the footer. (gasp!)

With Google Tag Manager the placement is now a little different. Instead of placing it in the head section, Google recommends putting the container code immediately after the opening body tag. (more…)

Extracting Schema & Metadata With Google Tag Manager

gtm-schema

If you’re evaluating the performance of your site content, it can help tremendously to segment that content into a variety of cohorts. Unfortunately, many website owners have trouble getting enough information about their content into Google Analytics to help them with their analysis.

Some information may already be available on your website, like information about your page or extra information that gives context to the page.

Ultimately we want to bring these additional dimensions about your content into Google Analytics to help with your analysis. One way to do this is by leveraging Schema and Google Tag Manager.

What’s Schema

If you’re still unaware of Schema, it’s a way of marking up your content so that it is recognized by Google and other search providers. This helps search engines to better understand your content, and hopefully deliver it in a more relevant way to people searching on their systems.

Ultimately, it’s about driving more organic visitors to your website. (more…)

Form Engagement Tracking with Google Tag Manager

blog-form-engagement

Do you know how people are completing forms on your site? Are there certain fields that get skipped frequently or that cause users to drop off?

Almost two years ago, I wrote a post showing how to use a simple script to track form abandonment in Google Analytics with event tracking. I’ve gotten a lot of great user feedback (and requests) about that script, and wanted to share an updated version that is a little more elegant.

This new version more effectively handles fields that are completed or skipped. I’ve also modified this script and included instructions for how to add it to your site through Google Tag Manager.

Use this script to see which fields get the most completions, but also use it to compare to the amount of forms that get submitted successfully. If you find that people are starting to complete the form but failing to submit it, you may need to look into ways to improve the user experience.
(more…)

Using Visual Website Optimizer with Google Tag Manager

blog-vwo-gtm

Recently, I was working with a client to integrate Visual Website Optimizer (VWO) with Google Tag Manager. I started by following the integration guide on VWO’s support pages, but ran into a few issues that required a creative workaround.

Not only did the timing of the VWO loading present issues, but I found that the specific data that is supposed to made available on the dataLayer wasn’t being made available.

Follow the instructions below to fix both of the problems! (more…)