Google Analytics

Url Tagging and Tracking Campaigns in Google Analytics

Back to Basics

It’s almost Christmas. “The most wonderful time of the year…” and maybe the most stressful as a marketer or ecommerce store! For many companies, this is the hot season, and your marketing department has a ton of creative marketing campaigns, both online and offline. Come New Years, your CEO wants a clear understanding of how the seasonal sales and marketing went and what initiatives made the most money. With all the chaos, this can seem overwhelming, but with powerful tools like Google Analytics and a little bit of planning, you’ll have a happier holiday season when it comes to data and measurement!

Tagging URLs, and keeping track of your tagged URLs, can be tedious, and perhaps also a little intimidating. Hopefully, with this “back to basics” post, we’ve simplified it and laid it out for you clearly.

Medium and Source: Where is your traffic coming from?

Google Analytics by default can tell where your traffic comes from and separates them into the following categories:

  • Organic – Any time someone searches for a relevant keyword, your site pops up and they click on you.
  • Referral – If your site is linked to by another site.
  • Direct – If someone types your name into the browser (or clicks on it from an email or something).

These “categories” are called Mediums.

Of course, these are a little broad. There are other mediums we usually like to identify. For example, here are some typical categories we’d like to track:

  • Paid/CPC
  • Email
  • Display/Retargetted Ad
  • Social

Also, you probably want to know where in particular the traffic is coming from, such as what website. This is what GA calls Source.

Example, let’s say you have a product on amazon.com and they see a link to your website and they click through to it. The medium would be “referral” since it came from another website, and the source would be “amazon.com”.

Campaign Tagging Your URLs

Google Analytics allows you to override and control these Mediums and Sources by tagging your urls. That’s usually done for a marketing Campaign or initiative, which GA also allows you to label.

Tagging your urls is pretty simple. Simply pass the following parameters using question marks:

  • Campaign (utm_campaign) – For marketers, this allows you to separate your efforts (and therefore your data) into particular campaigns.
  • Medium (utm_medium) – The category of the type of channel the traffic is coming from. Again, like email, referral site, social media, paid add, etc.
  • Source (utm_source) – The actual source of traffic. What site your traffic came from.
  • Content (utm_content) (Optional) – You can use this to distinguish two different creatives or two different links in the same email that are part of the same campaign. For example, a banner link or text link within the same email going to the same place./li>
  • Term (utm_term) (Optional) – You might have a specific keyword the campaign is centered around. This is where you can specify that. Actually, in some cases, you can configure this parameter to be automatically populated by third-party SEM networks.

Tagging Strategy

The main purpose of tagging is to differentiate between the different campaigns you are running. These could be online paid ads, social viral campaigns, email campaigns, even offline campaigns. It’s important to have a structure and strategy from the onset. Here’s an example I stole from my colleague Allaedin’s post previous post on tagging!

Let’s create a chart to organize our campaign tags (click to enlarge).

“Retargeting”, “Magazine”, “TV”, and “Radio” are not part of the Default Channel Grouping in the Channels report, but you can customize the Default Channel Grouping as described in our channel grouping blog post here.

From the chart above, let’s tag a display/retargetted ad link that you’re using for AdRoll.

The required campaign tags are:

  • utm_campaign = holiday-campaign-2015
  • utm_medium = display
  • utm_source = adroll

The resulting url will be:

https://www.yourdomain.com/yourproduct.html?utm_source=adroll&utm_medium=display&utm_campaign=holiday-campaign-2015

Reporting on Source/Medium

So now, you can report and filter on your campaign by campaign name or source/medium as dimensions. You can easily segment for the campaign, source, or medium now, or choose from a variety of reports to see how your campaign is doing.

Go to “Acquisition” on the left side menu. (You can also view metrics for your campaigns within the Source / Medium report.)

You’ll see a list of campaigns and you can click through to drill down and see how each Medium/Source did.

Offline Campaign Tagging and Implementation

There are a couple ways you can do this. For example, you could create the “ugly” tagged url and just use a shortener. But even shortened url’s are not branded sometimes and also still hard to remember!

I prefer the simple redirect way. If your site is on a unix environment, it’s really simple with the .htaccess file.

Per our chart above, this is how you would tag the GQ Magazine ad you are running for the cologne you might be selling for the holidays:

https://www.yourdomain.com/yourproduct.html?utm_source=gq&utm_medium=magazine&utm_campaign=holiday-campaign-2015

Notice, the source is “gq” and not “gq.com” because this is the offline source. You can differentiate sources this way if you’d like.

You probably don’t want to have this long ugly url in your ad, so in the .htaccess file, you can create a redirect to this particular url:

Redirect /gq https://www.yourdomain.com/yourproduct.html?utm_source=gq&utm_medium=magazine&utm_campaign=holiday-campaign-2015

That code will redirect anyone going to yourdomain.com/gq to the appropriately tagged url. You’ve branded shortened your tagged url!

You can use the following for the copy for your magazine ad. Similarly, you can create other branded urls for offline marketing, like flyers, cards, tv, etc.

https://www.yourdomain.com/gq

(If you are investing heavily in TV advertisement, you should consider a more advanced analytics infrastructure and invest in platforms such as Adometry for cross-channel attribution).

Tagging Tools

If you’re not technical, remembering the campaign parameters can be a little difficult and tagging all the url’s can be a tedious task.

For one-off urls, use our quick tagging tool the Url Builder.

Final Notes

  • This is “the” year of mobile, if you haven’t noticed :). If you’re driving traffic to promote your app downloads, follow these instructions for proper tracking and analysis.
  • You should not manually tag AdWords campaigns; instead, link to AdWords from the Google Analytics property admin and enable Autotagging. Google Analytics will receive all data that the manual campaign parameters would provide, plus cost and much more additional AdWords data, such as ad position and the full, matched query string.
  • For email campaigns, you normally specify the list name or the type of email (such as “newsletter_subscribers” or “leads”) as the Source.
CP Marketing

Share
Published by
CP Marketing

Recent Posts

Optimizing user experiences with Digital Experience Analytics (DXA) platforms

As consumers become increasingly digitally savvy, and more and more brand touchpoints take place online,…

1 month ago

Enabling Value-Based Bidding with Google Tightlock

Marketers are on a constant journey to optimize the efficiency of paid search advertising. In…

1 month ago

Resolving “Unassigned” Traffic in GA4

Unassigned traffic in Google Analytics 4 (GA4) can be frustrating for data analysts to deal…

2 months ago

This website uses cookies.