Google Analytics Campaign Tracking Pt. 1: Link Tagging

November 10, 2006 by Justin Cutroni

What is Link Tagging?

To track your marketing campaigns Google Analytics uses a technology called link tagging. This provides a fine level of detail about marketing efforts. The data we gather from link tagging helps us make informed business decisions about our marketing spend.

With link tagging, we add additional information to the destination URL used in an ad. The technical name for this additional information is the query string. Here’s an example:
http://www.cutroni.com/landing_page.php?utm_campaign=fall-sale
&utm_medium=banner&utm_source=boston.com&utm_content=text-only

*** NOTE: I moved some text to a second line for readability ***

Everything after the question mark is called the query string. Within the query string we have a number of parameters. Each parameter is separated by an ampersand (&). Pulling apart the above query string we find the following parameters:

utm_campaign=fall-sale
utm_medium=banner
utm_source=boston.com
utm_content=text-only

Each parameter can be further divided into two parts; a variable (the text on the left side of the equals sign) and a value (the text on the right side of the equal sign). Let’s break the above parameters into variable – value pairs:

Parameter Variable Value
utm_campaign=fall-sale utm_campaign fall-sale
utm_medium=banner utm_medium banner
utm_source=boston.com utm_source boston.com
utm_content=text-only utm_content text-only

Ok, stick with me. We’ve gone from a query string, to parameters, to variables and values. Now, let’s start to explain what all of this means. What are the variables and values? I’ll start by explaining the variables:

Variable Meaning
utm_campaign The name of the campaign. Think of this as a bucket. It holds all of our marketing activities. For example, we may be buying some keywords on Google, running some banner ads and sending out an email all to advertise our winter ski sale. However, these three activities are all part of a bigger marketing campaign, our ‘Winter Ski Sale’.
utm_medium I like to think of the medium as the mechanism, or how the message is delivered to the recipient (i.e. email, banner, CPC, etc). What is the ‘distribution method’ that is used to get our message out to our clients?
utm_source Think of utm_source as the ‘who’. Who are you partnering with to push your message. If you’re tagging CPC links the source may be Google, Yahoo! or MSN. This could also be the name of a service that will be pushing banner ads for you.
utm_content The version of the ad (used for A/B testing). You can identify two versions of the same ad using this variable.
utm_term The search term purchased (if you’re buying keywords). This is not always used and is NOT included in the above example.

It’s important to note that you do not always need to use every variable. The core variables are utm_campaign, utm_source and utm_medium. You should always use those three. With Campaign, Medium and Source you’ll reap the most benefit from Google Analytics.

Just to recap, link tagging is the process of adding additional information to the destination URLs we use in our ads. This additional information consists of variables and values.

Here’s the really cool part, the values. The value for each variable is a piece of business information that will end up in Google Analytics. Let me clarify that, you’re actually taking information that is specific to your business, like the name of a marketing campaign, and placing it in Google Analytics. GA will display it, exactly as it is typed, in a series of reports called the Marketing Campaign Results (see Part 3 of this series). This is extremely powerful because you can look at your analytics data through the lens of your business.

So now we know everything about what link tagging is, but what happens after we tag our links?

When someone clicks on a tagged link Google Analytics, using the urchin.js JavaScript, stores all the values in a cookie on the visitor’s machine. That way we can track the traffic generated by each marketing campaign. When a visitor completes one of our goals we can view the marketing activity that drove them to the site.

It’s important to understand that the cookie will persist until 2038. It’s also important to understand that the cookie will be updated with other information. For details about how Google Analytics stores various referral information please see the following post: How Does Google Analytics Track Conversion Referrals?

How to Tag Your Links

The process of Link Tagging is simple. Start by identifying the information that you need to place in the variables. You need to identify the campaigns, mediums and sources that you use in your marketing activities and place it in your destination URLs. Then modify your destination URLs to include the new variables and values.
How do you do that? You can use any text editor, the Google Analytics URL Builder or the special tool I discuss in Part 2 of this series. I’m partial to the special tool :)

Remember, if you’re placing links to your site in cyber-space, you should be tagging them.

  • Twitter
  • StumbleUpon
  • Digg
  • del.icio.us
  • Facebook
  • LinkedIn
  • FriendFeed
  • Sphinn
  • Google Bookmarks
  • Reddit
  • email
  • Technorati
  • Yahoo! Buzz
Subscribe:
  1. 101 Responses to “Google Analytics Campaign Tracking Pt. 1: Link Tagging”

  2. I have been thoroughly impressed with all the hints, tips and tricks available in this blog. Thank you so much, this was sorely needed.

    I did have a question though. Is there a way to find out query string parameters from a referral? Meaning that http://www.somesite.com/forum.php may be the referral, but I really would like to see what the request scope parameters were as well, as the URL was most likely http://www.somesite.com/forum.php?post=xyz&foo=bar.

    I look forward to your reply.

    Best Wishes.

    By Georg on Dec 11, 2006

  3. Hi Georg,

    Unfortunately GA will not capture the query string variables in a referral URI.

    Thanks for reading and thanks for the positive feedback.

    Justin

    By Justin on Dec 12, 2006

  4. This documentation is so much more complete and thorough than anything Google provides for this subject.

    By Steven on Jul 2, 2007

  5. Hi Steven,

    Thanks so much for the comment. Honestly, that’s why I do this :) I’m trying to dump everything I know into a book that is written in the same tone and style as the blog. Hopefully that will be out soon (the next few months) and will be very affordable (about $10).

    Thanks for reading and the kind words.

    Justin

    By Justin on Jul 2, 2007

  6. Hi Justin,
    great article! I had planned a link planned to monitor some newsletter campains and it works great but I got stucked with the ugly-url problem: the querystring definitely ruins the well formed url, hit the usability because the url became longer that the browser input (copy problem by non experience users) and finally sometimes the user copy and paste it around (email, blog, etc..) spreading a false referer.
    I’m testing how I can avoid that; I found a solution using the urchinTracker but require a (non tracked) redirect so it’s not optimal.. any ideas?

    Thank you in advance.

    Regards,
    daniele

    By Daniele on Sep 20, 2007

  7. Hi Danielle,

    You can’t really use urchinTracker() to identify referrals. The reason is that urchinTracker() creates pageviews while referral information is visit information.

    It sounds like you need to use vanity URLs with a redirect that automatically adds the campaign tracking query string parameters.

    Hope that helps and thanks for reading the blog!

    Justin

    By Justin on Sep 26, 2007

  8. Hi Justin,
    thank you for the reply. Of course urchinTracker use is not-so-good: I can read the referer as pageviews but of course this is a weak solution because it losts the ability to segment and cross the data in the analytics way.
    Redirect seems the most logical way but it has to be done in client side (and I don’t like that) and then you have to worry about counting two times the second views, so you have to implement a way to sniff the redirect and omit tracking it.
    By the way I have to *remove* the querystring, not add it. The problem is not the compless link on the mail (often hidden) but the url that stay in the browser url location after the user click on it.

    By Daniele on Sep 28, 2007

  9. >>Unfortunately GA will not capture the query string variables in a referral URI.

    Sure they can, but you have to setup a custom filter. Google it and you’ll find it. I set it up a while back. The only pain is when you go to referrals and then your custom variable, the GA page doesn’t have links and long links are cut off so you have to view source and copy and paste to visit any site.

    Why doesn’t google clue into this obvious need???

    And why don’t they compress the js code, it’s so obvious too, no one is reading it.

    By ziggy on Oct 8, 2007

  10. If I tag a link without the source, will the referring domain register
    in the reporting data?

    For example,

    http://www.mysite.com/?utm_medium=banner1&utm_campaign=promo1

    Instead of,

    http://www.mysite.com/?utm_source=external&utm_medium=banner1&utm_campaign=promo1

    The reason I want to do this is that I may not know who the source is
    (I’m passing the code around in a viral campaign), and I’d rather GA
    “automatically” pick up the domain/source, but where I can still
    customize the medium and campaign tags so I know which banners are being clicked and how often.

    By Joe on Oct 23, 2007

  11. Hi Joe,

    If you leave off the utm_source variable then the GA tracking code will automatically identify the link as a referral. It will override the values that you enter for campaign and medium.

    Is it possible for you to add some JS to the link you provide? If you could dynamically add document.location to the utm_source variable then you can get the data that you want. The key is to add some script that does document.write(‘utm_source=’+document.location) or something like it.

    Hope that helps and let me know if it works.

    Thanks for reading the blog and thanks for the question.

    Justin

    By Justin on Oct 23, 2007

  12. Thanks, I got that to work… kinda. For others, I posted the code below.

    But when I go into GA, I get 0 for visits. Literally, the # 0 shows up. I’m not sure how that’s possible! But I don’t think it’s particular to this javascript approach. I’ve seen other instances for normal tagged links where the visit count is 0. Is this a “first visit” thing, or is the code not catching properly?

    Thanks,
    Joe

    The javascript code I used:
    document.write(““);

    By Joe on Oct 28, 2007

  13. I am not sure if this is possible but can we pass anything unique to a particular page, as argument to urchinTracker()?

    My requirement actually is that I want to check which the username/userId visited a particular page…

    Is it possible in GA?

    By Kapeel Mopkar on Nov 1, 2007

  14. Hi Kapeel,

    Whatever value you pass to urchinTracker() will become a pageview. But be careful. It is against the GA TOS to send any PII to Google Analytics.

    Justin

    By Justin on Nov 1, 2007

  15. GA does not seem to track all visits correctly when the utm_X parameters are sent along with POST data.

    works often, but not always. Possibly the Internet Explorer 6 fails to comply here… any ideas?

    By Chris on Nov 15, 2007

  16. I noticed that google uses the campaign names from the adwords account when auto-tagging is on. Since we track other campaigns, we have been using the utm_campaign field to identify engine, campaign and adgroup, and then parse the data in excel. We would like to do this with google as well (since there is now way to pull a report out of GA with all adgroups (have to drill down into each campaign.

    I know that you CAN tag Google with the GA parameters, but do we have to then turn off autotagging? Even if we do this, will GA replace the campaign names it currently grabs with the utm_campaign values we set?

    Thanks,
    Chris

    By Chris on Nov 16, 2007

  17. Hi Chris,

    I havenot heard of that problem. Also, I’m not sure why you would need to pass the campaign tracking parameters via a POST. The campaign parameters are only meant to be present on the initial landing page. Then the values are stored as cookies on the visitor’s machine.

    If you’re talking about cross domain tracking then it’s probable that the third party site is stripping off the query string parameters.

    Thanks for the question sand thanks for reading.

    Justin

    By Justin on Nov 17, 2007

  18. Hey Chris,

    To answer your second question, YES. If you want to manually tag your AdWords links then you must turn off auto tagging. Once you turn off auto tagging and manually tag your links, GA will pull in the value that you specify in utm_campaign.

    Thanks for the question.

    Justin

    By Justin on Nov 17, 2007

  19. thanks for the great writeup. very clear. I think I understand how GA will track clicks on a given campaign. I recently started a website & am looking to sell banner ad space on the site. Can I use GA to track the ads that I run on my site? Can I track impressions of the banners using GA tagging or can it only track clicks?
    If not, is there something you can recommend for tracking the ad’s impressions?

    By Vic on Nov 28, 2007

  20. Hi Vic,

    To track banner impressions you’ll need to hack something together using urchinTracker. You’ll need to create a pageview every time an ad is displayed. You can learn about urchinTracker in this series of posts.

    A better solution will be to use event tracking when that feature is released.

    Thanks for reading,

    Justin

    By Justin Cutroni on Dec 2, 2007

  21. Anyone else who’s using GA event tracking to track banner impressions, I’d love to hear how you are doing it too. I’d really like to compare GA analytics figures versus my ad management solution to get a feel for the differences.

    By Tim Archambault on Dec 7, 2007

  22. Hi Tim,

    I think a lot of people are going to use event tracking to track ad impressions. Because the event data model is so flexible you should be able to track a substantial amount of data.

    Thanks for reading and thanks for the comment.

    By Justin Cutroni on Dec 7, 2007

  23. Hi Tim
    We currently have a number of banners set up on affiliate sites. Im hoping to be able to set up funnels from each of these to track the amount of custom from each of these. We are unable to add the tracking code to the actual page but could add this to the banner. Is this as simple as simply adding the tracking code to each of the banners?
    Also congratulations on the help you’re providing it’s a great help and is much appreciated.

    By Nick on Jan 7, 2008

  24. Can someone clarify if GA sometimes does not pick up certain utm_xxx variables, even if they are in the links I’m using?

    We are usng redirects from “friendly” URL’s (mydomain.com/VALUE) to the long URL with both the utm query string, plus some other aspx parameters of our own.

    GA seems to pick up the utm_source, but NOT the medium and campaign values.

    Can anyone explain?

    By Rich on Jan 15, 2008

  25. Hi Justin;

    I wonder what the “best” approach would be to track referrals from shopping comparison engines such as Nextag or shopping.com. I can tag the landing page URLs. This is what I am using:

    campaign: NexTag
    medium: shopping engine
    source: product_id

    Of course if I have lots of products I end up with lots of sources in GA. Or should “NexTag” be the source?

    There may be no right or wrong here, so am just wondering what approach other people are using.

    Many thanks,
    Michael

    By Michael Whitaker on Jan 18, 2008

  26. Rich,

    Not sure there is an easy solution to the problem that you describe. It could be that your server is using a delimiter other than the ampersand. I would check the cookies on your machine. Navigate to the landing page and after it redirect you look at the cookies. You should see a cookie named _utmz and it should contain all of your link tagging values.

    Hope that helps and thanks for reading.

    Justin

    By Justin Cutroni on Jan 20, 2008

  27. Hi Michael,

    First, always a pleasure to hear from you.

    I like the approach that you’re taking with the affiliate tracking. You’re capturing all of the data in a logical way.

    I really think that the best practice is capturing the data in a structure that works with the GA reporting. You’ve done that very well.

    With that said I think there a couple of small tweaks you could potentially use.

    First, if this is an ongoing marketing campaign, that you want to group with other ongoing marketing activities, you may want to change the utm_campaign value.

    Second, you may be able to take advantage of the utm_content parameter to capture even more information. But this depends on the shopping engine and the data they let you track.

    Again, you’ve got a great setup, and if it’s workig for you I would not change a thing.

    Thanks for reading,

    Justin

    By Justin Cutroni on Jan 20, 2008

  28. Will Google Analytics be able to track a referring url if there is no click invloved from that URL.

    Meaning, what if a site uses redirect code, would GA be able to track that redirect as it would a click from that URL.

    Thanks!
    A.J.

    By AJ on Jan 28, 2008

  29. Greetings,

    I have a question about tracking visits from email campaigns. When I see traffic sources in GA that have the word “mail” in them, as in the examples below, does this mean they were visits from clicks on the email that they opened? If not, what would these be, and how do I track email visits to the various links on the site (3 links in the emails).

    Examples:
    us.mg2.mail.yahoo.com / referral
    by114w.bay114.mail.live.com / referral
    netmail.verizon.net / referral
    bl108w.blu108.mail.live.com / referral

    By Joe Kamenar on Feb 5, 2008

  30. Does this syntax still apply with the new GA.js Tracking Code?

    By Matt on Feb 11, 2008

  31. Hi AJ,

    It depends. Referrals can, and often do, break GA’s ability to track referrals. It all depends on the type of redirect that is implemented. In general, HTML and JS redirects don’t work well with GA while server redirects preserve the true referral information.

    Hope that helps,

    Justin

    By Justin Cutroni on Jun 24, 2008

  32. Hi Matt,

    Yes, the campaign tracking syntax still applies even if you’re using the new ga.js tracking code.

    Justin

    By Justin Cutroni on Jun 25, 2008

  33. Joe,

    To track an email campaign you must tag the links in the email that you send out. If you do not tag the links the Google Analytics will not know that the visitor clicked on a link in an email.

    If you do not tag your links, and the visitor uses some type of web mail application, like GMail, then the traffic will appear as a referral. That’s why tagging links is so important.

    Justin

    By Justin Cutroni on Jun 25, 2008

  34. Hi Justin! Your provide very useful info here!

    I have a customer for which I have created a newsletter that contains a link to the customer’s website.

    I would like to track how many times this link is clicked. For this I was going to use GA link taging.

    The problem that I have is that I do not have access on the customer’s website and therefore I cannot install the script that is provided by GA for tracking.

    My question is: What shall I do to track the link in the newsletter without having to add any code in the customer’s website?

    Will tracking work if I just track the link using GA tags?

    Which domain name should I use if I follow this solution?

    If the link is clicked twice by the same newsletter reader, will GA count it twice?

    Sorry for the loads of questions and many thanks in advance!

    My question

    The newsletter contains a link that I

    By Alex on Jul 1, 2008

  35. Hi Alex,

    Link tagging will only work if you install the GA tracking code on the site. If you’re interested in just tracking clicks on the links in the email then you may want to check the metrics that the email vendor provides. Many email tools will track basic pre-visit metrics, like bounces, # messages delivered, clicks, etc.

    Hope that helps,

    Justin

    By Justin Cutroni on Jul 2, 2008

  36. Justin this site is amazing!

    I have 2 quick questions I hope you can help me with.

    I understand link tagging (which i will be using) but I would like to track impressions of these links (actually banners) I have heard and seen people do this, but I cant find anywhere! Im not savy on coding myself so Id need it explained or given to me.

    So basically I would like to be able to track impressions of a banner on my site and the clicks so I can calculate the CTR.

    2.

    Is there a feature of custormizing the actually GA account? Aranging data or layout to how you want it? Making your own pages to store cetain data on etc?

    Thanks again

    Matthew

    By Matthew Miele on Jul 13, 2008

  37. Hi Matthew,

    Glad you like the site. :)

    1. Tracking impressions can be done, but it’s definitely more of a hack than anything else. You can generate pageviews every time an impression happens, and then create a pageview every time a click happens. Then the two numbers can be used to calculate CTR.

    You can read mroe about tracking clicks with GA in this series of posts.

    2. There is no way to customize the GA interface. Unfortunately what you see is what you get.

    Thanks again for reading,

    Justin

    By Justin Cutroni on Jul 14, 2008

  38. Hi Justin,

    I’m using the following as a redirect from a vanity URL to a web page to track the effectiveness of print advertising…

    meta http-equiv=”refresh” content=”1;url=/index.php?main_page=product_info&products_id=141&utm_source=testmagazine&utm_medium=print&utm_campaign=testmagazineflexflash”

    When I look at my analytics I see that the tags show up as source, medium and campaign but they all have zero values for visits, time, etc. The vanity is url h-b.com/flexflash

    Any idea what the problem is?

    By Tom Walsh on Aug 19, 2008

  39. After looking through my reports I found that GA is seeing the landing page as /index.php rather than

    /index.php?main_page=product_info&products_id=141

    By Tom Walsh on Aug 19, 2008

  40. Tom,

    It looks like you have everything set up correctly. I tried the link and my GA cookies were set correctly. The only thing I can think if is that the GA cookies are getting set, and then, for some reason, you’re UPDATING the cookies with the redirect happens. I’ve seen this cause campaigns, mediums and sources have 0 vistis. I would make sure that the no GA code executes before the redirect.

    Hope that helps, and thanks for the comment.

    Justin

    By Justin Cutroni on Aug 19, 2008

  41. Hi Justin,

    I see your reply comment to Matt on June 25th that the same syntax works on the new ga.js. I am a bit confused by this…For example, I thought that:

    utm_campaign=fall-sale

    was suppose to be

    pageTracker._setCampNameKey(“ga_campaign”);

    By Craig S. Kiessling on Aug 29, 2008

  42. Craig,

    The code that you reference is only if you want to rename the query string parameters that GA uses to track campaigns. _setCampaignNameKey doesn’t have anything to do with the _value_ of the query string parameter, it literally changes the name of the query sting parameter. It tells GA that you will be using a query sting parameter names ga_campaign and not utm_campaign.

    Hope that clarifies things,

    Justin

    By Justin Cutroni on Sep 2, 2008

  43. We have been tracking our internal site traffic using _utmSetVar on our different page banners (homepage, cartpage, category page).
    The information then shows up in the Visitor Report/ User Defined. Thus limiting the amount of reporting I can provide our marketing team.
    I have requested that we tag the Linking URL with utm_source=homepage&utm_medium=banner&utm_campaign=freegift
    however; I am being told that doing this causes 2 different URLs for one page. And when indexed by Google it causes problems with our page rankings.
    I have a couple of questions–
    Does this really cause there to be 2 identical pages to be indexed by Google?

    Why are we told by GA that this is the way to track campaign efforts if it causes our page ranking to go down?

    What other method of tracking would you recommend?

    By Jz on Oct 1, 2008

  44. JZ-

    Link tagging should not be used to track internal banners or other promotions. While I don’t know if the internal link tagging will affect your page rank, I do know that it will not increase the number of pageviews. Another result of using link tagging to track internal promotions is that you will see campaigns NAMES in your reports, but those names will have 0 visits.

    Thanks for the question and I hope that helps.

    Justin

    By Justin Cutroni on Oct 1, 2008

  45. Thank you for the quick answer. How would you recommend we track internal banners.
    (We have vendors that pay for spots on these banners and they would like us to track which pages they visit on our site)

    Thanks,
    Jz

    By Jz on Oct 2, 2008

  46. JZ,

    You may want to try and capture the click by creating a “virtual pageview“. However, this can be very difficult based on the ad serving platform and your ability to add JavaScript to the ad platform.

    Hope that helps,

    Justin

    By Justin Cutroni on Oct 2, 2008

  47. Thank you so much for taking the time to write such great content about link tagging in emails. This is much more informative than what I have found elsewhere. However, I do have a couple questions that I hope you can shed some light on:

    1. Are there any ethical implications in tagging links in an HTML email? That is, does any private or identifying information get
    collected from the user that clicks on it?

    2. Will tagging a link in an HTML email cause spam filters to block the email from the user’s Inbox?

    Thanks again for sharing your expertise on the subject!

    By emsketch on Oct 8, 2008

  48. Hello,

    How do you tag email campaigns thru GA, if you are using another email campaign company that already tracks the the path. We would like to have it tracked thru GA all the way thru path of purchase (goal page)?

    By Jason Lonsgsworth on Oct 8, 2008

  49. emsketch:

    1. According to the GA terms of service you can not use GA to collect any PII. This means that adding an email address to the link tagging parameters is a big no-no.

    2. The link tagging should not trigger spam filters.

    Jason: To track your emails with GA you can tag your links using the method in this post. I’ll write something that’s more explicit for email soon.

    Thanks for the questions.

    Justin

    By Justin Cutroni on Oct 29, 2008

  50. Hi,

    I haven’t had the time to take a look at all the posts. I know someone already asked: how do you use event tracking to track banner impressions? But I didn’t really get the answer.

    Could someone give me a “for dummies”-answer pls?
    Now we use Tradedoubler to track impressions, but I’d like to use GA for everyting.

    Thanks a lot!

    Laura

    By Laura on Oct 31, 2008

  51. Laura,

    Event tracking will let you track the clicks on ads. That’s pretty much all there is to it. Depending on the implementation, the reporting will let you see which ads were clicked on and which pages people were on when they clicked on an ad.

    Unfortunately you may not be able to use event tracking to track ad clicks. It all depends on the ad serving platform and your access to the code.

    Hope that helps,

    Justin

    By Justin Cutroni on Oct 31, 2008

  52. What is your opinion regarding GA tracking vs. the good old fashioned SEO strategy of keeping links pure.

    Would google perhaps view the link with tracking as a paid link instead of organic?

    In other words, does a link take an authoritative, or equity, hit when it contains the tracking information vs. without out.

    What are your thoughts?

    By christian on Jan 28, 2009

  53. Thanks for cool information. It gave me detail about Google tracking. I was looking for information, found here. Thanks

    By Server Support on Feb 9, 2009

  54. Hi Christian,

    The link tagging parameters are only present when a visitor views a page after clicking on a tagged link. The link tagging parameters are not permanent, and therefore would never be seen by a a search engine.

    Hope that clarifies things,

    Justin

    By Justin Cutroni on Feb 11, 2009

  55. Thanks Justin, but I’m not sure I agree.

    When I take my links with a campaign tagging, I am, inessence, adding tracking to those links in the form of variables.

    When a SE spider combs my site, sees the link to whatever landing page, it also sees the appended variables on the URL.

    My concern is that anything other than a clean link *could be* perceived by the SE as a paid link since it carries tracking variables.

    Google, especially, seems focused on separating paid links from organic links when applying link pop (or equity, or whatever), and my goal is to get the search engine benefit of relevant linking, and NOT get an organic link flagged as ‘paid’

    does that makes sense?

    By christian on Feb 11, 2009

  56. Hey Christina,

    I think the part that we’re mixing up is where link tagging happens. You only add parameters to the links in your emails, banner ads, etc. You modify the destination URL that you place into your ad. You don’t actually change the URLs of any pages on the site.

    The only time the campaign parameters should ever be seen, by anyone, is when a visitor clicks on an ad with tagged links.

    SE crawlers should never see the link tagging parameters as the links with those parameters should only exist in ads.

    The only time that a SE crawler might see the query string parameters is if you post a link that contains the query string parameters on a message board, blog comment, etc.

    Hope that clarifies things,

    Justin

    By Justin Cutroni on Feb 11, 2009

  57. Hi Justin,

    When tagging a page with http://www.domain.com?langing.html?utm_source=src&utm_medium=med everything works as planned.

    However, this URL: http://www.domain.com?langing.html?utm_source=src&affid=123 causes direct referral information to be written to the _utmz cookie.

    Do you see something wrong with the second URL?

    Thanks,

    Juvaly

    By Juvaly on Mar 12, 2009

  58. Are you aware of a way to manually code the campaign variables on a landing page? We have an affiliate program that drives traffic to a unique landing page and it would be easier to code the three variables on the landing page then to have to update all of the links to the page with these? Is there a way to do that?

    By Kathleen Devilbiss on Mar 17, 2009

  59. Hi Kathlene,

    We’ve been toying with this idea, but it’s really hard to implement. We would need to reverse engineer the GA tracking code and we’ve had little luck with that.

    This is a very common request and we’ve elevated it to Google.

    Thanks for reading and thanks for the comment.

    Justin

    By Justin Cutroni on Mar 18, 2009

  60. Juvaly,

    I see a couple of things wrong with your URL. First, there are multiple question marks. You should only have one question mark to separate your path from the query string parameters and each query string parameter should be separated with a &.

    I also noticed you’re using one campaign tracking parameter. You need to use at least three (utm_campaign, utm_medium and utm_source) to track a campaign in GA.

    Hope that solves your problem!

    Justin

    By Justin Cutroni on Mar 18, 2009

  61. Hi Justin,

    When using the EpicOne link tagging tool, I produced a result difference from the one from Google’s URL builder. When “term” contained three words, Google’s tool gave me a tagged URL like this:

    &utm_term=great%2Bred%20tulips

    …whereas the EpicOne tool produces

    &utm_term=great red tulips

    What do you think? Thanks!

    By Greg Moore on Mar 25, 2009

  62. Ok, so the link to the landing page is “tagged” with the url parameters, but what if the goal page is different than the landing page? Do I have to write code to propagate those url vars from the landing page to the goal page? Or will Analytics automatically associate a successful goal with the campaign vars from the landing page, even if those vars are not present in the goal page url?

    By Robert on Apr 11, 2009

  63. Robert,

    No need to propagate the tags in all your URLs. Once the visitor lands on the site GA copies the values out of the URL and stores them in a cookie. Then all visitor actions are attributed to the value in the cookie.

    Thanks for the question.

    Justin

    By Justin Cutroni on Apr 16, 2009

  64. Greg,

    Thanks for the heads up. The Google URL builder does an encode on the white space. Not super important, but not a bad thing to replicate. We’ll try to add it in.

    We’re actually building that functionality into Analytics view. Look for it soon!

    Justin

    By Justin Cutroni on Apr 16, 2009

  65. Hi Justin,

    Do you have any info on naming conventions wrt link tagging?

    Thanks,
    Rosanne

    By Rosanne on May 19, 2009

  66. Hi Rosanne,

    I have 2 suggestions for link tagging:

    1. Be logical. Make sure your link tags can be understood by everyone in the organization.
    2. Be consistent. Don’t change the values that you use. Always use the same values for mediums and sources.

    Other than that, I like to add dates whenever possible, usually to the campaign name. I like to use simple things for medium, like “email”, “banner” and “cpc”. When it comes to email, I like to set the source to the segment of traffic receiving the email (more thoughts on email tracking here).

    Whatever you choose stick with it.

    Hope that helps and thanks for the question,

    Justin

    By Justin Cutroni on May 19, 2009

  67. Thanks for these great tips. I now have the knowledge and confidence to ditch my expensive and cumbersome email tracking system and keep all results within analytics.

    By Mark Tayar, Young Entrepreneur on Jun 18, 2009

  68. Is it possible by GA which particular user has been clicked on the particular tagged link and also how many times he clicked for particular user?

    By Bob on Apr 15, 2010

  69. @Bob,

    Technically yes, you can see which users click on links. But the GA TOS clearly states that you can not track any personally identifiable information in Google Analytics. Plus, tracking individual users will generate a TON of data, which is not particularly trackable. That’s why I don’t get into tracking individual users.

    Thanks for the comment,

    Justin

    By Justin Cutroni on Apr 19, 2010

  70. This question may already be answered in this thread… but it is too huge to scour through at the moment… I am wondering if I lose tracking accuracy in this situation…

    I post banner ads on websites such as http://www.racerxonline.com , and I add the tracking codes to the link back to my home page. I get tracking stats under the campaign tracking in GA, but I still get stats showing up in the referral category from racerxonline.com . Do I combine these two figures to make it accurate? Or are some of the figures being created on both ends from the same visitors?

    By Mike on Apr 19, 2010

  71. @Mike: It could be that some of the banners are not tagged with the link tagging parameters. Use the referring sites report to identify which pages on the referring domain have links back to your site. It could also be that, for some reason, the links are getting stripped off. And finally, is it possible that there are other, non-banner, links on the referring site?

    In a perfect world all of the traffic should appear from the banners.

    Hope that helps!

    By Justin Cutroni on Apr 20, 2010

  72. Great post! One more tip, if you set your medium to cpc or ppc then those keywords will appear in the ‘paid’ section of your keyword report.

    Our tool, Campaignsync, can do all this tagging automatically to your Microsoft adCenter or Yahoo! Search Marketing campaigns. It’s free so try it out and let us know what you think.

    By Campaignsync on Apr 23, 2010

  73. @Mike: It could be that some of the banners are not tagged with the link tagging parameters. Use the referring sites report to identify which pages on the referring domain have links back to your site. It could also be that, for some reason, the links are getting stripped off. And finally, is it possible that there are other, non-banner, links on the referring site?

    By منتديات on Jun 24, 2010

  1. 29 Trackback(s)

  2. Nov 10, 2006: this just in » Google Analytics Campaign Tracking Pt. 1: Link Tagging
  3. Nov 10, 2006: Analytics Talk » Google Analytics Campaign Tracking Pt. 2: The EpikOne Link Tagging Tool
  4. Nov 14, 2006: Analytics Talk » Google Analytics Campaign Tracking Pt. 0: An Overview
  5. Mar 4, 2007: Analytics Talk » Google Analytics Campaign Tracking Part 3: Reports and Analysis
  6. Mar 5, 2007: Analytics Talk » Google Analytics Campaign Tracking Pt. 3: Reports and Analysis
  7. Apr 5, 2007: Confluence: Content Design Univ
  8. Apr 6, 2007: Jeff’s Blog » Blog Archive » Tracking Adwords and other ppc click results
  9. Apr 7, 2007: links for 2007-04-08 » eWhisper.net
  10. Jun 8, 2007: Web Developer and Design Reference Book
  11. Jul 11, 2007: Analytics Talk » Email Optimization: A Quick Tip
  12. Jul 17, 2007: Analytics Talk » Segmenting Visitor Loyalty Reports in GA
  13. Oct 7, 2007: Analytics Talk » Blog Archive » Give Me What I Want and I’ll Do What You Ask
  14. Oct 29, 2007: Analytics Talk » Blog Archive » Integrating Google Analytics With a CRM
  15. Dec 14, 2007: Analytics Talk » Blog Archive » How Does Google Analytics Track Conversion Referrals?
  16. Aug 29, 2008: Library Analytics (Part 7) « OUseful.Info, the blog…
  17. Oct 30, 2008: Google Analytics Profiles and Filters Part 1: The Must-Haves » Closed Loop Marketing Blog
  18. May 20, 2009: Analytics Talk » Blog Archive » How Google Analytics Tracks ‘Bookmark’ Visits
  19. Jun 15, 2009: How Google Analytics Tracks ‘Bookmark’ Visits | rapid-DEV.net
  20. Jun 15, 2009: Tracking Email with Google Analytics | rapid-DEV.net
  21. Jun 17, 2009: Using Google Analytics To Track Yahoo & Adcenter Paid Keywords
  22. Aug 22, 2009: Google Analytics Link 之標籤(Tagging) « SEO study 搜尋引擎優化學習
  23. Sep 30, 2009: Google Base/Produktsuche Traffic in Google Analytics auswerten | Suchmaschinenoptimierung - Internet Marketing
  24. Nov 12, 2009: “Campaign” Tracking With Google Analytics at Actually…
  25. Nov 13, 2009: “Campaign” Tracking With Google Analytics « JISCPress
  26. Dec 15, 2009: Analytics Talk » Blog Archive » Google Analytics Campaign Tracking Pt. 1: Link Tagging « Real Life Hitch
  27. Dec 22, 2009: 网站分析常见误区:Google Analytics 如何跟踪从“ Bookmark” 来的访问 | SEM WATCH
  28. Jan 26, 2010: How To Track Paid Search Traffic from Adcenter and Yahoo Search Marketing In Google Analytics | Ludex Marketing Blog
  29. Mar 31, 2010: Social Media Metrics | Geoff Kenyon
  30. Jun 18, 2010: Mass Traffic Overload SEO and Traffic Generation Articles » SEO and Website Traffic Technique Articles…

Post a Comment