Tracking Online and Offline Marketing Campaigns with Google Analytics

Although every day is a mother’s day, here in the US we dedicate one day especially for her to show our appreciation and thankfulness. Mother’s Day is just around the corner. As a marketer or a business owner you are getting ready, like all retailers, to kick-off your Mother’s Day campaigns. Last year’s campaign did ok. You didn’t get fired :), but you didn’t get a promotion either! :( You are a much smarter marketer now and you want to better track your initiatives, assess what channel is performing and fix what is not performing. You are planning all sorts of marketing activities: offline: TV and newspaper ads; online: paid Search, email, banners, social media, and others.

You have your messaging, promotions, copy, creative, and landing pages all ready, and soon you will go live and you have a week to figure out this “tracking, measurement and analytics” business!

No worries! Google Analytics and this post have come to the rescue!!

In this post I will walk you through a process of how to plan and implement a comprehensive external campaign tracking.


  • You have Google Analytics implemented on your site
  • You have a basic familiarity with URL tagging
  • Last but not least this post also assumes that you are ready and willing to be proactive and you do care about analytics and campaign ROI :)

Prerequisite: Structure & Naming Convention

As you know, the sole purpose of tagging is to differentiate between the different ads and campaigns you are running, so it is very important to agree on the structure and the naming convention as a first step. Here is an example:

As you can see from the chart above, we are running different online and offline ads for our Mother’s Day campaign. In the next section, we are going to tag all these ad’s links with the campaign variables using the URL Builder tool provided by Google.


Email campaigns are one of the most effective ways of attracting visitors to your site especially existing clients. If we don’t tag the emails links with the right campaign tags, visits from emails will be attributed as referral or direct traffic.

How do we tag email links?

  1. Use the URL Builder or CampaignAlyzer to create tagged links
  2. Enter the following variables into the URL builder:
    Website URL:
    Campaign Source: newsletter-april
    Campaign Medium: email
    Campaign Name: Mother’s Day 2010
  3. Use the generated link URL in your email (ex. “Visit the Store” button”)


We will follow the same tagging steps that we used for email campaign to tag our banner campaign:

  1. Use the URL Builder or CampaignAlyzer to create tagged links
  2. Enter the following variables into the URL builder:
    Website URL:
    Campaign Source:
    Campaign Medium: banner
    Campaign Name: Mother’s Day 2010
  3. Use the generated link URL in your banner (ex. “Shop Now” button”)


Social media today is reshaping the online marketing landscape. People are using YouTube, Facebook, Flicker, and Twitter for more than just personal updates and video/picture exchange. There is a huge amount of promotion and branding taking place in these sites and our job in this post is to measure the success of these marketing efforts.

Let’s use Twitter for our Mother’s Day campaign and make sure we tag all links to our site with the proper campaign variables.

How do we tag Twitter links?

  1. Use the URL Builder or CampaignAlyzer to create tagged links
  2. Enter the following variables into the URL builder:
    Website URL:
    Campaign Source: twitter
    Campaign Medium: social media
    Campaign Name: Mother’s Day 2010
  3. Shorten the generated link URL using any URL shortening tools (I usually use
  4. Tweet about your promotion using the tiny URL

Paid Search – Google

Thank goodness that Google AdWords and Google Analytics are cousins and integrate very well together! Google AdWords has a nice feature called auto-tagging which makes it easy for us to see AdWords campaign information in our Google Analytics reports without any manually tagging.

To learn more about auto-tagging visit this help topic.

How do we enable auto-tagging?

  1. Sign in to your AdWords account
  2. Click on My account tab and select Account preferences
  3. Under Tracking section, click Edit
  4. Check the Destination URL Auto-tagging checkbox
  5. Click “Save changes”

Paid Search – Yahoo

Unlike AdWords, to track Yahoo paid traffic we need to manually tag the destination URL with the campaign variables.

  1. Tag your yahoo ad link using the following variables:
    Website URL:
    Campaign Source: yahoo
    Campaign Medium: cpc
    Campaign Term: {OVKey}
    Campaign Name: Mother’s Day 2010
  2. Use the tagged URL for the “Destination URL” field

Paid Search – Bing

Similar to what we did with Yahoo ads, but with the following variables:

  • Website URL:
  • Campaign Source: bing
  • Campaign Medium: cpc
  • Campaign Term: {QueryString}
  • Campaign Name: Mother’s Day 2010

Tracking Offline Campaigns

When we talk about tracking campaigns, it is not enough to focus only on online campaigns. We have to include the offline campaigns in our reports for complete analysis. In this section, I will share with you one method of tracking your offline campaigns in Google Analytics in 2 simple steps:

  1. In your offline ads, refer visitors to a page that is unique to the campaign; []
  2. Tag all visitors to the unique page with the campaign variables [source, medium, & campaign name]

How to tag all visitors to with the campaign variables?

We will assume that all visitors to the unique landing page [] are coming from a specific offline campaign let say the USA Today newspaper. When the USA Today visitors request the promotion URL and before we fire the Google Analytics code, we will refresh the landing page using meta-refresh tag, which update the URL with the campaign UTMs. When The Google Analytics code gets executed after the page refresh, it will see the URL with the campaign UTMs attached to it and will attribute the visit as desired.

How do we tag destination URLs?

  1. Go to the URL Builder
  2. Enter the following variables into the URL builder:
    Website URL:
    Campaign Source: usa-today
    Campaign Medium: newspaper
    Campaign Name: Mother’s Day 2010
  3. Add the following code to the header of landing page before the Google Analytics tracking code

    <link rel=”canonical” href=”” />
    <meta http-equiv=”refresh” content=”1;URL=’s%2BDay%202010″>

Analyzing the data:

Now as we had all tags in place, it is time for deep dive analysis into the “Mother’s Day 2010″ campaign. I suggest that you isolate the campaigns’ visits by using advanced custom segment and look at this unique segment across reports.

Creating Custom Advanced Segmentation

  1. Sign in to your Google Analytics account
  2. Advanced Segments > Create a new advanced segment
  3. Add the following dimensions:

Viewing Reports (Show me the money!!)

Now, you are ready to conduct analysis based on the customized segment. You can look at the traffic sources report and see how many people purchased and from which medium:

From the first look at the ecommerce numbers above, we can confirm that:

  • The TV campaign has the highest conversion rate
  • The newspaper campaign was not as effective as other campaigns
  • Social media has the highest ROI (Return on Investment)

Click on the dropdown menu below for more marketing campaign tagging examples.

If you like this exercise and you were able to extract some valuable insights for your business, apply the same concept for the upcoming Father’s Day, which is on June 20th here in the US and do a comparison between the users’ purchasing behavior in these two very special occasions.

Share your findings and happy analyzing and drop us a comment below!


  • For advanced users and those interested in multi-channel attribution, you can make use of the the Multiple Custom Variables (MCV) feature in Google Analytics
  • If you are running social media and online viral marketing activities and you are active in blogging, on Twitter and Facebook, you should include “off-site” measurements in your overall campaign analysis. In addition, be sure to dedicate resources to listen and participate in the social conversations around your brand, products and campaigns

Related Posts

41 thoughts on “Tracking Online and Offline Marketing Campaigns with Google Analytics”

  1. Good breakdown, but if you are going to use a redirect you should use a 301 (permanent) redirect, not a meta refresh. 301 redirects are better for your SEO.

  2. Hi Allaedin

    Really one of the best descriptions of campaign tracking I have seen.

    In my experience it is often more efficient using a completely unique URL in the material and redirecting the visitors from there with the campaign code to the actual landing page.

    People are often so lazy that if the URL says – a good part of them will enter and try to find your offer from there.

    But then again that might just be us Scandinavians :-)

  3. This is great! Never thought I could track everything in one place. I’m still fairly new to the industry so any little bit helps

  4. it is such a great post.
    usage of meta refresh is nice and simple implementation.

    i really like your chart and structure of your campaign graph.

  5. Ben, nachy, helpful, Mandar Marathe, William, Matt and Andy: Thanks for your kind words. I am glad you found the post of benefit!

    Celine: Thanks for the link. Caleb is one of our dear friends. He implemented nice tools for GA

    Carlos: Thanks… I agree!

    Briana: Good luck and welcome to the Analytics world :)

    Steen: Thanks for reading! No, it is not just the case with Scandinavians :)

    Using Vanity URL is a good option, but I personally found tagging is cleaner and easier in implementation than using vanity URLs especially for big campaigns where you are using different marketing channels; affiliation, email, banner, paid, social media,…

  6. Wow, very thorough post here. We invite you try out Campaignsync, which will automatically tag your Microsoft adCenter and Yahoo! Search Marketing campaigns. Simply upload a campaign as a CSV file, enter your destination URL and you’re done in a few clicks. Try it out and let us know what you think, it’s free!

  7. Thanks Allaedin :) I’m actually working on another tool that is going to be even better than the Google Analytics Campaign URL Builder (GACUB). It should be ready in a few months so follow me on to know when it’s ready for beta testing ;)

  8. I would say also, it’s a very smart comment that Steen added.
    He says, it’s more efficient using a completely unique URL in the material and redirecting the visitors from there with the campaign code to the actual landing page.

    People are often so lazy that if the URL says – a good part of them will enter and try to find your offer from there.

    And I agree with him.

  9. Thanks Yomna for reading! I agree with you and Steen about the usability issue with the use of sub-domains or folders for ad’s destination URLs. One option that you can consider is to use completely unique domain names for each offline campaign (ex., In this case you will need to make sure your domains are linked properly in order to keep the session information alive across domains. Read my post on this topic here []

  10. It’s a great post too, but I thought of it in more simplified way… It could be a very silly suggestion :D but let me tell it whatever…

    As we said, the majority of the offline visitors will totally type the major address without the extention (/mother), and that means they will be considered as (Direct) visitors in the GA profile.
    So, what if we put a banner ad (or just a click button for this offer) in the home page, so those who read the newspaper or saw the tv ad, will click on the banner from the home page, then they will be directed to the offer and then the special code you added for tracking the offline visitors on the landing page will work.
    And in this case we will be able to differentiate the offline visitors from the Direct online visitors.(those only who entered direct> HP banner ad), without the need to create any additional subdomains for this.
    So, we can then gather the stats of offline visitors from the profile under:
    – (Direct>/mother).
    – (URL: one shot visit

    It’s just a suggestion and I’ll be glad to know if it’s practical or not :)

  11. Yomna, a banner in the home page will be shared by all people regardless of their traffic sources. You need a unique identifier for you offline visitors. One other known practice is to use coupons to track the performance of your offline campaigns.

    Whither you are more convinced with using the unique URL or coupon or any other method, I suggestion that you try all different techniques and see which one works better for your site visitors’ experience and conversion.

  12. Outstanding post, Allaedin. Feras shared the link with me and quite ironic that just this day I was trying to explain the concept of link tagging to a client who just wasn’t getting it. Too bad I didn’t have this post to share with them at the time…but I shall. Keep up the great posts.

  13. Hey Allaedin, I finally read this! Here is our only concern with a meta fresh vs a 301. True, the meta refresh will be way easier to implement. But, what if it is a big company and a lot of people actually link to the vanity URL (e.g. super bowl ad?) and then the link love doesn’t pass to the rest of the site.

    I don’t get any credit for that thought, someone else here at Luna pointed that out — Robbin

  14. Hi Robbin, thanks for the feedback. Yes, I totally agree with you about the use of 301 vs. Meta refresh.

    301 redirects are heavily dependent on the technology being used (html, asp, php, etc) and in this post I wanted something people could use easily and immediately (meta refresh).

    I am not worried about big companies since they will come to consulting firms like LunaMetrics and E-Nor for their advanced implementations, and I am sure we will not use Meta refresh for their pages :)

  15. Great read and informative. I’ve used this successfully to monitor all of our marketing campaigns. Another helpful tool I’ve come across call tracking where I can put a different phone number on each marketing campaign to track and get reports on exactly which ads are bringing in the most revenue. Dynamic Call Tracking has been real reliable with cheap rates.

  16. Does anyone know how to add this code to a QR tag? I want to know exactly when people scan a tag in each mailing I send out – the tag just links them to our mobile site. I currently am tracking visits to my mobile site – but i’d like to know specifically which piece of mail they are scanning the code from.

    It does not seem to be working when i do the URL generator and just add the full link to the QR tag.

    If anyone knows – please let me know. thank you.

  17. You’re on the money every step of the way. The whole process you went through is gold!

    I agree that using a custom link is the way forward. Nice article, i’m bookmarking this one.


  18. Nice post. I have one doubt. How does google analytics calculate the transaction amount?


  19. Hi Anand,
    I am not sure if I understood your question but there is no calculation involved. By using the Google Analytics E-Commerce code, you report the exact transaction total amount to GA.
    For more info about tracking e-commerce transactions read the this help topic

  20. Great Post of campaign tracking:

    I generated a tagged url by using google url builder. I tested it by clicking it in the email. But the “campaign” is not shown in the Google Analytics > Acquisition > Campagin.

    Do you know any possible reason?

  21. Thanks for your comment Sam! We’d need to see the specific tagged url and need more details of the issue you’re running into in GA. You can send that and screenshots to support[at], and we’ll try to take a look.

  22. Nice article.

    Online Campaigns can be analyzed in Real Time with our Dashboards and Hourly/Daily Reports to help optimize your investment. Metrics like Visits(not clicks as reported by Marketing Tools), Bounce Rate, New Users etc as per the Campaign Spend with reccomendation to Scale/Maintain/Tone-Down the investments as applicable.

    TV Campaigns (TVC) involve a high investment and a complex scheduling and lack of measurement standards for Web Impact. We have developed Analytics based solutions for Real Time and Deep Dive Analytics for analyzing the impact from various angles. Be it Date, Timeslot, Weekday, Ad Break No, Ad Position in Break, Ad Duration etc many such factors. Get deep insights into the combination and domination of top most impacting factors. Also analyze Channel wise performance using our special Top Contribution and Exact Attribution Modelling(Linear Modelling) techniques.

  23. the offline utm tracking is very interesting in this article, the more and more we figure out the offline tracking aspects the more value it has to marketers

Leave a Reply

Your email address will not be published. Required fields are marked *


You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">