Analytics & Digital Marketing Tips

Campaign Tracking in Google Analytics

December 28, 2010           Analytics, Google Analytics

When you send out your monthly newsletter, how do you measure the performance of your campaign in Google Analytics?  When you advertise in a magazine or air a television commercial that directs viewers to your website, how do you measure conversion of those visitors?  When you engage users through your social media channels and promote your website, are you able to measure conversion of Twitter versus Facebook?

If you are not assigning visitors from these sources to campaigns in Google Analytics, then you will not be able to properly segment.  Without proper segmentation, it will be difficult to make actionable insights.

Campaign Tags

The campaign tags in Google Analytics are query-string driven.  By appending specific values on the end of a URL on the initial page that is visited, that visit is attributed to the campaign parameters you’ve setup.

For example, instead of linking to http://www.mywebsite.com/my-web-page.html, you would link to something like http://www.mywebsite.com/my-web-page.html?utm_source=provider-name&utm_medium=email&utm_campaign=newsletter-12-21-10.  Notice the bold part?  That is what we added to the end of the URL.  When a user clicks this link, Google Analytics records this data as the traffic source. There are a few other parameters that you can use with campaign tagging (discussed below).  The ones referenced above are the required fields.

You can use Google’s URL Builder to easily generate your own link.  You’ll find a total of 5 parameters that you can use:

  • Campaign Source (utm_source): This is the source bucket that you’d like to identify users as coming from.  We often use the newsletter service name, such as Mailchimp.
  • Campaign Medium (utm_medium): This is the medium by which the campaign was delivered, such as email or radio, etc.
  • Campaign Term (utm_term): This optional field is used to specify the keyword that was used to display the campaign.
  • Campaign Content (utm_content): This optional field is used to differentiate the specific link or entry point method that brought the user to  your site.  This could be a specific link’s title or can be used for A/B testing.
  • Campaign Name (utm_campaign): This is the name of your campaign or promotional effort.
Technical Note #1: If you don’t like these parameter names, you can override the parameter names that are used.  Additionally, if you would rather use a ‘#’ instead of a ‘?’, use _setAllowAnchor.
Technical Note #2: It is important that you only use campaign tagging on external links that point to your internal site.  Do NOT, for example, add campaign parameters to URLs from a call-to-action on your homepage that links to another interior page.  We recommend watching the most recent Web Analytics TV, where they (Avinash Kaushik and Nick Mihailovski) answer this specific question at 2 mins and 11 seconds.

It is important to be consistent in your usage of how you structure your campaign tags.  Be sure to keep an excel spreadsheet with your campaign tag structure.  It makes creating new campaign tags so much easier!

Online Campaign Tracking

Using campaign tagging in Google Analytics opens a new door into the analysis of campaign performance.  Let’s look at a common use case — newsletters.  Your newsletter provider may already provide an easy method to automatically tag all of your links with campaign tags.  Our favorite, MailChimp, provides this along with many other cool features (such as list segmentation, Google Analytics data mashup, and more).  If you aren’t as lucky to be using an email newsletter provider that automates tagging, you’ll want to manually tag each link in the email with campaign tags.  Once tagged, you can easily view ecommerce conversion rates and revenue, goal conversion rates, bounce rates and more within Google Analytics.

There are many creative uses for campaign tagging.  For example, one of our clients has an ecommerce site that allows visitors to be notified when a product is back in stock.  The email that gets sent out to the visitor, when it is back in stock, has campaign tags appended.  We can then go into Google Analytics and view the ecommerce conversion rate for users that arrived to the site via this back in stock notification email.   Once we know what the performance is, we can then work to enhance the email communication and drive better conversion rates.

Ecommerce Campaign Conversion Rate

Social Media Campaign Tracking

If you send out a link on Twitter and a user, who uses a Twitter client (any non-web browser client), clicks on your link, they will typically show up as a direct visit.  This is because they do not have a referring source.  They are not coming from another website.  The same is true for users that use Outlook as an email client or the Facebook application on the iPhone.  You can overcome this by using campaign tagging on your URLs — you can even do this with shortened URLs such as bit.ly, prior shortening them.  You’ll end up with the shortened URL, but when the user clicks the link, they are redirected to your landing page, with the campaign tags appended to the URL.

Offline Campaign Tracking

An often overlooked channel of campaign tracking is offline campaigns.  If you stick your website’s URL up on a huge billboard along side the freeway or in a magazine, you obviously don’t want to put an incredibly long URL with utm_source parameters in it.  By using a server-side redirect, you can redirect users that go to http://mywebsite.com/freeshirt to http://www.mywebsite.com/freeshirt.html?utm_source=billboard-name&utm_medium=billboard&utm_campaign=free-shirt-promo.  You can use this method for radio, magazines, newspapers, etc.

Google Analytics Campaign Report

The Data

When you view your analytics data, you’ll see all visitors that clicked a tagged link under the ‘Traffic Sources > Campaigns’ report.  Note that this report also includes your paid AdWords campaigns.  If you have goals or ecommerce configured for your profile, you can select the appropriate tab of the report to view revenue, conversion rates, and more.

When you view the ‘Traffic Sources Overview’ report, campaign visitors show up under ‘Other’.

Google Analytics Traffic Sources

By creating an advanced segment in Google Analytics that matches a specific campaign name or source, you can then apply that segment to a variety of reports to analyze conversion rates, engagement and more quite easily.

You’ll be glad that you took the time to tag your URLs!

 

  • Guest

    Great post, but does it work if the link you are posting is to a PDF based on your site?

  • Google Analytics does not track PDF files themselves. You can track the click to go off to download/view the PDF by using a _trackPageview or _trackEvent in the onclick attribute of the link tag. In your case, it sounds like you would want to have a landing page that has the UTM campaign parameters in the URL and then use the onclick attribute to track the action of downloading/viewing the PDF.

    Hope that helps!

  • Olaf

    Nice article, just to add a bit: If you want to see in Google Analytics, how often an email or newsletter was opened (or viewed), you can use http://email-tracking-with-google-analytics.com/, There you can get a pixel which you insert into your email. The pixel will then cause your Google Analytics to show how often the email has been read.

  • Christian

    Hi Joe,
    I have a issue about campaign tags, I set up 3 URL with Google URL builder for 3 different sites, and just one of them send me traffic for tracking in Google Analytics, and the other 2 do not appear nothing in GA. However when i used Google URL shortener for all of the URLs, all of them appear in the statistics data of URL shortener dashboard. Do you have any idea why Campaign tags can not work for my other 2 sites ?

  • Drew

    Hi Joe. Really great article here! Hey, 1 quick question. I am adding UTM URLs to a banner campaign – but 1 thing I can’t seem to gather now in Google Analytics is: where exactly those users went on the site after arriving. In other words…if banner campaign XYZ sent 100 visitors to the site…and let’s say Google Analytics shows them real well and very clearly as campaign traffic b/c of the UTMs – well, now I can speak to average time on site, average pageviews, etc. by those campaign referrals. BUT – my client would also love to know which pages those folks from the campaign actually viewed. Another way to say it is: “what were the top 3 pages viewed in aggregate by the folks who entered the site from the banner campaign XYZ?” Is that something GA should tell us – I just cannot figure out how to get at that level of detail. (you can assume that they all enter the site at the homepage by the way). Thank you again Joe!!

  • Laura

    Hi Joe,

    I would love to know the answer to other Joe’s question too. Any clues? Cheers Laura

  • Adrian

    If I understand your question correctly, then all you would need to do is set up the campaign as an advanced segment. Just create New Advanced Segment, and then use Campaign as your dimension. Then when you’ve got this segment ticked, you’ll be able to see all the actions of people on your site that have come just through that campaign.

  • Arizona Renaissance Festival

    I am very confused by some results. I have exported a report on our campaigns (URL tracking) and the number of sessions is very different from the number of clicks that our media partners are reporting. Logic tells me that if I’ve provided them with the tracking URL for our web ad and they’ve used it then the number of clicks on that ad should pretty closely correspond with the number of sessions for the campaign. Am I missing something?

 

Analytics Blog

We're here to help with tips and insight on the following topics:

Subscribe to RSS


Optimize your website and marketing campaigns

Get a constant flow of Google Analytics help and digital marketing tips, case studies and more from Google Certified Partner Blast Analytics & Marketing.




Connect with Blast Analytics & Marketing




 

1 Shares
Share
Tweet
Share
+11