<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Analytics Talk&#187; Tracking posts &#8211; Analytics Talk</title>
	<atom:link href="http://cutroni.com/blog/category/tracking/feed/" rel="self" type="application/rss+xml" />
	<link>http://cutroni.com/blog</link>
	<description></description>
	<lastBuildDate>Mon, 19 Jul 2010 21:01:22 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
	<atom:link rel='hub' href='http://cutroni.com/blog/?pushpress=hub'/>
		<item>
		<title>Faster, Better, Stronger. The GA Async Tracking Code</title>
		<link>http://cutroni.com/blog/2010/04/19/faster-better-stronger-the-ga-async-tracking-code/</link>
		<comments>http://cutroni.com/blog/2010/04/19/faster-better-stronger-the-ga-async-tracking-code/#comments</comments>
		<pubDate>Mon, 19 Apr 2010 21:23:28 +0000</pubDate>
		<dc:creator>Justin Cutroni</dc:creator>
				<category><![CDATA[Tracking]]></category>

		<guid isPermaLink="false">http://cutroni.com/blog/?p=1468</guid>
		<description><![CDATA[You may have heard that Google will begin to use site speed when calculating web rankings. This generated a lot of buzz, but according to Matt Cutts, fewer than 1% of search queries are affected by the site speed signal in our implementation and the signal for site speed only applies for visitors searching in [...]<p><a href="http://cutroni.com/blog/2010/04/19/faster-better-stronger-the-ga-async-tracking-code/">Faster, Better, Stronger. The GA Async Tracking Code</a> is a post from: <a href="http://cutroni.com/blog">Analytics Talk by Justin Cutroni</a></p>
]]></description>
			<content:encoded><![CDATA[<p>You may have heard that Google will begin to use <a href="http://googlewebmastercentral.blogspot.com/2010/04/using-site-speed-in-web-search-ranking.html" target="_blank">site speed when calculating web rankings</a>. This generated a lot of buzz, but according to <a href="http://www.mattcutts.com/blog/">Matt Cutts</a>, </p>
<blockquote><p>fewer than 1% of search queries are affected by the site speed signal in our implementation and the signal for site speed only applies for visitors searching in English on Google.com at this point.&#8221;</p></blockquote>
<p>This may be the beginning of Google&#8217;s use of site speed. It&#8217;s probably a good idea to think about speed when designing your site.</p>
<p><strong>How GA can Slow Your Site</strong></p>
<p>One thing that can potentially slow your site down is the Google Analytics tracking code. Specifically, the <code>ga.js</code> library and how the browser loads the file.</p>
<p><img class="alignright size-medium wp-image-1475" title="You could wait for ga.js to load!" src="http://cutroni.com/blog/wp-content/uploads/waiting-199x300.jpg" alt="" width="199" height="300" /></p>
<p>When a browser renders a page it literally starts starts to display the HTML from the top of the page and moves to the botton. When it hits a JavaScript file, like <code>ga.js</code>, it requests the file from the remote server.</p>
<p>Then it waits.</p>
<p>And waits.</p>
<p>And waits.</p>
<p>Once the file has been pulled into the browser it continues to process the HTML.</p>
<p>You can see the issue here, the browser could wait a long time for the JavaScript file depending on the visitors proximity to the server, the visitor&#8217;s bandwidth, and a bunch of other factors most of which you can&#8217;t control.  Waiting for a page to render is a bad user experience. I know I don&#8217;t like to wait!</p>
<p>There&#8217;s a great example of how a remote file can make the browser slow down on the <a href="http://stevesouders.com/cuzillion/?ex=10008&amp;title=Scripts+Block+Downloads" target="_blank">High Performance website blog</a>.</p>
<p>Google tries to mitigate load-time issues by geo-loadbalancing <code>ga.js</code>, so the visitor&#8217;s browser will automatically contact the closest data center to load the <code>ga.js</code> faster.</p>
<p>It&#8217;s also best to place the <code>ga.js</code> at the bottom of your pages just in case there is an issue with the communication between the data center and the visitor&#8217;s browser. By placing the <code>ga.js</code> at the bottom of the page all of the content has already rendered, so the visitor won&#8217;t experience a blank or partially loaded pags.</p>
<p>While placing the GATC at the bottom of the page can mitigate some issues it can cause others.</p>
<p>First, it is possible for visitors to navigate away from the site before data is sent to Google Analytics. This leads to missing data.</p>
<p>Second, if you need to do any advanced tracking, like ecommerce or events, you may need to move the <code>ga.js</code> to the top of the page thus negating the benefit from putting it at the bottom of the page. This can also complicate your implementaiton because some pages may have the code at the top of the page and some might have the code at the bottom of the page which is a maintenance nightmare.</p>
<p>Using the new async code can help mitigate both of these problems.</p>
<p><strong>How the Async Code Helps</strong></p>
<p>First, The asyncronous version of the tracking code utilizes <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/scripting-1.html#scripting-1" target="_blank"> HTML 5 and the modern browser&#8217;s ability to load files asyncronously</a>. This means that the browser can load files like <code>ga.js</code> while it continues to render the page for the visitor.</p>
<p>Second, the async code let&#8217;s us send data to Google Analytics before the <code>ga.js</code> has loaded in the browser. Technically we&#8217;re not sending the data to Google, but we are executing the commands that generate the data. The broser just holds the commands until the <code>ga.js</code> has completely loaded. Then the commands are executed (in the order in which they were added) and the data is sent to Google.</p>
<p>In the old days (like last year) we had to wait for <code>ga.js</code> to load before we could call any GA code. Not any more.</p>
<p>So the Async code is a good thing.</p>
<p><img class="aligncenter size-medium wp-image-1488" title="Martha likes the Google Analytics Async Code" src="http://cutroni.com/blog/wp-content/uploads/martha-async-300x251.jpg" alt="" width="300" height="251" /></p>
<p>The big question is, <em>should you use the async tracking code?</em></p>
<p>Well, if you&#8217;re concerned that Google Analytics is slowing down your site, and that it may be impacting your search rankings, then yes, use the async code. There are a number of free tools that you can use to test how long it takes <code>ga.js</code> to load on your site. (<a href="http://developer.yahoo.com/yslow/">YSlow</a>, <a href="http://code.google.com/speed/page-speed/download.html">Page Speed</a>, etc.) Use them to determine if GA is slowing down your site.</p>
<p>If you decide to use the async version of the code there are a few things you should know. </p>
<p>Using the async code is slightly different than using the standard tracking code. Let&#8217;s look:</p>
<p><code>&lt; script&gt;<br />
//<br />
// This section creates the queue<br />
//<br />
var _gaq = _gaq || [];<br />
_gaq.push(['_setAccount', 'UA-XXXXX-X']);<br />
_gaq.push(['_trackPageview']);</p>
<p>//<br />
// This section calls the ga.js<br />
//<br />
(function() {<br />
var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;<br />
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';<br />
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);<br />
})();<br />
&lt;/ script&gt;<br />
<!-- All sorts of really cool site content here... --></code></p>
<p>The async code can appear anywhere in a page. But it&#8217;s best to place it at the immediately after the opening BODY tag. This let&#8217;s you add commands to the queue as soon as the page starts to render.</p>
<p>Some of the GA documentaion states that you can place the code in the HEAD tag. But this can cause some JavaScript issues with IE6. If you have a lot of visitors that use IE6 don&#8217;t put the code in the HEAD tag.</p>
<p>If you&#8217;re still leary about putting the code at the top of the page you can split the tracking code into two sections. You can place the first part of the code at the top of the page and the second part, the calls the <code>ga.js</code>, at the bottom of the page.</p>
<p>While this let&#8217;s you add commands to the queue immediately it is still possible to miss some GA data becayse the <code>ga.js</code> will be the last thing the browser requests. But the choice is up to you.</p>
<p><strong>How the Code Works</strong></p>
<p>Digging into the code a bit more, the first thing you&#8217;ll notice is the call for the <code>ga.js</code> is the second part of the code. This is the opposite of the standard tracking code. The async tracking code begins by creating the queue to store commands. Then the tracking code calls Google&#8217;s servers for the <code>ga.js</code> file. </p>
<p>The great thing about the queue of commands is you can add things to the queue whenever you want, even if the <code>ga.js</code> has not finished loading. This is what makes it possible to add GA commands at the top of a page.</p>
<p>The second section of code is the request to Google&#8217;s servers for the <code>ga.js</code>. It&#8217;s the exact same <code>ga.js</code> that&#8217;s used in the standard tracking code, it&#8217;s just pulled into the browser in a different way. Notice the  <strong>ga.async=true</strong> part of the code? That&#8217;s the part that tells the browser it should load the code asyncronously. The browser not execute any commands in the queue until after the <code>ga.js</code> has loaded.</p>
<p>If you&#8217;ve got a basic site then all you need to do is add the async code to your pages and you&#8217;re good to go. You don&#8217;t need to worry about adding items to the que, etc.</p>
<p>But if you&#8217;re doing any advanced tracking, like virtual pageviews, events or ecommerce you need to know how to add items to the queue.</p>
<p><strong>How to Add Items to the Queue</strong></p>
<p>Adding items to the queue can be done a number of different ways. The easiest way is to &#8220;push&#8221; things onto the queue. This is done with the push command, as shown below.</p>
<p><code>_gaq.push(['_setAccount', 'UA-XXXXX-X']);<br />
_gaq.push(['_trackPageview']);</code></p>
<p>If you wanted to add an event to the click of a link you would push the command on to the queue like this:</p>
<p><code>&lt; a href="onClick='_gaq.push('cat','act','label');'"&gt;go red sox&lt; /a&gt;</code></p>
<p>Or, to create a virtual pageview you could push the command onto the queue like this:</p>
<p><code>&lt; a href="onClick='_gaq.push('_trackPageview','/virtual/go-red-sox');'"&gt;go red sox&lt; /a&gt;</code></p>
<p>You can also add mulitple commands to the queue at a time. But this is where things start to get technical, and I&#8217;m not going to go there :)</p>
<p>How you implement the code depends on your site, the commands you want to add and how much JS you know. To learn more about how to add commands check out the <a href="http://code.google.com/apis/analytics/docs/tracking/asyncUsageGuide.html">GA Code site</a>.</p>
<p><strong>Switching to the Async Code</strong></p>
<p>The complexity of migrating to the async tracking code depends on your site. If you&#8217;re not using any of the advanced GA features then migration can be as simple as swapping the tags.</p>
<p>But, if you are using advanced features, you&#8217;ll need to update all of the GA code on your site. Remeber, all the standard Google Analytics functionality in the <code>ga.js</code> exists in the async code. You just need to replicate your existing code in the async format. You can find an overview of the async code (written in nerd) as well as code examples, on the <a href="http://code.google.com/apis/analytics/docs/tracking/asyncTracking.html" target="_blank">Google Code site</a>.</p>
<p>Obviously the migration effort depends on the complexity of your implementation. But if you take your time and document your existing GA code and test your implementaiton thoroughly everything should go smoothly.</p>
<p>Have you tried the new async code? Got an experience you want to share? Leave a comment!</p>
<p><a href="http://cutroni.com/blog/2010/04/19/faster-better-stronger-the-ga-async-tracking-code/">Faster, Better, Stronger. The GA Async Tracking Code</a> is a post from: <a href="http://cutroni.com/blog">Analytics Talk by Justin Cutroni</a></p>

<div class="sociable">

<ul>
	<li class="sociablefirst"><a rel="nofollow"  target="_blank" href="http://twitter.com/home?status=Faster%2C%20Better%2C%20Stronger.%20The%20GA%20Async%20Tracking%20Code%20-%20http%3A%2F%2Fcutroni.com%2Fblog%2F2010%2F04%2F19%2Ffaster-better-stronger-the-ga-async-tracking-code%2F" title="Twitter"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/twitter.png" title="Twitter" alt="Twitter" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2010%2F04%2F19%2Ffaster-better-stronger-the-ga-async-tracking-code%2F&amp;title=Faster%2C%20Better%2C%20Stronger.%20The%20GA%20Async%20Tracking%20Code" title="StumbleUpon"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/stumbleupon.png" title="StumbleUpon" alt="StumbleUpon" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fcutroni.com%2Fblog%2F2010%2F04%2F19%2Ffaster-better-stronger-the-ga-async-tracking-code%2F&amp;title=Faster%2C%20Better%2C%20Stronger.%20The%20GA%20Async%20Tracking%20Code&amp;bodytext=You%20may%20have%20heard%20that%20Google%20will%20begin%20to%20use%20site%20speed%20when%20calculating%20web%20rankings.%20This%20generated%20a%20lot%20of%20buzz%2C%20but%20according%20to%20Matt%20Cutts%2C%20%0D%0A%0D%0Afewer%20than%201%25%20of%20search%20queries%20are%20affected%20by%20the%20site%20speed%20signal%20in%20our%20implementation%20and%20" title="Digg"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/digg.png" title="Digg" alt="Digg" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://delicious.com/post?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2010%2F04%2F19%2Ffaster-better-stronger-the-ga-async-tracking-code%2F&amp;title=Faster%2C%20Better%2C%20Stronger.%20The%20GA%20Async%20Tracking%20Code&amp;notes=You%20may%20have%20heard%20that%20Google%20will%20begin%20to%20use%20site%20speed%20when%20calculating%20web%20rankings.%20This%20generated%20a%20lot%20of%20buzz%2C%20but%20according%20to%20Matt%20Cutts%2C%20%0D%0A%0D%0Afewer%20than%201%25%20of%20search%20queries%20are%20affected%20by%20the%20site%20speed%20signal%20in%20our%20implementation%20and%20" title="del.icio.us"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/delicious.png" title="del.icio.us" alt="del.icio.us" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.facebook.com/share.php?u=http%3A%2F%2Fcutroni.com%2Fblog%2F2010%2F04%2F19%2Ffaster-better-stronger-the-ga-async-tracking-code%2F&amp;t=Faster%2C%20Better%2C%20Stronger.%20The%20GA%20Async%20Tracking%20Code" title="Facebook"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/facebook.png" title="Facebook" alt="Facebook" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.linkedin.com/shareArticle?mini=true&amp;url=http%3A%2F%2Fcutroni.com%2Fblog%2F2010%2F04%2F19%2Ffaster-better-stronger-the-ga-async-tracking-code%2F&amp;title=Faster%2C%20Better%2C%20Stronger.%20The%20GA%20Async%20Tracking%20Code&amp;source=Analytics+Talk+&amp;summary=You%20may%20have%20heard%20that%20Google%20will%20begin%20to%20use%20site%20speed%20when%20calculating%20web%20rankings.%20This%20generated%20a%20lot%20of%20buzz%2C%20but%20according%20to%20Matt%20Cutts%2C%20%0D%0A%0D%0Afewer%20than%201%25%20of%20search%20queries%20are%20affected%20by%20the%20site%20speed%20signal%20in%20our%20implementation%20and%20" title="LinkedIn"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/linkedin.png" title="LinkedIn" alt="LinkedIn" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.friendfeed.com/share?title=Faster%2C%20Better%2C%20Stronger.%20The%20GA%20Async%20Tracking%20Code&amp;link=http%3A%2F%2Fcutroni.com%2Fblog%2F2010%2F04%2F19%2Ffaster-better-stronger-the-ga-async-tracking-code%2F" title="FriendFeed"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/friendfeed.png" title="FriendFeed" alt="FriendFeed" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://sphinn.com/index.php?c=post&amp;m=submit&amp;link=http%3A%2F%2Fcutroni.com%2Fblog%2F2010%2F04%2F19%2Ffaster-better-stronger-the-ga-async-tracking-code%2F" title="Sphinn"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/sphinn.png" title="Sphinn" alt="Sphinn" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.google.com/bookmarks/mark?op=edit&amp;bkmk=http%3A%2F%2Fcutroni.com%2Fblog%2F2010%2F04%2F19%2Ffaster-better-stronger-the-ga-async-tracking-code%2F&amp;title=Faster%2C%20Better%2C%20Stronger.%20The%20GA%20Async%20Tracking%20Code&amp;annotation=You%20may%20have%20heard%20that%20Google%20will%20begin%20to%20use%20site%20speed%20when%20calculating%20web%20rankings.%20This%20generated%20a%20lot%20of%20buzz%2C%20but%20according%20to%20Matt%20Cutts%2C%20%0D%0A%0D%0Afewer%20than%201%25%20of%20search%20queries%20are%20affected%20by%20the%20site%20speed%20signal%20in%20our%20implementation%20and%20" title="Google Bookmarks"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/googlebookmark.png" title="Google Bookmarks" alt="Google Bookmarks" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://reddit.com/submit?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2010%2F04%2F19%2Ffaster-better-stronger-the-ga-async-tracking-code%2F&amp;title=Faster%2C%20Better%2C%20Stronger.%20The%20GA%20Async%20Tracking%20Code" title="Reddit"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/reddit.png" title="Reddit" alt="Reddit" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="mailto:?subject=Faster%2C%20Better%2C%20Stronger.%20The%20GA%20Async%20Tracking%20Code&amp;body=http%3A%2F%2Fcutroni.com%2Fblog%2F2010%2F04%2F19%2Ffaster-better-stronger-the-ga-async-tracking-code%2F" title="email"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/email_link.png" title="email" alt="email" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://technorati.com/faves?add=http%3A%2F%2Fcutroni.com%2Fblog%2F2010%2F04%2F19%2Ffaster-better-stronger-the-ga-async-tracking-code%2F" title="Technorati"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/technorati.png" title="Technorati" alt="Technorati" /></a></li>
	<li class="sociablelast"><a rel="nofollow"  target="_blank" href="http://buzz.yahoo.com/submit/?submitUrl=http%3A%2F%2Fcutroni.com%2Fblog%2F2010%2F04%2F19%2Ffaster-better-stronger-the-ga-async-tracking-code%2F&amp;submitHeadline=Faster%2C%20Better%2C%20Stronger.%20The%20GA%20Async%20Tracking%20Code&amp;submitSummary=You%20may%20have%20heard%20that%20Google%20will%20begin%20to%20use%20site%20speed%20when%20calculating%20web%20rankings.%20This%20generated%20a%20lot%20of%20buzz%2C%20but%20according%20to%20Matt%20Cutts%2C%20%0D%0A%0D%0Afewer%20than%201%25%20of%20search%20queries%20are%20affected%20by%20the%20site%20speed%20signal%20in%20our%20implementation%20and%20&amp;submitCategory=science&amp;submitAssetType=text" title="Yahoo! Buzz"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/yahoobuzz.png" title="Yahoo! Buzz" alt="Yahoo! Buzz" /></a></li>
</ul>
</div>
]]></content:encoded>
			<wfw:commentRss>http://cutroni.com/blog/2010/04/19/faster-better-stronger-the-ga-async-tracking-code/feed/</wfw:commentRss>
		<slash:comments>17</slash:comments>
		</item>
		<item>
		<title>Tracking Internal Campaigns with Google Analytics</title>
		<link>http://cutroni.com/blog/2010/03/30/tracking-internal-campaigns-with-google-analytics/</link>
		<comments>http://cutroni.com/blog/2010/03/30/tracking-internal-campaigns-with-google-analytics/#comments</comments>
		<pubDate>Tue, 30 Mar 2010 09:00:34 +0000</pubDate>
		<dc:creator>Justin Cutroni</dc:creator>
				<category><![CDATA[Analysis]]></category>
		<category><![CDATA[Campaign Tracking]]></category>
		<category><![CDATA[Tracking]]></category>
		<category><![CDATA[site search]]></category>

		<guid isPermaLink="false">http://cutroni.com/blog/?p=1356</guid>
		<description><![CDATA[Internal campaigns are marketing efforts that are run on your site and promote your products and services. Here&#8217;s an example from the Boton Red Sox site. They&#8217;re using ads on the homepage to promote ticket sales. Companies should track how people react to these campaigns and which ones are most successful. But what&#8217;s the best [...]<p><a href="http://cutroni.com/blog/2010/03/30/tracking-internal-campaigns-with-google-analytics/">Tracking Internal Campaigns with Google Analytics</a> is a post from: <a href="http://cutroni.com/blog">Analytics Talk by Justin Cutroni</a></p>
]]></description>
			<content:encoded><![CDATA[<p>Internal campaigns are marketing efforts that are run on your site and promote your products and services. Here&#8217;s an example from the Boton Red Sox site. They&#8217;re using ads on the homepage to promote ticket sales.</p>
<p><a href="http://cutroni.com/blog/wp-content/uploads/2010/03/Picture-1.png"><img class="aligncenter size-full wp-image-1383" title="Internal ticket sale campaign on RedSox.com" src="http://cutroni.com/blog/wp-content/uploads/2010/03/Picture-1.png" alt="" width="738" height="488" /></a></p>
<p>Companies should track how people react to these campaigns and which ones are most successful. But what&#8217;s the best way to do this with Google Analytics?</p>
<p>Some people use the standard campaign tracking to track internal campaigns. THIS IS INCORRECT AND SHOULD NEVER BE DONE.  Using the standard campaign tracking for internal campaigns will cause problems with your source data. So don&#8217;t do it!</p>
<p>There are a few correct ways to track internal campaigns. You could use <a href="http://cutroni.com/blog/2007/10/16/event-tracking-pt-1-overview-data-model/">Event Tracking</a>, <a href="http://cutroni.com/blog/2009/10/20/google-analytics-custom-variables-overview/">Custom Variables</a> or Virtual Pageviews. But I like to use GA&#8217;s internal campaign tracking tool.</p>
<p>What? You&#8217;ve never seen or used the GA&#8217;s internal campaign tracker? It&#8217;s in the profile settings and it&#8217;s called Site Search tracking! Did I fool you ;)</p>
<p>Site Search can easily be configured to track internal campaigns. Let&#8217;s walk through the steps to set it up and then the data and analysis.</p>
<h2>Step 1: Create a New Profile</h2>
<p>Because we&#8217;re using Site Search for an unintended purpose it&#8217;s best to configure these settings on a new profile. It&#8217;s not possible to use Site Search for both tracking internal campaigns and internal site search within the same profile. You need to have a separate profile to track internal campaigns.</p>
<p><a href="http://cutroni.com/blog/wp-content/uploads/2010/03/Picture-2.png"><img class="aligncenter size-full wp-image-1384" title="New Google Analytics Profile for Internal Campaigns" src="http://cutroni.com/blog/wp-content/uploads/2010/03/Picture-2.png" alt="" width="392" height="69" /></a></p>
<h2>Step 2: Tag your Internal Campaigns</h2>
<p>Once you&#8217;ve created your new profile it&#8217;s time to tag your internal campaigns. Internal campaigns need to be tagged in a similar manner to external campaigns: you need to add query string parameterrs to your internal ad.</p>
<p>However, unlike external campaigns you do not use the standard link tagging parameters (<code>utm_campaign</code>, <code>utm_medium</code>, etc.). You get to make up your own parameters!</p>
<p>You can use one or two parameters for internal campaign tracking and you can name then anything you want. The reason you can use one or two parameters is that GA&#8217;s site search configuration uses two parameters, one for the search phrase and one for the search category.</p>
<p>Whatever you choose, make sure the parameters are not used for anything else.</p>
<p><em>TIP: Check your Top Content report for a complete list of your site&#8217;s query string parameters. Verify that the parameters you create are NOT in this list.</em></p>
<p>For the sake of this post I&#8217;ll use the parameter <code>icn</code> (shor for internal campaign name). This parameter will holds the name of the internal campaign. I&#8217;m going to use the following format for the value of the campaign name parameter</p>
<p><code>icn=[internal-campaign-name]</code></p>
<p>I mentioned that you can use two paramters. You don&#8217;t need to use two, but GA&#8217;s site search can be confiugured to track the internal site search phrase and a site search category. We&#8217;ll use the category paramter to track the internal campaign name.</p>
<p>I&#8217;m going to name the second paraeter <code>ici</code> (short for internal campaign info). Again make sure the parameter you&#8217;re using does not already exist. This second parameter let&#8217;s me collect details about the ad the visitor clicked on and the location of the ad.</p>
<p>Here&#8217;s a basic format:</p>
<p><code>ici=[ad-creative]_[location-on-the-page]</code></p>
<p>You can see that I&#8217;m stuffing a lot of information into the parameter. You can put whatever you want and GA will gladly suck it in. By adding more information we&#8217;ll get a granluar view of how the internal campaigns perform and which locations and variations lead to tbe most conversions.</p>
<p>If you don&#8217;t have different types of internal ads, or just don&#8217;t care about this level of detail, then you can ignore the add internal campaign info parameter. It blank, it&#8217;s up to you!</p>
<p>Now you need to define the values for all the ads. Thic can get messy if you&#8217;re running a lot of internal campaign. But you can do it, just be organized! Use a spreadsheet to keep track of all the values you use.</p>
<p>Once you&#8217;ve got al your parameters it&#8217;s time to tag your links. The exact process depends on your site. You may need to change static links, like this:</p>
<p>&lt; a href=&#8221;/internal-page.php?icn=2010-spring-sale&amp;ici=stubs_home-roller &gt;</p>
<p>Or if you have complicate flash ads you may need to get inside the Flash code. It depends on your site.</p>
<p>The bottom line is when somone clicks on an internal ad you want to see your internal campaign parameter on the next page. If you don&#8217;t see the parameter in the URL then you did something wrong.</p>
<p>You can use the sample spread sheet below to track the different parameters you use for your internal campaigns. The spread sheet also has a formula in column D to automatically add the parameters to your URLs.</p>
<p>NOTE: There is an iFrame in this post. If you can not see it, you can view the original post <a href="http://cutroni.com/blog/2010/03/29/tracking-internal-campaigns-with-google-analytics">here</a> or view the Google Spreadsheet <a href="http://spreadsheets.google.com/ccc?key=0AnmzEWCHMzUPdFpuRXJkOTZseW5KQVhRTUJmRUJWZlE&amp;hl=en">here</a>.</p>
<p>Once youe&#8217;ve got the parameters added to your links it&#8217;s itme to configure the Site Search settings.</p>
<h2>Step 3: Configure Site Search Settings</h2>
<p>Remeber, we&#8217;re configuring these settings on a new profile so we don&#8217;t break the site search in our main reporting profile.</p>
<p>Site search has three settings. First, turn site search on.</p>
<p>Next, tell GA the name of the paramter that holds the site search phrase (in this case it&#8217;s out internal campaign name) by adding the parameter to the &#8216;Query Parameter&#8217; filed.</p>
<p>Next, choose Strip Query String Parameters. This setting will remove the parameter from the URL after GA processes the data. This is a good idea because it reduces duplicate pages in your top content reports.</p>
<p><em>TIP: You probably want to exclude your internal campaign name parameter, and internal campaign information parameter, from your other profiles. It can really mess up your pageview data.</em></p>
<p>If you&#8217;re using an internal campaign information parameter configure the Site Search Category settings the same way. Just make sure you use your internal campaign info parameter in the &#8216;Category Parameter&#8217; setting.</p>
<p>Here&#8217;s how the settings look using the parameters from my example:</p>
<p><a href="http://cutroni.com/blog/wp-content/uploads/2010/03/Picture-3.png"><img class="aligncenter size-full wp-image-1387" title="Google Analytics Internal Site Search settings" src="http://cutroni.com/blog/wp-content/uploads/2010/03/Picture-3.png" alt="" width="497" height="327" /></a></p>
<p>That&#8217;s it! Let&#8217;s look at the data.</p>
<h2>The Reports</h2>
<p>Let&#8217;s start by answering a simple question: do people who respond to internal camapigns convert more or less than those that do not respond to internal camapigns? To answer this question use the Content &gt; Site Search &gt; Usage report. Here we can see that there were only eight visits that clicked an internal campaign. Sad! But it&#8217;s just test data.</p>
<p><img class="aligncenter size-full wp-image-1397" title="Success of Internal Campaigns" src="http://cutroni.com/blog/wp-content/uploads/2010/03/Picture-8.png" alt="" width="604" height="240" /></p>
<p>Now let&#8217;s drill deeper ad identify which inernal camapigns are most effective. Use the Content &gt; Site Search &gt; Search Terms report. Rather than search phrases this report contains the names of all internal campaigns. Again, what was the response to the campaign? Was it worth the effort? Don&#8217;t forget to check the Goals tab and the Ecommerce tabs (if applicable) to measure outcomes!</p>
<p><img class="aligncenter size-full wp-image-1398" title="Internal campaign in the Google Analytics Search Terms report." src="http://cutroni.com/blog/wp-content/uploads/2010/03/Picture-9.png" alt="" width="619" height="237" /></p>
<p>But let&#8217;s drill deeper to understand which ads within those campaigns are working. Click on a campaign name and choose Category from the Analyze drop down.</p>
<p><img class="aligncenter size-full wp-image-1399" title="Analyze a given internal campaign by the Category data" src="http://cutroni.com/blog/wp-content/uploads/2010/03/Picture-10.png" alt="" width="491" height="135" /></p>
<p>Now we&#8217;re looking at all of the information that we put into the <code>ici</code> query string parameter for this particular campaign name. If we had multiple internal ads we&#8217;d be able to differentiate ad placements and creative variations.</p>
<p><img class="aligncenter size-full wp-image-1422" title="Segmenting an internal campaign in Google Analytics." src="http://cutroni.com/blog/wp-content/uploads/2010/03/Picture-11.png" alt="" width="577" height="105" /></p>
<p>Don&#8217;t forget to use the Goals and Ecommerce tabs to measure outcomes! This is what most people want to know: did internal campaigns, and specifically which internal campaigns, generated <strong>revenue and conversions</strong>?</p>
<p>But we can do more. Now change to the Content &gt; Site Search &gt; Start Pages report. Now you can see which page people were on when they click on an internal ad. Again, more insight into where visitors responded to an internal campaign.</p>
<p><img class="aligncenter size-full wp-image-1415" title="How to identify start pages for Internal Campaigns." src="http://cutroni.com/blog/wp-content/uploads/2010/03/Picture-13.png" alt="" width="489" height="97" /></p>
<p>And for all those marketing folks that are so concerned with internal campaigns, how about creating a nice custom report and automating the delivery or, better yet, use the Custom Report Sharing feature to share this report with others. People will love this because you can change the wording so it does not say Site Search it says Internal Campaigns Report.</p>
<p>But wait, there&#8217;s more! What about using a secondary dimension to view the external marketing campaigns (or sources, or mediums) that drive visitor to react to internal campaigns. Perhaps the extrnal creative has some influence over how visitors react to the internal campaign creative. The data isn&#8217;t so hot in the image below, but you get the idea.</p>
<p><img class="aligncenter size-full wp-image-1412" title="Use a secondary dimension to view external campaigns for each internal campaign." src="http://cutroni.com/blog/wp-content/uploads/2010/03/Picture-12.png" alt="" width="602" height="73" /></p>
<p>And finally, the ultimate in analysis, internal campaign attribution. We can use the Search Term Refinement feature if visitors click on multiple internal campaigns. Google Analytics will track all subsequent site searches, but in our case follow up site searches are actually additional internal campaigns that the visitor responded to. Honestly, I have never found any insights from this type of analysis, but you can do it if you want!</p>
<p>Ok, I&#8217;ve officially entered nerdville.</p>
<p>I think you get the idea. By adding all this data you can do many different kinds of segmentation and analysis. More than enough to understand the behavior of your site visitors and how your internal campaigns perform.</p>
<p>Last but not least, I&#8217;ll mention that you can track internal campaigns using events and custom variables. But both of those solutions require coding. And that requires working with IT. Using Site Search, in most cases, will not require any code changes to your site.</p>
<p><a href="http://cutroni.com/blog/2010/03/30/tracking-internal-campaigns-with-google-analytics/">Tracking Internal Campaigns with Google Analytics</a> is a post from: <a href="http://cutroni.com/blog">Analytics Talk by Justin Cutroni</a></p>

<div class="sociable">

<ul>
	<li class="sociablefirst"><a rel="nofollow"  target="_blank" href="http://twitter.com/home?status=Tracking%20Internal%20Campaigns%20with%20Google%20Analytics%20%20-%20http%3A%2F%2Fcutroni.com%2Fblog%2F2010%2F03%2F30%2Ftracking-internal-campaigns-with-google-analytics%2F" title="Twitter"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/twitter.png" title="Twitter" alt="Twitter" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2010%2F03%2F30%2Ftracking-internal-campaigns-with-google-analytics%2F&amp;title=Tracking%20Internal%20Campaigns%20with%20Google%20Analytics%20" title="StumbleUpon"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/stumbleupon.png" title="StumbleUpon" alt="StumbleUpon" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fcutroni.com%2Fblog%2F2010%2F03%2F30%2Ftracking-internal-campaigns-with-google-analytics%2F&amp;title=Tracking%20Internal%20Campaigns%20with%20Google%20Analytics%20&amp;bodytext=Internal%20campaigns%20are%20marketing%20efforts%20that%20are%20run%20on%20your%20site%20and%20promote%20your%20products%20and%20services.%20Here%27s%20an%20example%20from%20the%20Boton%20Red%20Sox%20site.%20They%27re%20using%20ads%20on%20the%20homepage%20to%20promote%20ticket%20sales.%0D%0A%0D%0A%0D%0A%0D%0ACompanies%20should%20track%20how%20peo" title="Digg"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/digg.png" title="Digg" alt="Digg" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://delicious.com/post?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2010%2F03%2F30%2Ftracking-internal-campaigns-with-google-analytics%2F&amp;title=Tracking%20Internal%20Campaigns%20with%20Google%20Analytics%20&amp;notes=Internal%20campaigns%20are%20marketing%20efforts%20that%20are%20run%20on%20your%20site%20and%20promote%20your%20products%20and%20services.%20Here%27s%20an%20example%20from%20the%20Boton%20Red%20Sox%20site.%20They%27re%20using%20ads%20on%20the%20homepage%20to%20promote%20ticket%20sales.%0D%0A%0D%0A%0D%0A%0D%0ACompanies%20should%20track%20how%20peo" title="del.icio.us"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/delicious.png" title="del.icio.us" alt="del.icio.us" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.facebook.com/share.php?u=http%3A%2F%2Fcutroni.com%2Fblog%2F2010%2F03%2F30%2Ftracking-internal-campaigns-with-google-analytics%2F&amp;t=Tracking%20Internal%20Campaigns%20with%20Google%20Analytics%20" title="Facebook"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/facebook.png" title="Facebook" alt="Facebook" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.linkedin.com/shareArticle?mini=true&amp;url=http%3A%2F%2Fcutroni.com%2Fblog%2F2010%2F03%2F30%2Ftracking-internal-campaigns-with-google-analytics%2F&amp;title=Tracking%20Internal%20Campaigns%20with%20Google%20Analytics%20&amp;source=Analytics+Talk+&amp;summary=Internal%20campaigns%20are%20marketing%20efforts%20that%20are%20run%20on%20your%20site%20and%20promote%20your%20products%20and%20services.%20Here%27s%20an%20example%20from%20the%20Boton%20Red%20Sox%20site.%20They%27re%20using%20ads%20on%20the%20homepage%20to%20promote%20ticket%20sales.%0D%0A%0D%0A%0D%0A%0D%0ACompanies%20should%20track%20how%20peo" title="LinkedIn"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/linkedin.png" title="LinkedIn" alt="LinkedIn" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.friendfeed.com/share?title=Tracking%20Internal%20Campaigns%20with%20Google%20Analytics%20&amp;link=http%3A%2F%2Fcutroni.com%2Fblog%2F2010%2F03%2F30%2Ftracking-internal-campaigns-with-google-analytics%2F" title="FriendFeed"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/friendfeed.png" title="FriendFeed" alt="FriendFeed" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://sphinn.com/index.php?c=post&amp;m=submit&amp;link=http%3A%2F%2Fcutroni.com%2Fblog%2F2010%2F03%2F30%2Ftracking-internal-campaigns-with-google-analytics%2F" title="Sphinn"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/sphinn.png" title="Sphinn" alt="Sphinn" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.google.com/bookmarks/mark?op=edit&amp;bkmk=http%3A%2F%2Fcutroni.com%2Fblog%2F2010%2F03%2F30%2Ftracking-internal-campaigns-with-google-analytics%2F&amp;title=Tracking%20Internal%20Campaigns%20with%20Google%20Analytics%20&amp;annotation=Internal%20campaigns%20are%20marketing%20efforts%20that%20are%20run%20on%20your%20site%20and%20promote%20your%20products%20and%20services.%20Here%27s%20an%20example%20from%20the%20Boton%20Red%20Sox%20site.%20They%27re%20using%20ads%20on%20the%20homepage%20to%20promote%20ticket%20sales.%0D%0A%0D%0A%0D%0A%0D%0ACompanies%20should%20track%20how%20peo" title="Google Bookmarks"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/googlebookmark.png" title="Google Bookmarks" alt="Google Bookmarks" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://reddit.com/submit?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2010%2F03%2F30%2Ftracking-internal-campaigns-with-google-analytics%2F&amp;title=Tracking%20Internal%20Campaigns%20with%20Google%20Analytics%20" title="Reddit"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/reddit.png" title="Reddit" alt="Reddit" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="mailto:?subject=Tracking%20Internal%20Campaigns%20with%20Google%20Analytics%20&amp;body=http%3A%2F%2Fcutroni.com%2Fblog%2F2010%2F03%2F30%2Ftracking-internal-campaigns-with-google-analytics%2F" title="email"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/email_link.png" title="email" alt="email" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://technorati.com/faves?add=http%3A%2F%2Fcutroni.com%2Fblog%2F2010%2F03%2F30%2Ftracking-internal-campaigns-with-google-analytics%2F" title="Technorati"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/technorati.png" title="Technorati" alt="Technorati" /></a></li>
	<li class="sociablelast"><a rel="nofollow"  target="_blank" href="http://buzz.yahoo.com/submit/?submitUrl=http%3A%2F%2Fcutroni.com%2Fblog%2F2010%2F03%2F30%2Ftracking-internal-campaigns-with-google-analytics%2F&amp;submitHeadline=Tracking%20Internal%20Campaigns%20with%20Google%20Analytics%20&amp;submitSummary=Internal%20campaigns%20are%20marketing%20efforts%20that%20are%20run%20on%20your%20site%20and%20promote%20your%20products%20and%20services.%20Here%27s%20an%20example%20from%20the%20Boton%20Red%20Sox%20site.%20They%27re%20using%20ads%20on%20the%20homepage%20to%20promote%20ticket%20sales.%0D%0A%0D%0A%0D%0A%0D%0ACompanies%20should%20track%20how%20peo&amp;submitCategory=science&amp;submitAssetType=text" title="Yahoo! Buzz"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/yahoobuzz.png" title="Yahoo! Buzz" alt="Yahoo! Buzz" /></a></li>
</ul>
</div>
]]></content:encoded>
			<wfw:commentRss>http://cutroni.com/blog/2010/03/30/tracking-internal-campaigns-with-google-analytics/feed/</wfw:commentRss>
		<slash:comments>19</slash:comments>
		</item>
		<item>
		<title>New Google Analytics Goals</title>
		<link>http://cutroni.com/blog/2009/10/20/new-google-analytics-goals/</link>
		<comments>http://cutroni.com/blog/2009/10/20/new-google-analytics-goals/#comments</comments>
		<pubDate>Tue, 20 Oct 2009 18:47:35 +0000</pubDate>
		<dc:creator>Justin Cutroni</dc:creator>
				<category><![CDATA[Analysis]]></category>
		<category><![CDATA[Tracking]]></category>
		<category><![CDATA[goals]]></category>
		<category><![CDATA[v4]]></category>

		<guid isPermaLink="false">http://www.epikone.com/blog/?p=1186</guid>
		<description><![CDATA[We all know that it&#8217;s critical to measure conversions, or goals, for our website. But for a long time Google Analytics limited the number of conversions, and types of conversions, you could track with Google Analytics. All that changes today (October 20, 2009). You can now create up to 20 goals per profile in Google [...]<p><a href="http://cutroni.com/blog/2009/10/20/new-google-analytics-goals/">New Google Analytics Goals</a> is a post from: <a href="http://cutroni.com/blog">Analytics Talk by Justin Cutroni</a></p>
]]></description>
			<content:encoded><![CDATA[<p>We all know that it&#8217;s critical to measure conversions, or goals, for our website.  But for a long time Google Analytics limited the number of conversions, and types of conversions, you could track with Google Analytics.  All that changes today (October 20, 2009).</p>
<p>You can now create up to 20 goals per profile in Google Analytics.  I can literally hear the applause at eMetrics :)</p>
<p>In addition to expanding the number of goals Google has expanded the types of goals to include &#8216;threshold&#8217; goals for pageviews per visit and time on site.</p>
<p>I think we all know the importance of tracking goals, so I&#8217;m not going to get too deep into why you should use goals.  If you&#8217;re not using goals you should start NOW!</p>
<p>Let&#8217;s talk about this new feature.</p>
<h2>Goal Sets</h2>
<p>Goals are now organized into four sets.  Each set of goals can contain up to five different goals.</p>
<p><img src="http://cutroni.com/blog/wp-content/uploads/picture-24.png" alt="Google Analytics Goal Sets" title="Google Analytics Goal Sets" width="549" height="473" class="aligncenter size-full wp-image-1199" /></p>
<p>Sets have been introduced as a way to accommodate all the new data in GA.  In the report tabs, rather than one goal tab there can be up to four goal tabs in a GA reports.</p>
<p><img src="http://cutroni.com/blog/wp-content/uploads/picture-191.png" alt="New Google Analytics Goal sets in a report" title="New Google Anlytics Goal sets in a report" width="537" height="116" class="aligncenter size-full wp-image-1189" /></p>
<p>When creating a goal you can place it in any set as long as there is room. Once you place a goal in a set it&#8217;s best to NOT MOVE IT.  Google Analytics sees this as a NEW goal and does not move the previously captured conversions to the new goal.</p>
<p>TIP: I like to organize goals by business function i.e. put goals that are related together.  For example, if you&#8217;re a content site, you might create goals for spending a certain amount of time on site (1 minute, 2 minutes, etc.).  I would group these goals in a set all related to time.</p>
<h2>Goal Types</h2>
<p>In the old days a goal was a pageview that represented the completion of some high value process, like a thank you page.  Now goals can be based on actions that have nothing to do with viewing a page.  Conversions can be based on how much time a visitor spends on the site or how many pages the visitor views.</p>
<h3>Time Based Goals</h3>
<p>Time based conversions are triggered after a visitor has spent a certain amount of time on the site.  To configure a time based goal enter the hours, minutes and seconds that a visitor must spend on the site before a conversion is counted.  Once the visitor reaches that amount of time on the site then a conversion is triggered.</p>
<p><img src="http://cutroni.com/blog/wp-content/uploads/picture-201.png" alt="Creating time based goals in Google Analytics." title="Creating time based goals in Google Analytics." width="441" height="451" class="aligncenter size-full wp-image-1191" /></p>
<p>What&#8217;s interesting here is that you can create a time based goal if a visit does NOT reach a certain amount of time.  If you choose &#8216;Less Than&#8217; Google Analytics will trigger a goal if a visit does NOT reach a certain length.</p>
<p><img src="http://cutroni.com/blog/wp-content/uploads/picture-212.png" alt="Less Than Goals in Google Analytics" title="Less Than Goals in Google Analytics" width="428" height="87" class="aligncenter size-full wp-image-1192" /></p>
<p>Why on earth would you measure this?  I like to think of &#8216;Less Than&#8217; goals as <strong>&#8216;Failure&#8217; metrics</strong>.  We often define success metrics, like Conversion Rate, but rarely define metrics to measure our failures!</p>
<p>Using failure based metrics really packs a punch when you&#8217;re talking to co workers or clients.  For example, when you configure a failure goal you can easily measure and say, &#8220;Did you know that 97% of our traffic does not spend at least 2 minutes on our site?  We suck!&#8221;</p>
<p><a href="http://www.kaushik.net/avinash/2006/08/excellent-analytics-tip-7-the-adorable-site-abandonment-rate-metric.html">Abandonment rate</a> is another well know failure metrics.</p>
<p><img src="http://www.cutroni.com/blog/wp-content/uploads/2009/03/clock-150x150.jpg" alt="Time on site can be configured as a Goal in GA" title="Time on site can be configured as a Goal in GA" width="150" height="150" class="alignright size-thumbnail wp-image-973" /></p>
<p>Time based goals can also be very useful if you&#8217;re trying to MINIMIZE the amount of time people spend on your site.  For example, if you have a support section on your site you may want to understand what percentage of traffic spends a certain amount of time on your site.  Long term you can try to reduce the number of visits that are too long.</p>
<p>How about setting up a goal set for various time intervals and then try to move visitors from one &#8220;goal&#8221; bucket to the next.  10 minutes, to 7 minutes, to 5 mintues&#8230; You guys are bright, you get the idea :)</p>
<p>Remember, time based goals can be affected by creating <a href="http://www.cutroni.com/blog/2007/03/19/tracking-clicks-with-ga-pt-1-about-urchintracker/">virtual pageviews</a> and <a href="http://www.cutroni.com/blog/2007/10/16/event-tracking-pt-1-overview-data-model/">events</a>.  Both of these activities send data to Google Analytics and can change how visit length is calculated.</p>
<h3>Pageview Based Goals</h3>
<p>Another new goal type is pageviews per visit.  Like time on site goals this this type of conversion is triggered when a visit exceeds a certain number of pages.  I can literally hear all the advertisers clapping out there!</p>
<p>Pageviews goals are set up in the same manner as time based conversions.  Just specify a condition (greater than or less than) and the number of pageviews in a visit.</p>
<p><img src="http://cutroni.com/blog/wp-content/uploads/picture-221.png" alt="Pageviews per Visit Goals in Google Analytics" title="Pageviews per Visit Goals in Google Analytics" width="418" height="86" class="aligncenter size-full wp-image-1193" /></p>
<p>Like time goals, pageview goals can also be affected by virtual pageviews.  If you&#8217;re creating a lot of data using <code>_trackPageview()</code> you need to understand that this can change your overall goal calculation.</p>
<h3>URL Destination Goals</h3>
<p>The old standby!  &#8216;Traditional&#8217; goals are now called URL Destination Goals.  You can still use a regular expression, head match or exact match to identify a page that represents a goal.  This functionality has not changed (you can learn more about goals <a href="http://www.cutroni.com/blog/2007/07/07/google-analytics-goals/">in this old post</a>.)</p>
<p><img src="http://cutroni.com/blog/wp-content/uploads/picture-36.png" alt="URL Destination Goal in Google Analytics" title="URL Destination Goal in Google Analytics" width="427" height="197" class="aligncenter size-full wp-image-1251" /></p>
<p>Now that we have 20 goals we can easily measure all of those micro conversions (RSS subscription, email signup, reaching product page, downloading white paper&#8230; etc, etc, etc).</p>
<p>And yes, you can still use a virtual pageview as a URL Destination goal.</p>
<h2>Funnels</h2>
<p>Google did spend some time tweaking the interface. The old interface always showed 10 steps in the funnel.  Now you can choose the number of fields the funnel form displays.  You&#8217;re still limited to 10 steps in total.  This isn&#8217;t such a big deal.</p>
<p><img src="http://cutroni.com/blog/wp-content/uploads/picture-37.png" alt="New Funnels interface in Google Analytics" title="New Funnels interface in Google Analytics" width="273" height="129" class="aligncenter size-full wp-image-1252" /></p>
<p>But think about the bigger picture.  Do we really need funnels if we have so many goals?  With 20 goals we can use a goal to represent each stage in a process, rather than a funnel step? So do we still need funnels?</p>
<p>Yes.  Funnels provide a nice visualization of critical processes, so I think they are still relevant.  Plus, you need to configure a funnel if you want to measure Abandonment rate, a very nice failure metric that can make people squirm :)</p>
<h2>Odds and Ends</h2>
<p>A few random thoughts re: new goals:</p>
<p>If you&#8217;ve been creating lots of profiles for goals you may want to consider consolidating all goals to a single profile.  The benefit is you can  have all your conversions in one interface.  No more messing with multiple browser tabs and adjusting the date range.</p>
<p>If you need to control the access to certain goals, you may need to create a profile for certain goals and then give only the people who need access to those goals access to the profile.</p>
<p>A visitor can only convert at each goal once per visit. This is the way it&#8217;s always been.</p>
<p>And finally, creating new goals will not modify your historical data, only future data.  So all those new goals you&#8217;re going to create this week will only track from the day your create them onward.</p>
<p><a href="http://cutroni.com/blog/2009/10/20/new-google-analytics-goals/">New Google Analytics Goals</a> is a post from: <a href="http://cutroni.com/blog">Analytics Talk by Justin Cutroni</a></p>

<div class="sociable">

<ul>
	<li class="sociablefirst"><a rel="nofollow"  target="_blank" href="http://twitter.com/home?status=New%20Google%20Analytics%20Goals%20-%20http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F10%2F20%2Fnew-google-analytics-goals%2F" title="Twitter"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/twitter.png" title="Twitter" alt="Twitter" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F10%2F20%2Fnew-google-analytics-goals%2F&amp;title=New%20Google%20Analytics%20Goals" title="StumbleUpon"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/stumbleupon.png" title="StumbleUpon" alt="StumbleUpon" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F10%2F20%2Fnew-google-analytics-goals%2F&amp;title=New%20Google%20Analytics%20Goals&amp;bodytext=We%20all%20know%20that%20it%27s%20critical%20to%20measure%20conversions%2C%20or%20goals%2C%20for%20our%20website.%20%20But%20for%20a%20long%20time%20Google%20Analytics%20limited%20the%20number%20of%20conversions%2C%20and%20types%20of%20conversions%2C%20you%20could%20track%20with%20Google%20Analytics.%20%20All%20that%20changes%20today%20%28Octob" title="Digg"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/digg.png" title="Digg" alt="Digg" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://delicious.com/post?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F10%2F20%2Fnew-google-analytics-goals%2F&amp;title=New%20Google%20Analytics%20Goals&amp;notes=We%20all%20know%20that%20it%27s%20critical%20to%20measure%20conversions%2C%20or%20goals%2C%20for%20our%20website.%20%20But%20for%20a%20long%20time%20Google%20Analytics%20limited%20the%20number%20of%20conversions%2C%20and%20types%20of%20conversions%2C%20you%20could%20track%20with%20Google%20Analytics.%20%20All%20that%20changes%20today%20%28Octob" title="del.icio.us"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/delicious.png" title="del.icio.us" alt="del.icio.us" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.facebook.com/share.php?u=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F10%2F20%2Fnew-google-analytics-goals%2F&amp;t=New%20Google%20Analytics%20Goals" title="Facebook"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/facebook.png" title="Facebook" alt="Facebook" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.linkedin.com/shareArticle?mini=true&amp;url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F10%2F20%2Fnew-google-analytics-goals%2F&amp;title=New%20Google%20Analytics%20Goals&amp;source=Analytics+Talk+&amp;summary=We%20all%20know%20that%20it%27s%20critical%20to%20measure%20conversions%2C%20or%20goals%2C%20for%20our%20website.%20%20But%20for%20a%20long%20time%20Google%20Analytics%20limited%20the%20number%20of%20conversions%2C%20and%20types%20of%20conversions%2C%20you%20could%20track%20with%20Google%20Analytics.%20%20All%20that%20changes%20today%20%28Octob" title="LinkedIn"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/linkedin.png" title="LinkedIn" alt="LinkedIn" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.friendfeed.com/share?title=New%20Google%20Analytics%20Goals&amp;link=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F10%2F20%2Fnew-google-analytics-goals%2F" title="FriendFeed"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/friendfeed.png" title="FriendFeed" alt="FriendFeed" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://sphinn.com/index.php?c=post&amp;m=submit&amp;link=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F10%2F20%2Fnew-google-analytics-goals%2F" title="Sphinn"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/sphinn.png" title="Sphinn" alt="Sphinn" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.google.com/bookmarks/mark?op=edit&amp;bkmk=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F10%2F20%2Fnew-google-analytics-goals%2F&amp;title=New%20Google%20Analytics%20Goals&amp;annotation=We%20all%20know%20that%20it%27s%20critical%20to%20measure%20conversions%2C%20or%20goals%2C%20for%20our%20website.%20%20But%20for%20a%20long%20time%20Google%20Analytics%20limited%20the%20number%20of%20conversions%2C%20and%20types%20of%20conversions%2C%20you%20could%20track%20with%20Google%20Analytics.%20%20All%20that%20changes%20today%20%28Octob" title="Google Bookmarks"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/googlebookmark.png" title="Google Bookmarks" alt="Google Bookmarks" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://reddit.com/submit?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F10%2F20%2Fnew-google-analytics-goals%2F&amp;title=New%20Google%20Analytics%20Goals" title="Reddit"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/reddit.png" title="Reddit" alt="Reddit" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="mailto:?subject=New%20Google%20Analytics%20Goals&amp;body=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F10%2F20%2Fnew-google-analytics-goals%2F" title="email"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/email_link.png" title="email" alt="email" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://technorati.com/faves?add=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F10%2F20%2Fnew-google-analytics-goals%2F" title="Technorati"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/technorati.png" title="Technorati" alt="Technorati" /></a></li>
	<li class="sociablelast"><a rel="nofollow"  target="_blank" href="http://buzz.yahoo.com/submit/?submitUrl=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F10%2F20%2Fnew-google-analytics-goals%2F&amp;submitHeadline=New%20Google%20Analytics%20Goals&amp;submitSummary=We%20all%20know%20that%20it%27s%20critical%20to%20measure%20conversions%2C%20or%20goals%2C%20for%20our%20website.%20%20But%20for%20a%20long%20time%20Google%20Analytics%20limited%20the%20number%20of%20conversions%2C%20and%20types%20of%20conversions%2C%20you%20could%20track%20with%20Google%20Analytics.%20%20All%20that%20changes%20today%20%28Octob&amp;submitCategory=science&amp;submitAssetType=text" title="Yahoo! Buzz"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/yahoobuzz.png" title="Yahoo! Buzz" alt="Yahoo! Buzz" /></a></li>
</ul>
</div>
]]></content:encoded>
			<wfw:commentRss>http://cutroni.com/blog/2009/10/20/new-google-analytics-goals/feed/</wfw:commentRss>
		<slash:comments>44</slash:comments>
		</item>
		<item>
		<title>Google Analytics Custom Variables Overview</title>
		<link>http://cutroni.com/blog/2009/10/20/google-analytics-custom-variables-overview/</link>
		<comments>http://cutroni.com/blog/2009/10/20/google-analytics-custom-variables-overview/#comments</comments>
		<pubDate>Tue, 20 Oct 2009 18:46:43 +0000</pubDate>
		<dc:creator>Justin Cutroni</dc:creator>
				<category><![CDATA[Analysis]]></category>
		<category><![CDATA[Tracking]]></category>
		<category><![CDATA[custom variables]]></category>
		<category><![CDATA[v4]]></category>

		<guid isPermaLink="false">http://www.epikone.com/blog/?p=1222</guid>
		<description><![CDATA[Today Google releases Custom Variables (cv for short) in Google Analytics. This is an evolution of the custom segmentation feature. This post is meant to give you an overview of the feature. We&#8217;ll discuss how to use it in a later post. Like Custom Segmentation, custom variables are a flexible way to add more information [...]<p><a href="http://cutroni.com/blog/2009/10/20/google-analytics-custom-variables-overview/">Google Analytics Custom Variables Overview</a> is a post from: <a href="http://cutroni.com/blog">Analytics Talk by Justin Cutroni</a></p>
]]></description>
			<content:encoded><![CDATA[<p>Today Google releases Custom Variables (cv for short) in Google Analytics.  This is an evolution of the custom segmentation feature.  This post is meant to give you an overview of the feature.  We&#8217;ll discuss how to use it in a later post.</p>
<p>Like Custom Segmentation, custom variables are a flexible way to add more information to Google Analytics.  The big difference is that you can create LOTS of custom variables.  How many?  In theory you can set an infinite number of custom variables.  But GA has some internal limits that keep you to 50,000.</p>
<p>What can we use custom variables for?  The possibilities are endless:</p>
<ul>
<li>Segmenting members from non-members</li>
<li>Segmenting customers from non-customers</li>
<li>Tracking all the campaigns a visitor sees prior to converting</li>
<li>Content categorization</li>
<li>Segmenting visitors based on landing page</li>
<li>Visitor segmentation based on demographic info</li>
<li>Customer segmentation based on order history</li>
</ul>
<p><img src="http://cutroni.com/blog/wp-content/uploads/christmas_tree.png" alt="Google Analytics Custom Variables are like data decorations!" title="Google Analytics Custom Variables are like data decorations!" width="125" height="169" class="alignright size-full wp-image-1258" /></p>
<p>As my friend Phil likes to say, custom variables are decorations that you hang on your data.  Almost like holiday decorations hanging on a tree!  This is a really good analogy that I&#8217;ll continue in this post.</p>
<p>There are four critical attributes of a custom variable that we must understand in order to use them.</p>
<h2>Name and Value</h2>
<p>The easiest attributes to understand are Name and Value.  The Name of a custom variable is literally the name you give to the variable.  Each variable can have many, many values.   For example, you could define a variable named &#8216;Baseball Team&#8217; and then add the values:</p>
<ul>
<li>Red Sox</li>
<li>Yankees</li>
<li>Phillies</li>
<li>Giants</li>
<li>Angels</li>
</ul>
<p>This is totally different than the old Custom Segmentation feature.  With Custom Segmentation you were limited to one variable (ie one Name) that could contain multiple values.  Now you can create multiple variables each of which can have multiple values.</p>
<p>You can view all of your variable names in the new Custom Variables report.</p>
<p><img src="http://cutroni.com/blog/wp-content/uploads/picture-331.png" alt="Google Analytics Custom Variables Report" title="Google Analytics Custom Variables Report" width="628" height="217" class="aligncenter size-full wp-image-1224" /></p>
<p><strong>It&#8217;s important to note that the name of a variable, plus the value for a variable must be less than 64 characters</strong>.  Why?  The data is sent to Google via a request for an image file.  The actual length of the request is limited and Google wants to insure that all of the data makes it to the server.</p>
<h2>Scope</h2>
<p><img src="http://www.cutroni.com/blog/wp-content/uploads/2009/10/scope-mouthwash-canada-150x150.jpg" alt="Google Analytics custom variables depends on the scope of the variable." title="Google Analytics custom variables depends on the scope of the variable." border="0px" width="150" height="150" class="alignright size-thumbnail wp-image-1243" /></p>
<p>The real power of custom variables comes with something called the Scope.  Think of scope as the different  &#8216;levels&#8217; of visitor data.  When a visitor visits a website Google Analytics collects data at three levels:</p>
<ul>
<li><strong>Pageview level</strong>: This is data associated with each page viewed during a visits. Page level data can change from one page to the next.</li>
<li><strong>Visit level</strong>: This is data associated with the visitor&#8217;s entire visit.  This data can change from one visit to the next.  But visit level data is applied to every page within a visit.  This data only exists for the CURRENT visits.</li>
<li><strong>Visitor Level</strong>:  This data is applied to the visitor and every visit and every pageview that the visitor generates.  This data persists across all visits that a person creates.  How does it persist?  Via a cookie.</li>
</ul>
<p>This means we can set information, ie custom variables, at the page level, the visit level and the visitor level.  If we think of custom variables as decorations &#8220;hanging&#8221; on our data then we could use the following graphic:</p>
<p><img src="http://www.cutroni.com/blog/wp-content/uploads/2009/10/cv-scope-300x201.jpg" alt="GA Custom Variables &quot;hanging&quot; on your data." title="GA Custom Variables &quot;hanging&quot; on your data." width="300" height="201" class="aligncenter size-medium wp-image-1225" /></p>
<p>So scope is the same as level.  Anyone drooling out there?</p>
<p>The ability to control the scope of a custom variable makes this feature extremely flexible.  For example, if you want to group all of the content on your site you can add a page level custom variable to every page that identifies the groups that a page belongs to.</p>
<p>If you want to segment visitors by their purchase history you can add visitor level custom variable.  The possibilities are truly endless.</p>
<p>Let&#8217;s take a look at some of the reporting so you can get a feel for some of the data.</p>
<p>Here&#8217;s the Custom Variables report.  You&#8217;ll notice it looks a lot like the user defined report.  This report contains all of the variables that you defined.  If you click on a variable you&#8217;ll see all of the VALUES for that variable.</p>
<p>So why has google added a scope if we can&#8217;t see it in the reports?  I&#8217;m just going to let you guys speculate. But it&#8217;s obviously a critical part of CVs and we should see that data.</p>
<h2>Index</h2>
<p>The last attribute that we need to discuss is something called the Index.  To be honest, it&#8217;s really hard to define the index.  Basically the index is a technical attribute that helps GA organize all the custom variables on a page.</p>
<p>It&#8217;s only used during the implementation, so we&#8217;re not going to dig any further in this post.</p>
<p>Speaking of the implementation, you&#8217;ve probably noticed that I haven&#8217;t talked much about the implementation.  To be honest, we&#8217;re still playing with CVs.  Obviously this data comes from JavaScript.  So you have to do some coding to get this data.</p>
<p>But I&#8217;m going to hold off on the implementation talk until later. Implementation involves another concept called the Index which is, to be honest, vague and confusing.</p>
<p><a href="http://cutroni.com/blog/2009/10/20/google-analytics-custom-variables-overview/">Google Analytics Custom Variables Overview</a> is a post from: <a href="http://cutroni.com/blog">Analytics Talk by Justin Cutroni</a></p>

<div class="sociable">

<ul>
	<li class="sociablefirst"><a rel="nofollow"  target="_blank" href="http://twitter.com/home?status=Google%20Analytics%20Custom%20Variables%20Overview%20-%20http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F10%2F20%2Fgoogle-analytics-custom-variables-overview%2F" title="Twitter"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/twitter.png" title="Twitter" alt="Twitter" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F10%2F20%2Fgoogle-analytics-custom-variables-overview%2F&amp;title=Google%20Analytics%20Custom%20Variables%20Overview" title="StumbleUpon"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/stumbleupon.png" title="StumbleUpon" alt="StumbleUpon" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F10%2F20%2Fgoogle-analytics-custom-variables-overview%2F&amp;title=Google%20Analytics%20Custom%20Variables%20Overview&amp;bodytext=Today%20Google%20releases%20Custom%20Variables%20%28cv%20for%20short%29%20in%20Google%20Analytics.%20%20This%20is%20an%20evolution%20of%20the%20custom%20segmentation%20feature.%20%20This%20post%20is%20meant%20to%20give%20you%20an%20overview%20of%20the%20feature.%20%20We%27ll%20discuss%20how%20to%20use%20it%20in%20a%20later%20post.%0A%0ALike%20Custo" title="Digg"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/digg.png" title="Digg" alt="Digg" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://delicious.com/post?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F10%2F20%2Fgoogle-analytics-custom-variables-overview%2F&amp;title=Google%20Analytics%20Custom%20Variables%20Overview&amp;notes=Today%20Google%20releases%20Custom%20Variables%20%28cv%20for%20short%29%20in%20Google%20Analytics.%20%20This%20is%20an%20evolution%20of%20the%20custom%20segmentation%20feature.%20%20This%20post%20is%20meant%20to%20give%20you%20an%20overview%20of%20the%20feature.%20%20We%27ll%20discuss%20how%20to%20use%20it%20in%20a%20later%20post.%0A%0ALike%20Custo" title="del.icio.us"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/delicious.png" title="del.icio.us" alt="del.icio.us" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.facebook.com/share.php?u=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F10%2F20%2Fgoogle-analytics-custom-variables-overview%2F&amp;t=Google%20Analytics%20Custom%20Variables%20Overview" title="Facebook"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/facebook.png" title="Facebook" alt="Facebook" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.linkedin.com/shareArticle?mini=true&amp;url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F10%2F20%2Fgoogle-analytics-custom-variables-overview%2F&amp;title=Google%20Analytics%20Custom%20Variables%20Overview&amp;source=Analytics+Talk+&amp;summary=Today%20Google%20releases%20Custom%20Variables%20%28cv%20for%20short%29%20in%20Google%20Analytics.%20%20This%20is%20an%20evolution%20of%20the%20custom%20segmentation%20feature.%20%20This%20post%20is%20meant%20to%20give%20you%20an%20overview%20of%20the%20feature.%20%20We%27ll%20discuss%20how%20to%20use%20it%20in%20a%20later%20post.%0A%0ALike%20Custo" title="LinkedIn"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/linkedin.png" title="LinkedIn" alt="LinkedIn" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.friendfeed.com/share?title=Google%20Analytics%20Custom%20Variables%20Overview&amp;link=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F10%2F20%2Fgoogle-analytics-custom-variables-overview%2F" title="FriendFeed"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/friendfeed.png" title="FriendFeed" alt="FriendFeed" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://sphinn.com/index.php?c=post&amp;m=submit&amp;link=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F10%2F20%2Fgoogle-analytics-custom-variables-overview%2F" title="Sphinn"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/sphinn.png" title="Sphinn" alt="Sphinn" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.google.com/bookmarks/mark?op=edit&amp;bkmk=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F10%2F20%2Fgoogle-analytics-custom-variables-overview%2F&amp;title=Google%20Analytics%20Custom%20Variables%20Overview&amp;annotation=Today%20Google%20releases%20Custom%20Variables%20%28cv%20for%20short%29%20in%20Google%20Analytics.%20%20This%20is%20an%20evolution%20of%20the%20custom%20segmentation%20feature.%20%20This%20post%20is%20meant%20to%20give%20you%20an%20overview%20of%20the%20feature.%20%20We%27ll%20discuss%20how%20to%20use%20it%20in%20a%20later%20post.%0A%0ALike%20Custo" title="Google Bookmarks"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/googlebookmark.png" title="Google Bookmarks" alt="Google Bookmarks" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://reddit.com/submit?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F10%2F20%2Fgoogle-analytics-custom-variables-overview%2F&amp;title=Google%20Analytics%20Custom%20Variables%20Overview" title="Reddit"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/reddit.png" title="Reddit" alt="Reddit" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="mailto:?subject=Google%20Analytics%20Custom%20Variables%20Overview&amp;body=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F10%2F20%2Fgoogle-analytics-custom-variables-overview%2F" title="email"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/email_link.png" title="email" alt="email" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://technorati.com/faves?add=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F10%2F20%2Fgoogle-analytics-custom-variables-overview%2F" title="Technorati"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/technorati.png" title="Technorati" alt="Technorati" /></a></li>
	<li class="sociablelast"><a rel="nofollow"  target="_blank" href="http://buzz.yahoo.com/submit/?submitUrl=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F10%2F20%2Fgoogle-analytics-custom-variables-overview%2F&amp;submitHeadline=Google%20Analytics%20Custom%20Variables%20Overview&amp;submitSummary=Today%20Google%20releases%20Custom%20Variables%20%28cv%20for%20short%29%20in%20Google%20Analytics.%20%20This%20is%20an%20evolution%20of%20the%20custom%20segmentation%20feature.%20%20This%20post%20is%20meant%20to%20give%20you%20an%20overview%20of%20the%20feature.%20%20We%27ll%20discuss%20how%20to%20use%20it%20in%20a%20later%20post.%0A%0ALike%20Custo&amp;submitCategory=science&amp;submitAssetType=text" title="Yahoo! Buzz"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/yahoobuzz.png" title="Yahoo! Buzz" alt="Yahoo! Buzz" /></a></li>
</ul>
</div>
]]></content:encoded>
			<wfw:commentRss>http://cutroni.com/blog/2009/10/20/google-analytics-custom-variables-overview/feed/</wfw:commentRss>
		<slash:comments>24</slash:comments>
		</item>
		<item>
		<title>Tracking Zero Result Searches in Google Analytics</title>
		<link>http://cutroni.com/blog/2009/09/08/tracking-ero-result-searches-in-google-analytics/</link>
		<comments>http://cutroni.com/blog/2009/09/08/tracking-ero-result-searches-in-google-analytics/#comments</comments>
		<pubDate>Wed, 09 Sep 2009 02:53:57 +0000</pubDate>
		<dc:creator>Justin Cutroni</dc:creator>
				<category><![CDATA[Analysis]]></category>
		<category><![CDATA[Tips]]></category>
		<category><![CDATA[Tracking]]></category>
		<category><![CDATA[enhancements]]></category>
		<category><![CDATA[site search]]></category>

		<guid isPermaLink="false">http://www.epikone.com/blog/?p=1105</guid>
		<description><![CDATA[I &#60;3 Google Analytics Site Search reports. There&#8217;s amazingly actionable data in those reports. But they&#8217;re missing one vital piece of information: searches that don&#8217;t produce any results. Why is this important? Don&#8217;t you want to know when visitors search and don&#8217;t get any results? Zero result searches can help your identify missing content on [...]<p><a href="http://cutroni.com/blog/2009/09/08/tracking-ero-result-searches-in-google-analytics/">Tracking Zero Result Searches in Google Analytics</a> is a post from: <a href="http://cutroni.com/blog">Analytics Talk by Justin Cutroni</a></p>
]]></description>
			<content:encoded><![CDATA[<p>I &lt;3 Google Analytics Site Search reports.  There&#8217;s amazingly actionable data in those reports.  But they&#8217;re missing one vital piece of information: searches that don&#8217;t produce any results.</p>
<p>Why is this important?  Don&#8217;t you want to know when visitors search and don&#8217;t get any results?  Zero result searches can help your identify missing content on your site or a problem with your site search engine.</p>
<p><img src="http://cutroni.com/blog/wp-content/uploads/fenway-scoreboard.png" alt="fenway-scoreboard" title="fenway-scoreboard" width="449" height="149" class="aligncenter size-full wp-image-1170" /></p>
<p>Many search solutions will provide this information for you.  For example, I use <a href="http://tr.im/yd7t">Search Meter</a> for WordPress and it shows me which search queries generate zero results.  But I thought it would be interesting to add this data to Google Analytics.  That way all my site search information would be in one place.</p>
<p>Unfortunately there is no easy way to add this data to GA.  You need to do some programming to collect the data.  So this post is really meant for those folks with programming resources AND for those developers that maintain GA plugins.  Like my buddy <a href="http://tr.im/yd7x">Joost</a>, who has a great GA plugin for WordPress.</p>
<p>If you&#8217;re interested in the data and analysis, skip to the bottom of this post.</p>
<h2>Conceptual Overview</h2>
<p>Our goal with this hack is to modify site search data in two ways.  First, we&#8217;re going to put all search queries with zero results in a category.  This will allow us to use the Search Categories report to easily find all the search terms that yielded zero results.</p>
<p>Second, we&#8217;ll modify the actual search terms to indicate that a term yielded zero results.  This will make it easy to scan a list of all the search terms and identify which generated no results.</p>
<p>Before we get into the implementation, a big THANK YOU to Charles Miller, one of the lead consultants here.  He wrote the JavaScript below.  Thanks Charles.</p>
<h2>Step 1: Identify No Result Search</h2>
<p>The first step is to identify a zero results search page.  Most websites have the same search results page regardless of the number of results.  You need to identify some something that differentiates a zero results search page from a non-zero results search page.</p>
<p>This must be done programatically and is the hardest part of the implementation.</p>
<p>For example, a zero results search page on this blog has the text &#8220;No posts found. Try a different search?&#8221;</p>
<p><img src="http://cutroni.com/blog/wp-content/uploads/picture-23.png" alt="No Posts Found" title="No Posts Found" width="468" height="143" class="aligncenter size-full wp-image-1110" /></p>
<p>I can create code (or more specifically, Charles can create code) to look for the text &#8220;No posts found. Try a different search?&#8221; If the code finds this text in the page then I can identify that the visitor&#8217;s search yielded zero results and than I can send the data sent to GA.  Here&#8217;s the code that I&#8217;m using on this blog:</p>
<pre>
<code>var content = document.getElementById('content');
if (content.innerHTML.search('No posts found.')) {</code>
</pre>
<p>The code looks for a section of the page called &#8216;content&#8217; and then searches that section for the phrase &#8216;No posts found.&#8217;.  If &#8216;no posts found.&#8217; is found (oh, the irony!) then we will modify the data sent to GA.</p>
<p>Important!  The way you detect a zero result search page may be different.  It&#8217;s VERY difficult to create an example that will work for everyone.  Take this as a conceptual overview.</p>
<h2>Step 2:  Tweak GA Tracking Code</h2>
<p>Once we know what differentiates a zero results search page we can add some code that tweaks the data.  Remember, we want to modify the data in two ways: 1. by placing it in a special search category and 2. by modifying the search term to indicate it did not yield any results.</p>
<p>To create the category all we need to do is add an extra query string parameter to the URL.</p>
<p>To manipulate the search term we need to split apart the page URL and then put it back together with the phrase no-results.</p>
<p>Here&#8217;s the complete code.</p>
<pre>
<code>&lt;script type='text/javascript'&gt;
var pageTracker = _gat._getTracker("UA-XXXXXX-1");
var content = document.getElementById('content');
if (content.innerHTML.search('No posts found.')) {
     // These lines get the search data from the URL and
     //  deconstruct the URL into parts
     var sn = "s";
     var sr = new RegExp(sn+"=[^\&amp;]+"),
      p = document.location.pathname,
      s = document.location.search,
      sm = s.match(sr).toString(),
      srs = sm.split("="),
      // The next line is where we add the category and add
      // the phrase no-results to the search term.
      sre = sm.replace(sr,srs[0]+"=no-results:
 "+srs[1]+"&amp;cat=no-results"),
      sf = s.replace(sr,sre);
      // Send the data to Google as a Pageview
      pageTracker._trackPageview(p+sf);
} else {
      // If this is a regular page on the site, use the standard GA code.
      pageTracker._trackPageview();
}
&lt;/script&gt;</code>
</pre>
<p>The code starts with the section that identifies a zero result search page.</p>
<p>Then we deconstruct the URL to identify the search term.  Finally we add the category named &#8216;no_results&#8217; and the phrase &#8216;no-results&#8217; to the search term.</p>
<p>If the code does NOT find the term &#8216;No posts found.&#8217; then a pageview is created as normal.</p>
<p>That&#8217;s it for the coding part (thank goodness!)</p>
<h2>Step 3:  Configure Site Search Settings</h2>
<p>The last step is to add the new category parameter to the Site Search settings so GA can identify the no-results search category.  This is easy, it&#8217;s in the profile setting section of Google Analytics.</p>
<p><img src="http://cutroni.com/blog/wp-content/uploads/picture-33.png" alt="How to set a search Category parameter in Google Analytics" title="How to set a search Category parameter in Google Analytics" width="345" height="153" class="aligncenter size-full wp-image-1111" /></p>
<p>I also like to set the &#8216;Strip Query Parameter&#8217; to YES.  This removes the category parameter after site search is done processing and normalizes your pageview data.</p>
<p>That&#8217;s it for the configuration!  We&#8217;re cleared for insight-hunting!</p>
<h2>Analyzing The Data</h2>
<p>When a visitor performs a search that yields zero results the search term will be placed in a category named &#8216;no_results&#8217;.  To find this data navigate to the Content>Site Search>Categories Report:</p>
<p><img src="http://cutroni.com/blog/wp-content/uploads/site-search-categories-google-analytics-2.png" alt="site-search-categories-google-analytics-2" title="site-search-categories-google-analytics-2" width="471" height="94" class="aligncenter size-full wp-image-1155" /></p>
<p>Immediately you&#8217;ll be able to see what percentage of your searches yield zero results.  Hopefully it&#8217;s very low!  Want to see if this impacts conversions or revenue?  Click the Goals or Ecommerce tab to check the conversion rate:</p>
<p><img src="http://cutroni.com/blog/wp-content/uploads/site-search-categories-google-analytics-4.png" alt="Zero Result Searches Impact on Website Outcomes" title="Zero Result Searches Impact on Website Outcomes" width="516" height="108" class="aligncenter size-full wp-image-1164" /></p>
<p>This is a bad picture, but you get the point.</p>
<p>Next you can click on the no-results line in the data and see exactly which search terms yielded zero results.</p>
<p><img src="http://cutroni.com/blog/wp-content/uploads/site-search-category_-google-analytics-1.png" alt="Search terms that had no results in Google Analytics" title="Search terms that had no results in Google Analytics" width="472" height="185" class="aligncenter size-full wp-image-1157" /></p>
<p>This is super-actionable data.  Now you know where you may be missing content or if your site search engine might be broken.  You should be asking yourself, &#8220;Why are there no results for these terms?  Is there missing content or is there a problem with my site search engine?&#8221;</p>
<p>You&#8217;ll also notice that the search terms now have &#8216;no-results&#8217; in them.  This provides a lot of flexibility for view the search data other ways.  Example, let&#8217;s use the Search Terms report:</p>
<p><img src="http://cutroni.com/blog/wp-content/uploads/site-search-terms-google-analytics-2.png" alt="Google Analytics site search queries" title="Google Analytics site search queries" width="581" height="257" class="aligncenter size-full wp-image-1159" /></p>
<p>Here we can see the search terms ranked by searches.  What percent of your top 10, 20 or 50 are no-result searches?  How is that impacting your bottom line?</p>
<p>This is just the start.  You can use other metrics, like %Search Exists to understand if visitors who receive zero results refine their search or exit.</p>
<p>While this is not the easiest thing to configure, I hope you see the value of the data.  More so, I hope that all those folks that maintain plugins add this type of feature to their GA plugins.  Joost, you listening!?</p>
<p><a href="http://cutroni.com/blog/2009/09/08/tracking-ero-result-searches-in-google-analytics/">Tracking Zero Result Searches in Google Analytics</a> is a post from: <a href="http://cutroni.com/blog">Analytics Talk by Justin Cutroni</a></p>

<div class="sociable">

<ul>
	<li class="sociablefirst"><a rel="nofollow"  target="_blank" href="http://twitter.com/home?status=Tracking%20Zero%20Result%20Searches%20in%20Google%20Analytics%20-%20http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F09%2F08%2Ftracking-ero-result-searches-in-google-analytics%2F" title="Twitter"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/twitter.png" title="Twitter" alt="Twitter" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F09%2F08%2Ftracking-ero-result-searches-in-google-analytics%2F&amp;title=Tracking%20Zero%20Result%20Searches%20in%20Google%20Analytics" title="StumbleUpon"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/stumbleupon.png" title="StumbleUpon" alt="StumbleUpon" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F09%2F08%2Ftracking-ero-result-searches-in-google-analytics%2F&amp;title=Tracking%20Zero%20Result%20Searches%20in%20Google%20Analytics&amp;bodytext=I%20%26lt%3B3%20Google%20Analytics%20Site%20Search%20reports.%20%20There%27s%20amazingly%20actionable%20data%20in%20those%20reports.%20%20But%20they%27re%20missing%20one%20vital%20piece%20of%20information%3A%20searches%20that%20don%27t%20produce%20any%20results.%0A%0AWhy%20is%20this%20important%3F%20%20Don%27t%20you%20want%20to%20know%20when%20visi" title="Digg"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/digg.png" title="Digg" alt="Digg" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://delicious.com/post?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F09%2F08%2Ftracking-ero-result-searches-in-google-analytics%2F&amp;title=Tracking%20Zero%20Result%20Searches%20in%20Google%20Analytics&amp;notes=I%20%26lt%3B3%20Google%20Analytics%20Site%20Search%20reports.%20%20There%27s%20amazingly%20actionable%20data%20in%20those%20reports.%20%20But%20they%27re%20missing%20one%20vital%20piece%20of%20information%3A%20searches%20that%20don%27t%20produce%20any%20results.%0A%0AWhy%20is%20this%20important%3F%20%20Don%27t%20you%20want%20to%20know%20when%20visi" title="del.icio.us"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/delicious.png" title="del.icio.us" alt="del.icio.us" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.facebook.com/share.php?u=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F09%2F08%2Ftracking-ero-result-searches-in-google-analytics%2F&amp;t=Tracking%20Zero%20Result%20Searches%20in%20Google%20Analytics" title="Facebook"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/facebook.png" title="Facebook" alt="Facebook" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.linkedin.com/shareArticle?mini=true&amp;url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F09%2F08%2Ftracking-ero-result-searches-in-google-analytics%2F&amp;title=Tracking%20Zero%20Result%20Searches%20in%20Google%20Analytics&amp;source=Analytics+Talk+&amp;summary=I%20%26lt%3B3%20Google%20Analytics%20Site%20Search%20reports.%20%20There%27s%20amazingly%20actionable%20data%20in%20those%20reports.%20%20But%20they%27re%20missing%20one%20vital%20piece%20of%20information%3A%20searches%20that%20don%27t%20produce%20any%20results.%0A%0AWhy%20is%20this%20important%3F%20%20Don%27t%20you%20want%20to%20know%20when%20visi" title="LinkedIn"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/linkedin.png" title="LinkedIn" alt="LinkedIn" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.friendfeed.com/share?title=Tracking%20Zero%20Result%20Searches%20in%20Google%20Analytics&amp;link=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F09%2F08%2Ftracking-ero-result-searches-in-google-analytics%2F" title="FriendFeed"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/friendfeed.png" title="FriendFeed" alt="FriendFeed" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://sphinn.com/index.php?c=post&amp;m=submit&amp;link=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F09%2F08%2Ftracking-ero-result-searches-in-google-analytics%2F" title="Sphinn"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/sphinn.png" title="Sphinn" alt="Sphinn" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.google.com/bookmarks/mark?op=edit&amp;bkmk=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F09%2F08%2Ftracking-ero-result-searches-in-google-analytics%2F&amp;title=Tracking%20Zero%20Result%20Searches%20in%20Google%20Analytics&amp;annotation=I%20%26lt%3B3%20Google%20Analytics%20Site%20Search%20reports.%20%20There%27s%20amazingly%20actionable%20data%20in%20those%20reports.%20%20But%20they%27re%20missing%20one%20vital%20piece%20of%20information%3A%20searches%20that%20don%27t%20produce%20any%20results.%0A%0AWhy%20is%20this%20important%3F%20%20Don%27t%20you%20want%20to%20know%20when%20visi" title="Google Bookmarks"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/googlebookmark.png" title="Google Bookmarks" alt="Google Bookmarks" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://reddit.com/submit?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F09%2F08%2Ftracking-ero-result-searches-in-google-analytics%2F&amp;title=Tracking%20Zero%20Result%20Searches%20in%20Google%20Analytics" title="Reddit"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/reddit.png" title="Reddit" alt="Reddit" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="mailto:?subject=Tracking%20Zero%20Result%20Searches%20in%20Google%20Analytics&amp;body=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F09%2F08%2Ftracking-ero-result-searches-in-google-analytics%2F" title="email"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/email_link.png" title="email" alt="email" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://technorati.com/faves?add=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F09%2F08%2Ftracking-ero-result-searches-in-google-analytics%2F" title="Technorati"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/technorati.png" title="Technorati" alt="Technorati" /></a></li>
	<li class="sociablelast"><a rel="nofollow"  target="_blank" href="http://buzz.yahoo.com/submit/?submitUrl=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F09%2F08%2Ftracking-ero-result-searches-in-google-analytics%2F&amp;submitHeadline=Tracking%20Zero%20Result%20Searches%20in%20Google%20Analytics&amp;submitSummary=I%20%26lt%3B3%20Google%20Analytics%20Site%20Search%20reports.%20%20There%27s%20amazingly%20actionable%20data%20in%20those%20reports.%20%20But%20they%27re%20missing%20one%20vital%20piece%20of%20information%3A%20searches%20that%20don%27t%20produce%20any%20results.%0A%0AWhy%20is%20this%20important%3F%20%20Don%27t%20you%20want%20to%20know%20when%20visi&amp;submitCategory=science&amp;submitAssetType=text" title="Yahoo! Buzz"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/yahoobuzz.png" title="Yahoo! Buzz" alt="Yahoo! Buzz" /></a></li>
</ul>
</div>
]]></content:encoded>
			<wfw:commentRss>http://cutroni.com/blog/2009/09/08/tracking-ero-result-searches-in-google-analytics/feed/</wfw:commentRss>
		<slash:comments>25</slash:comments>
		</item>
		<item>
		<title>How Google Analytics Tracks &#8216;Bookmark&#8217; Visits</title>
		<link>http://cutroni.com/blog/2009/05/20/how-google-analytics-tracks-bookmark-visits/</link>
		<comments>http://cutroni.com/blog/2009/05/20/how-google-analytics-tracks-bookmark-visits/#comments</comments>
		<pubDate>Thu, 21 May 2009 01:00:36 +0000</pubDate>
		<dc:creator>Justin Cutroni</dc:creator>
				<category><![CDATA[About Google Analytics]]></category>
		<category><![CDATA[Campaign Tracking]]></category>
		<category><![CDATA[Tracking]]></category>

		<guid isPermaLink="false">http://www.epikone.com/blog/?p=1037</guid>
		<description><![CDATA[I was recently inspired by a Tweet to write about how GA tracks visitors that use a bookmark to access a site. Simply put, Google Analytics will attribute a &#8216;bookmark&#8217; visit to the information in the Google Analytics campaign cookie. Many people believe that GA tracks bookmark visits as (direct) traffic. Google Analytics does not [...]<p><a href="http://cutroni.com/blog/2009/05/20/how-google-analytics-tracks-bookmark-visits/">How Google Analytics Tracks &#8216;Bookmark&#8217; Visits</a> is a post from: <a href="http://cutroni.com/blog">Analytics Talk by Justin Cutroni</a></p>
]]></description>
			<content:encoded><![CDATA[<p>I was recently inspired by a Tweet to write about how <a href="http://analytics.google.com">GA</a> tracks visitors that use a bookmark to access a site.</p>
<p>Simply put, Google Analytics will attribute a &#8216;bookmark&#8217; visit to the information in the Google Analytics campaign cookie.</p>
<p>Many people believe that GA tracks bookmark visits as (direct) traffic.  Google Analytics does not track bookmark traffic as (direct) traffic unless (direct) is the value in the cookie.  Whatever is stored in the campaign cookie becomes the source of the &#8216;bookmark&#8217; visit.</p>
<p>The cookie is named <code>__utmz</code>, I&#8217;ve talked about a few times, in my series on <a href="http://www.cutroni.com/blog/2006/11/10/google-analytics-campaign-tracking-pt-1-link-tagging/">Campaign Tracking</a> and my post on <a href="http://www.cutroni.com/blog/2009/03/18/updated-integrating-google-analytics-with-a-crm/">GA &#8211; CRM integration</a>.  __utmz always stores where the visitor came from (organic search, campaign referral, etc.)</p>
<p>How about a quick video to walk through an example and save me some typing.</p>
<p><object width="425" height="344"><param name="movie" value="http://www.youtube.com/v/XzR2jJc-Rws&#038;hl=en&#038;fs=1"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/XzR2jJc-Rws&#038;hl=en&#038;fs=1" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="425" height="344"></embed></object></p>
<p><a href="http://cutroni.com/blog/2009/05/20/how-google-analytics-tracks-bookmark-visits/">How Google Analytics Tracks &#8216;Bookmark&#8217; Visits</a> is a post from: <a href="http://cutroni.com/blog">Analytics Talk by Justin Cutroni</a></p>

<div class="sociable">

<ul>
	<li class="sociablefirst"><a rel="nofollow"  target="_blank" href="http://twitter.com/home?status=How%20Google%20Analytics%20Tracks%20%27Bookmark%27%20Visits%20-%20http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F05%2F20%2Fhow-google-analytics-tracks-bookmark-visits%2F" title="Twitter"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/twitter.png" title="Twitter" alt="Twitter" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F05%2F20%2Fhow-google-analytics-tracks-bookmark-visits%2F&amp;title=How%20Google%20Analytics%20Tracks%20%27Bookmark%27%20Visits" title="StumbleUpon"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/stumbleupon.png" title="StumbleUpon" alt="StumbleUpon" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F05%2F20%2Fhow-google-analytics-tracks-bookmark-visits%2F&amp;title=How%20Google%20Analytics%20Tracks%20%27Bookmark%27%20Visits&amp;bodytext=I%20was%20recently%20inspired%20by%20a%20Tweet%20to%20write%20about%20how%20GA%20tracks%20visitors%20that%20use%20a%20bookmark%20to%20access%20a%20site.%0A%0ASimply%20put%2C%20Google%20Analytics%20will%20attribute%20a%20%27bookmark%27%20visit%20to%20the%20information%20in%20the%20Google%20Analytics%20campaign%20cookie.%0A%0AMany%20people%20be" title="Digg"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/digg.png" title="Digg" alt="Digg" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://delicious.com/post?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F05%2F20%2Fhow-google-analytics-tracks-bookmark-visits%2F&amp;title=How%20Google%20Analytics%20Tracks%20%27Bookmark%27%20Visits&amp;notes=I%20was%20recently%20inspired%20by%20a%20Tweet%20to%20write%20about%20how%20GA%20tracks%20visitors%20that%20use%20a%20bookmark%20to%20access%20a%20site.%0A%0ASimply%20put%2C%20Google%20Analytics%20will%20attribute%20a%20%27bookmark%27%20visit%20to%20the%20information%20in%20the%20Google%20Analytics%20campaign%20cookie.%0A%0AMany%20people%20be" title="del.icio.us"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/delicious.png" title="del.icio.us" alt="del.icio.us" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.facebook.com/share.php?u=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F05%2F20%2Fhow-google-analytics-tracks-bookmark-visits%2F&amp;t=How%20Google%20Analytics%20Tracks%20%27Bookmark%27%20Visits" title="Facebook"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/facebook.png" title="Facebook" alt="Facebook" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.linkedin.com/shareArticle?mini=true&amp;url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F05%2F20%2Fhow-google-analytics-tracks-bookmark-visits%2F&amp;title=How%20Google%20Analytics%20Tracks%20%27Bookmark%27%20Visits&amp;source=Analytics+Talk+&amp;summary=I%20was%20recently%20inspired%20by%20a%20Tweet%20to%20write%20about%20how%20GA%20tracks%20visitors%20that%20use%20a%20bookmark%20to%20access%20a%20site.%0A%0ASimply%20put%2C%20Google%20Analytics%20will%20attribute%20a%20%27bookmark%27%20visit%20to%20the%20information%20in%20the%20Google%20Analytics%20campaign%20cookie.%0A%0AMany%20people%20be" title="LinkedIn"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/linkedin.png" title="LinkedIn" alt="LinkedIn" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.friendfeed.com/share?title=How%20Google%20Analytics%20Tracks%20%27Bookmark%27%20Visits&amp;link=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F05%2F20%2Fhow-google-analytics-tracks-bookmark-visits%2F" title="FriendFeed"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/friendfeed.png" title="FriendFeed" alt="FriendFeed" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://sphinn.com/index.php?c=post&amp;m=submit&amp;link=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F05%2F20%2Fhow-google-analytics-tracks-bookmark-visits%2F" title="Sphinn"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/sphinn.png" title="Sphinn" alt="Sphinn" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.google.com/bookmarks/mark?op=edit&amp;bkmk=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F05%2F20%2Fhow-google-analytics-tracks-bookmark-visits%2F&amp;title=How%20Google%20Analytics%20Tracks%20%27Bookmark%27%20Visits&amp;annotation=I%20was%20recently%20inspired%20by%20a%20Tweet%20to%20write%20about%20how%20GA%20tracks%20visitors%20that%20use%20a%20bookmark%20to%20access%20a%20site.%0A%0ASimply%20put%2C%20Google%20Analytics%20will%20attribute%20a%20%27bookmark%27%20visit%20to%20the%20information%20in%20the%20Google%20Analytics%20campaign%20cookie.%0A%0AMany%20people%20be" title="Google Bookmarks"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/googlebookmark.png" title="Google Bookmarks" alt="Google Bookmarks" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://reddit.com/submit?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F05%2F20%2Fhow-google-analytics-tracks-bookmark-visits%2F&amp;title=How%20Google%20Analytics%20Tracks%20%27Bookmark%27%20Visits" title="Reddit"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/reddit.png" title="Reddit" alt="Reddit" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="mailto:?subject=How%20Google%20Analytics%20Tracks%20%27Bookmark%27%20Visits&amp;body=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F05%2F20%2Fhow-google-analytics-tracks-bookmark-visits%2F" title="email"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/email_link.png" title="email" alt="email" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://technorati.com/faves?add=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F05%2F20%2Fhow-google-analytics-tracks-bookmark-visits%2F" title="Technorati"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/technorati.png" title="Technorati" alt="Technorati" /></a></li>
	<li class="sociablelast"><a rel="nofollow"  target="_blank" href="http://buzz.yahoo.com/submit/?submitUrl=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F05%2F20%2Fhow-google-analytics-tracks-bookmark-visits%2F&amp;submitHeadline=How%20Google%20Analytics%20Tracks%20%27Bookmark%27%20Visits&amp;submitSummary=I%20was%20recently%20inspired%20by%20a%20Tweet%20to%20write%20about%20how%20GA%20tracks%20visitors%20that%20use%20a%20bookmark%20to%20access%20a%20site.%0A%0ASimply%20put%2C%20Google%20Analytics%20will%20attribute%20a%20%27bookmark%27%20visit%20to%20the%20information%20in%20the%20Google%20Analytics%20campaign%20cookie.%0A%0AMany%20people%20be&amp;submitCategory=science&amp;submitAssetType=text" title="Yahoo! Buzz"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/yahoobuzz.png" title="Yahoo! Buzz" alt="Yahoo! Buzz" /></a></li>
</ul>
</div>
]]></content:encoded>
			<wfw:commentRss>http://cutroni.com/blog/2009/05/20/how-google-analytics-tracks-bookmark-visits/feed/</wfw:commentRss>
		<slash:comments>38</slash:comments>
		</item>
		<item>
		<title>Count Me Out: GA.JS Version</title>
		<link>http://cutroni.com/blog/2009/04/16/count-me-out-gajs-version/</link>
		<comments>http://cutroni.com/blog/2009/04/16/count-me-out-gajs-version/#comments</comments>
		<pubDate>Thu, 16 Apr 2009 19:28:35 +0000</pubDate>
		<dc:creator>Justin Cutroni</dc:creator>
				<category><![CDATA[Tips]]></category>
		<category><![CDATA[Tracking]]></category>
		<category><![CDATA[google-analytics]]></category>

		<guid isPermaLink="false">http://www.epikone.com/blog/?p=503</guid>
		<description><![CDATA[A while back I wrote a post called Count Me Out! that explained how to exclude Google Analytics data based on the custom segment value. My previous post was based on the old, urchin.js tracking code, and a lot of people have been waiting for an update. It&#8217;s taken a while, but here it is. [...]<p><a href="http://cutroni.com/blog/2009/04/16/count-me-out-gajs-version/">Count Me Out: GA.JS Version</a> is a post from: <a href="http://cutroni.com/blog">Analytics Talk by Justin Cutroni</a></p>
]]></description>
			<content:encoded><![CDATA[<p>A while back I wrote a post called <a href="http://www.cutroni.com/blog/2006/07/11/count-me-out/">Count Me Out!</a> that explained how to exclude Google Analytics data based on the custom segment value.</p>
<p>My previous post was based on the old, <code>urchin.js</code> tracking code, and a lot of people have been waiting for an update.  It&#8217;s taken a while, but here it is.</p>
<p>I will mention that my favorite way to exclude traffic from Google Analytics is using an IP exclude filter.  An IP based exclude filter is very accurate unless you having a changing IP.  The method below works best if you have a dynamic or changing IP address.</p>
<p><em><strong>Even if you&#8217;re not interested in this post, there is a fun &#8216;group activity&#8217; below. Please try it!</strong><br />
</em></p>
<p>The old version of this <del datetime="2009-04-16T01:23:04+00:00">hack</del> method required you to add a new page to your website.  That page would set the GA custom segment cookie (named <code>__utmv</code>) on your computer.</p>
<p>This technique works fine, but who wants to add a new page to their site?  It can be a pain.</p>
<p>I&#8217;ve simplified this technique by removing that page.  You can enter the JavaScript directly into your browser.</p>
<h2>Step 1: Set Custom Segment Cookie</h2>
<p>Go to the site that you are tracking with Google Analytics and view a page.</p>
<p>Copy the code below and paste it into the location bar of your browser and click &#8216;enter&#8217; on your keyboard.</p>
<p><iframe src="http://sandbox.epikone.us/justin/blog/count-me-out-1-line.txt" width="560" height="50"></iframe></p>
<p>You should see a message that says, &#8220;Custom segment has been set.  Time to create a filter.&#8221;</p>
<p>Here&#8217;s a tip, you can bookmark this JS to make it easy to reset the cookie in the future.  I set the cookie every time I fire up my browser.</p>
<h2>Step 2: Create Exclude Filter</h2>
<p>Next, create an exclude filter in Google Analytics to exclude the user defined segment (i.e. the cookie) you just created:</p>
<p><img src="http://www.cutroni.com/blog/wp-content/uploads/2008/01/20080119-remove-me-filter.png" alt="" title="Filter to exclude user defined cookie." width="463" height="381" class="aligncenter size-full wp-image-461" /></p>
<p>This filter will exclude anyone with a custom segment cookie with a value of &#8216;remove-me&#8217;.</p>
<p>Remember, cookies are specific to a browser and computer. If you use mulitple browsers or multiple computers you need to set the cookie using all the browsers on all the computers you use.</p>
<h2>Having Some Fun With This!</h2>
<p><img src="http://cutroni.com/blog/wp-content/uploads/picture-14.png" alt="" title="The user defined report in Google Analytics." width="186" height="170" class="alignright size-full wp-image-1033" /></p>
<p>You&#8217;ve probbaly figured out that you can set the custom segment cookie on anyone&#8217;s website as long as they&#8217;re using GA.  This means that you can add data to their User Defined report.  Let&#8217;s try this on my site!</p>
<p>Navigate to <a href="http://www.cutroni.com/blog">www.cutroni.com/blog</a> and place the following code in the location bar of your browser after the page has loaded.  Change FOO to whatever you want and press enter on your keyword.  That&#8217;s it.  You&#8217;re now in my data.</p>
<p><iframe src="http://sandbox.epikone.us/justin/blog/count-me-out-prank.txt" width="560" height="50"></iframe></p>
<p>I&#8217;ll post some of the more popular and creative values in <a href="http://www.twitter.com/justincutroni">Twitter</a> and maybe here at a later date.</p>
<p>Please try to keep it clean.  I often review data with my 4 year old son :)</p>
<h2>Thoughts on the Old Method</h2>
<p>The old version of this technique uses a form to set the custom segment cookie which is pretty handy if you have a lot of people in remote locations that need to be excluded from the data.  Just send all your coworkers, contractors, etc. a link to the page and ask them to set the cookie on their computer.  It&#8217;s a little easier than asking them to paste JS into their browser.</p>
<p>If you&#8217;re interested in using this technique here is a new version of the page and the process.</p>
<p><strong>Step 1</strong>: Create a new page on your site using the code below.</p>
<p>** Note ** The information below is in an iFrame.  If you receive this post via email you may not see the contents.</p>
<p><iframe src="http://sandbox.epikone.us/justin/blog/count-me-out.txt" width="560" height="400"></iframe></p>
<p><strong>Step 2:</strong> Go to the new page you just added, fill out the form, and click the &#8216;Create Cookie&#8217; button.  Keep track of the value you enter into the form, you need it for step 3.</p>
<p><strong>Step 3:</strong> Finally, create an exclude filter in Google Analytics to exclude the value that you entered into the form.  Remember, you need to use a regular expression for the filter field.  So if you entered &#8216;remove-me&#8217; in the form, enter &#8216;remove-me&#8217; as the Filter Field.</p>
<p>That&#8217;s it.  Sorry for the lame post, but I&#8217;m trying to update a lot of the old code and posts on the site.</p>
<p><a href="http://cutroni.com/blog/2009/04/16/count-me-out-gajs-version/">Count Me Out: GA.JS Version</a> is a post from: <a href="http://cutroni.com/blog">Analytics Talk by Justin Cutroni</a></p>

<div class="sociable">

<ul>
	<li class="sociablefirst"><a rel="nofollow"  target="_blank" href="http://twitter.com/home?status=Count%20Me%20Out%3A%20GA.JS%20Version%20-%20http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F04%2F16%2Fcount-me-out-gajs-version%2F" title="Twitter"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/twitter.png" title="Twitter" alt="Twitter" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F04%2F16%2Fcount-me-out-gajs-version%2F&amp;title=Count%20Me%20Out%3A%20GA.JS%20Version" title="StumbleUpon"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/stumbleupon.png" title="StumbleUpon" alt="StumbleUpon" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F04%2F16%2Fcount-me-out-gajs-version%2F&amp;title=Count%20Me%20Out%3A%20GA.JS%20Version&amp;bodytext=A%20while%20back%20I%20wrote%20a%20post%20called%20Count%20Me%20Out%21%20that%20explained%20how%20to%20exclude%20Google%20Analytics%20data%20based%20on%20the%20custom%20segment%20value.%0A%0AMy%20previous%20post%20was%20based%20on%20the%20old%2C%20urchin.js%20tracking%20code%2C%20and%20a%20lot%20of%20people%20have%20been%20waiting%20for%20an%20upda" title="Digg"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/digg.png" title="Digg" alt="Digg" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://delicious.com/post?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F04%2F16%2Fcount-me-out-gajs-version%2F&amp;title=Count%20Me%20Out%3A%20GA.JS%20Version&amp;notes=A%20while%20back%20I%20wrote%20a%20post%20called%20Count%20Me%20Out%21%20that%20explained%20how%20to%20exclude%20Google%20Analytics%20data%20based%20on%20the%20custom%20segment%20value.%0A%0AMy%20previous%20post%20was%20based%20on%20the%20old%2C%20urchin.js%20tracking%20code%2C%20and%20a%20lot%20of%20people%20have%20been%20waiting%20for%20an%20upda" title="del.icio.us"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/delicious.png" title="del.icio.us" alt="del.icio.us" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.facebook.com/share.php?u=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F04%2F16%2Fcount-me-out-gajs-version%2F&amp;t=Count%20Me%20Out%3A%20GA.JS%20Version" title="Facebook"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/facebook.png" title="Facebook" alt="Facebook" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.linkedin.com/shareArticle?mini=true&amp;url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F04%2F16%2Fcount-me-out-gajs-version%2F&amp;title=Count%20Me%20Out%3A%20GA.JS%20Version&amp;source=Analytics+Talk+&amp;summary=A%20while%20back%20I%20wrote%20a%20post%20called%20Count%20Me%20Out%21%20that%20explained%20how%20to%20exclude%20Google%20Analytics%20data%20based%20on%20the%20custom%20segment%20value.%0A%0AMy%20previous%20post%20was%20based%20on%20the%20old%2C%20urchin.js%20tracking%20code%2C%20and%20a%20lot%20of%20people%20have%20been%20waiting%20for%20an%20upda" title="LinkedIn"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/linkedin.png" title="LinkedIn" alt="LinkedIn" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.friendfeed.com/share?title=Count%20Me%20Out%3A%20GA.JS%20Version&amp;link=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F04%2F16%2Fcount-me-out-gajs-version%2F" title="FriendFeed"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/friendfeed.png" title="FriendFeed" alt="FriendFeed" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://sphinn.com/index.php?c=post&amp;m=submit&amp;link=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F04%2F16%2Fcount-me-out-gajs-version%2F" title="Sphinn"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/sphinn.png" title="Sphinn" alt="Sphinn" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.google.com/bookmarks/mark?op=edit&amp;bkmk=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F04%2F16%2Fcount-me-out-gajs-version%2F&amp;title=Count%20Me%20Out%3A%20GA.JS%20Version&amp;annotation=A%20while%20back%20I%20wrote%20a%20post%20called%20Count%20Me%20Out%21%20that%20explained%20how%20to%20exclude%20Google%20Analytics%20data%20based%20on%20the%20custom%20segment%20value.%0A%0AMy%20previous%20post%20was%20based%20on%20the%20old%2C%20urchin.js%20tracking%20code%2C%20and%20a%20lot%20of%20people%20have%20been%20waiting%20for%20an%20upda" title="Google Bookmarks"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/googlebookmark.png" title="Google Bookmarks" alt="Google Bookmarks" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://reddit.com/submit?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F04%2F16%2Fcount-me-out-gajs-version%2F&amp;title=Count%20Me%20Out%3A%20GA.JS%20Version" title="Reddit"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/reddit.png" title="Reddit" alt="Reddit" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="mailto:?subject=Count%20Me%20Out%3A%20GA.JS%20Version&amp;body=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F04%2F16%2Fcount-me-out-gajs-version%2F" title="email"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/email_link.png" title="email" alt="email" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://technorati.com/faves?add=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F04%2F16%2Fcount-me-out-gajs-version%2F" title="Technorati"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/technorati.png" title="Technorati" alt="Technorati" /></a></li>
	<li class="sociablelast"><a rel="nofollow"  target="_blank" href="http://buzz.yahoo.com/submit/?submitUrl=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F04%2F16%2Fcount-me-out-gajs-version%2F&amp;submitHeadline=Count%20Me%20Out%3A%20GA.JS%20Version&amp;submitSummary=A%20while%20back%20I%20wrote%20a%20post%20called%20Count%20Me%20Out%21%20that%20explained%20how%20to%20exclude%20Google%20Analytics%20data%20based%20on%20the%20custom%20segment%20value.%0A%0AMy%20previous%20post%20was%20based%20on%20the%20old%2C%20urchin.js%20tracking%20code%2C%20and%20a%20lot%20of%20people%20have%20been%20waiting%20for%20an%20upda&amp;submitCategory=science&amp;submitAssetType=text" title="Yahoo! Buzz"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/yahoobuzz.png" title="Yahoo! Buzz" alt="Yahoo! Buzz" /></a></li>
</ul>
</div>
]]></content:encoded>
			<wfw:commentRss>http://cutroni.com/blog/2009/04/16/count-me-out-gajs-version/feed/</wfw:commentRss>
		<slash:comments>28</slash:comments>
		</item>
		<item>
		<title>UPDATED: Integrating Google Analytics with a CRM</title>
		<link>http://cutroni.com/blog/2009/03/18/updated-integrating-google-analytics-with-a-crm/</link>
		<comments>http://cutroni.com/blog/2009/03/18/updated-integrating-google-analytics-with-a-crm/#comments</comments>
		<pubDate>Wed, 18 Mar 2009 16:53:47 +0000</pubDate>
		<dc:creator>Justin Cutroni</dc:creator>
				<category><![CDATA[Tips]]></category>
		<category><![CDATA[Tracking]]></category>
		<category><![CDATA[configuration]]></category>
		<category><![CDATA[implementation]]></category>

		<guid isPermaLink="false">http://www.epikone.com/blog/?p=981</guid>
		<description><![CDATA[A while back I wrote a post about how you can integrate Google Analytics with a CRM system. That posts referenced the old urchin.js code and is in need of an update. Plus a lot of people have been asking me about different integration options and I thought it would be a good time to [...]<p><a href="http://cutroni.com/blog/2009/03/18/updated-integrating-google-analytics-with-a-crm/">UPDATED: Integrating Google Analytics with a CRM</a> is a post from: <a href="http://cutroni.com/blog">Analytics Talk by Justin Cutroni</a></p>
]]></description>
			<content:encoded><![CDATA[<p>A while back I wrote a post about how you can <a href="http://www.cutroni.com/blog/2007/10/29/integrating-google-analytics-with-a-crm/">integrate Google Analytics with a CRM system</a>.  That posts referenced the old <code>urchin.js</code> code and is in need of an update.  Plus a lot of people have been asking me about different integration options and I thought it would be a good time to revisit the topic.</p>
<p>So here it is, an update.  I&#8217;m not going to re-do the entire post, just a few key points.</p>
<h2>Why Do This?</h2>
<p>This entire <del datetime="2009-03-16T21:27:35+00:00">hack</del> configuration is based on one simple idea: to build a more robust view of customers/prospects/leads/whatever-you-call-them.  The more information we know about people that we sell to the more we can adjust our marketing.  This technique let&#8217;s us combine where the visitor came from (referral, campaign, direct, search engine) and how often they&#8217;ve been to the site with CRM data.</p>
<h2>How It Works</h2>
<p>We&#8217;re going to extract data from the GA tracking cookies and add it to a lead generation form. The GA data will be stored in hidden form elements that the visitor can not see.  When the visitor submits the form the GA will be connected to the other information that the visitor entered into the form (usually name, contact information, etc.).</p>
<p><img class="aligncenter size-full wp-image-1002" title="Adding GA data to a CRM" src="http://cutroni.com/blog/wp-content/uploads/crm-process.jpg" alt="Adding GA data to a CRM" width="500" height="230" /></p>
<p>Here&#8217;s the data that we&#8217;re going to pull from the GA cookies:</p>
<p>* Current referral information (i.e. where the visitor came from)<br />
* Custom segment value (if it exists)<br />
* How many times the visitor has been to the site</p>
<p>You&#8217;re probably wondering why we&#8217;re not extracting the data via the GA API.  More on that in a minute.</p>
<h2>The Code</h2>
<p>Here it is, the updated code:</p>
<p><iframe src="http://www.cutroni.com/blog/wp-content/uploads/2009/crm-gajs.php" height="150" width="550"></iframe></p>
<p>The new code differs from the original code in three ways:</p>
<p>First, the inclusion of <code>ga.js</code>.  No explanation needed there.</p>
<p>The second change is the addition of the <code>_uGC()</code> function.  This function was in the original <code>urchin.js</code>, and because I don&#8217;t include that file I need to include the code in the script.</p>
<p>The function is used to  parse pieces of data and return certain parts.  For example, I use to to parse the cookies (which are just a string) and return the value of the campaign cookie (<code>__utmz</code>), the custom segment cookie (<code>_utmv</code>) and the visitor identification cookie (<code>__utma</code>).</p>
<p>Finally, I added some new functionality to include this visitor&#8217;s number of visits.  This data is pulled from the <code>__utma</code> cookie (which identifies the visitor).  The last integer in __utma is actually a visit counter.  I think it is interesting to understand behavior based on frequency so I added this nugget of data.</p>
<p>If you want to see the code in action try this:</p>
<p><iframe src="http://www.cutroni.com/blog/wp-content/uploads/crm-gajs.php" width="550" height="150"></iframe></p>
<p>In my previous post I included a <a href="http://www.cutroni.com/blog/2007/10/29/integrating-google-analytics-with-a-crm/">reference section</a> that documents the format of the campaign cookie and the<code> _uGC()</code> function.  Check it out if you&#8217;re looking for more technical information.</p>
<h2>An Alternate Approach</h2>
<p><img class="alignright size-thumbnail wp-image-995" title="You can process this data at the server level." src="http://www.cutroni.com/blog/wp-content/uploads/servers-150x150.jpg" alt="" hspace="7" width="150" height="150" /></p>
<p>Remember, all the data we&#8217;re pulling is in first party cookies.  This means that you could extract the info at the server level rather than the browser level (first party cookies are available to server side code).</p>
<p>You don&#8217;t need to do this in JavaScript, as I did.  You could use <a href="http://en.wikipedia.org/wiki/ColdFusion">ColdFusion</a>, <a href="http://en.wikipedia.org/wiki/Php">PHP</a>, <a href="http://en.wikipedia.org/wiki/.NET_Framework">.NET</a> or some other server side language.</p>
<p>I&#8217;m just trying to provide some inspiration here :)</p>
<h2>What About the Google Analytics API?</h2>
<p>I&#8217;m sure there are a lot of people out there wondering about the GA API and why I don&#8217;t just use it to pull data out from GA.  The reason is the data in GA is all anonymous, aggregated data.  There&#8217;s no way to reach into GA and say, &#8220;tell me where John Doe came from.&#8221;   That&#8217;s why we pull data from the cookie, because we can combine it with a visitor&#8217;s info when they supply it.</p>
<p>Sure, it is possible to pull out GA data and place it in a CRM (like traffic from an email campaign, bounce rate from paid search, etc.) but it&#8217;s tough to identify individuals in that data.</p>
<p>Is it impossible?  No, not from a technical standpoint.  You would need to place a unique identifier in GA to link the data.</p>
<p>But we&#8217;re getting into a risky area here.</p>
<p>Remember, it is against the GA terms of service to capture data in GA that identifies an individual.  This could be an email address or database ID number.  Not my rule, Google&#8217;s, and they will crack down.</p>
<p>I&#8217;d be interested to hear people&#8217;s thoughts on this.  Feel free to comment!</p>
<p><a href="http://cutroni.com/blog/2009/03/18/updated-integrating-google-analytics-with-a-crm/">UPDATED: Integrating Google Analytics with a CRM</a> is a post from: <a href="http://cutroni.com/blog">Analytics Talk by Justin Cutroni</a></p>

<div class="sociable">

<ul>
	<li class="sociablefirst"><a rel="nofollow"  target="_blank" href="http://twitter.com/home?status=UPDATED%3A%20Integrating%20Google%20Analytics%20with%20a%20CRM%20-%20http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F03%2F18%2Fupdated-integrating-google-analytics-with-a-crm%2F" title="Twitter"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/twitter.png" title="Twitter" alt="Twitter" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F03%2F18%2Fupdated-integrating-google-analytics-with-a-crm%2F&amp;title=UPDATED%3A%20Integrating%20Google%20Analytics%20with%20a%20CRM" title="StumbleUpon"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/stumbleupon.png" title="StumbleUpon" alt="StumbleUpon" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F03%2F18%2Fupdated-integrating-google-analytics-with-a-crm%2F&amp;title=UPDATED%3A%20Integrating%20Google%20Analytics%20with%20a%20CRM&amp;bodytext=A%20while%20back%20I%20wrote%20a%20post%20about%20how%20you%20can%20integrate%20Google%20Analytics%20with%20a%20CRM%20system.%20%20That%20posts%20referenced%20the%20old%20urchin.js%20code%20and%20is%20in%20need%20of%20an%20update.%20%20Plus%20a%20lot%20of%20people%20have%20been%20asking%20me%20about%20different%20integration%20options%20and%20I" title="Digg"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/digg.png" title="Digg" alt="Digg" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://delicious.com/post?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F03%2F18%2Fupdated-integrating-google-analytics-with-a-crm%2F&amp;title=UPDATED%3A%20Integrating%20Google%20Analytics%20with%20a%20CRM&amp;notes=A%20while%20back%20I%20wrote%20a%20post%20about%20how%20you%20can%20integrate%20Google%20Analytics%20with%20a%20CRM%20system.%20%20That%20posts%20referenced%20the%20old%20urchin.js%20code%20and%20is%20in%20need%20of%20an%20update.%20%20Plus%20a%20lot%20of%20people%20have%20been%20asking%20me%20about%20different%20integration%20options%20and%20I" title="del.icio.us"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/delicious.png" title="del.icio.us" alt="del.icio.us" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.facebook.com/share.php?u=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F03%2F18%2Fupdated-integrating-google-analytics-with-a-crm%2F&amp;t=UPDATED%3A%20Integrating%20Google%20Analytics%20with%20a%20CRM" title="Facebook"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/facebook.png" title="Facebook" alt="Facebook" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.linkedin.com/shareArticle?mini=true&amp;url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F03%2F18%2Fupdated-integrating-google-analytics-with-a-crm%2F&amp;title=UPDATED%3A%20Integrating%20Google%20Analytics%20with%20a%20CRM&amp;source=Analytics+Talk+&amp;summary=A%20while%20back%20I%20wrote%20a%20post%20about%20how%20you%20can%20integrate%20Google%20Analytics%20with%20a%20CRM%20system.%20%20That%20posts%20referenced%20the%20old%20urchin.js%20code%20and%20is%20in%20need%20of%20an%20update.%20%20Plus%20a%20lot%20of%20people%20have%20been%20asking%20me%20about%20different%20integration%20options%20and%20I" title="LinkedIn"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/linkedin.png" title="LinkedIn" alt="LinkedIn" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.friendfeed.com/share?title=UPDATED%3A%20Integrating%20Google%20Analytics%20with%20a%20CRM&amp;link=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F03%2F18%2Fupdated-integrating-google-analytics-with-a-crm%2F" title="FriendFeed"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/friendfeed.png" title="FriendFeed" alt="FriendFeed" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://sphinn.com/index.php?c=post&amp;m=submit&amp;link=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F03%2F18%2Fupdated-integrating-google-analytics-with-a-crm%2F" title="Sphinn"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/sphinn.png" title="Sphinn" alt="Sphinn" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.google.com/bookmarks/mark?op=edit&amp;bkmk=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F03%2F18%2Fupdated-integrating-google-analytics-with-a-crm%2F&amp;title=UPDATED%3A%20Integrating%20Google%20Analytics%20with%20a%20CRM&amp;annotation=A%20while%20back%20I%20wrote%20a%20post%20about%20how%20you%20can%20integrate%20Google%20Analytics%20with%20a%20CRM%20system.%20%20That%20posts%20referenced%20the%20old%20urchin.js%20code%20and%20is%20in%20need%20of%20an%20update.%20%20Plus%20a%20lot%20of%20people%20have%20been%20asking%20me%20about%20different%20integration%20options%20and%20I" title="Google Bookmarks"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/googlebookmark.png" title="Google Bookmarks" alt="Google Bookmarks" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://reddit.com/submit?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F03%2F18%2Fupdated-integrating-google-analytics-with-a-crm%2F&amp;title=UPDATED%3A%20Integrating%20Google%20Analytics%20with%20a%20CRM" title="Reddit"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/reddit.png" title="Reddit" alt="Reddit" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="mailto:?subject=UPDATED%3A%20Integrating%20Google%20Analytics%20with%20a%20CRM&amp;body=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F03%2F18%2Fupdated-integrating-google-analytics-with-a-crm%2F" title="email"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/email_link.png" title="email" alt="email" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://technorati.com/faves?add=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F03%2F18%2Fupdated-integrating-google-analytics-with-a-crm%2F" title="Technorati"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/technorati.png" title="Technorati" alt="Technorati" /></a></li>
	<li class="sociablelast"><a rel="nofollow"  target="_blank" href="http://buzz.yahoo.com/submit/?submitUrl=http%3A%2F%2Fcutroni.com%2Fblog%2F2009%2F03%2F18%2Fupdated-integrating-google-analytics-with-a-crm%2F&amp;submitHeadline=UPDATED%3A%20Integrating%20Google%20Analytics%20with%20a%20CRM&amp;submitSummary=A%20while%20back%20I%20wrote%20a%20post%20about%20how%20you%20can%20integrate%20Google%20Analytics%20with%20a%20CRM%20system.%20%20That%20posts%20referenced%20the%20old%20urchin.js%20code%20and%20is%20in%20need%20of%20an%20update.%20%20Plus%20a%20lot%20of%20people%20have%20been%20asking%20me%20about%20different%20integration%20options%20and%20I&amp;submitCategory=science&amp;submitAssetType=text" title="Yahoo! Buzz"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/yahoobuzz.png" title="Yahoo! Buzz" alt="Yahoo! Buzz" /></a></li>
</ul>
</div>
]]></content:encoded>
			<wfw:commentRss>http://cutroni.com/blog/2009/03/18/updated-integrating-google-analytics-with-a-crm/feed/</wfw:commentRss>
		<slash:comments>30</slash:comments>
		</item>
		<item>
		<title>Tracking Email with Google Analytics</title>
		<link>http://cutroni.com/blog/2008/11/04/email-tracking-with-google-analytics/</link>
		<comments>http://cutroni.com/blog/2008/11/04/email-tracking-with-google-analytics/#comments</comments>
		<pubDate>Wed, 05 Nov 2008 02:35:30 +0000</pubDate>
		<dc:creator>Justin Cutroni</dc:creator>
				<category><![CDATA[Analysis]]></category>
		<category><![CDATA[Campaign Tracking]]></category>
		<category><![CDATA[Tracking]]></category>
		<category><![CDATA[Web Analytics]]></category>
		<category><![CDATA[camapign tracking]]></category>
		<category><![CDATA[email-marketing]]></category>
		<category><![CDATA[email-tracking]]></category>
		<category><![CDATA[link-tagging]]></category>

		<guid isPermaLink="false">http://www.epikone.com/blog/?p=764</guid>
		<description><![CDATA[In the past few weeks I&#8217;ve gotten a lot of questions about how to track email with Google Analytics. While I did cover the broad topic of online ad tracking in a previous series of posts, email tracking has certain nuances that I think should be addressed. The Concept Tracking email campaigns in Google Analytics [...]<p><a href="http://cutroni.com/blog/2008/11/04/email-tracking-with-google-analytics/">Tracking Email with Google Analytics</a> is a post from: <a href="http://cutroni.com/blog">Analytics Talk by Justin Cutroni</a></p>
]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.cutroni.com/blog/wp-content/uploads/2008/10/emailicon-150x150.png" alt="" title="Email tracking with Google Analytics" width="150" height="150" class="alignright size-thumbnail wp-image-778" /></p>
<p>In the past few weeks I&#8217;ve gotten a lot of questions about how to track email with <a href="http://google.com/analytics">Google Analytics</a>. While I did cover the broad topic of online ad tracking in a<a href="http://www.cutroni.com/blog/2006/11/10/google-analytics-campaign-tracking-pt-0-an-overview/"> previous series of posts</a>, email tracking has certain nuances that I think should be addressed.</p>
<h2>The Concept</h2>
<p>Tracking email campaigns in Google Analytics is done using a process called link tagging.  This process is the manipulation of the links in your emails.  Here&#8217;s a sample link that might appear in an email:</p>
<p><code>http://www.mysite.com/page.php</code></p>
<p>To track it with Google Analytics it would be modified like this:</p>
<p><code>http://www.mysite.com/page.php</code><span style="color:red;"><code>?utm_campaign=fall-sale&amp;utm_medium=email&amp;utm_source=female-list</code></span></p>
<p>And another email link that looks like this:</p>
<p><code>http://www.mysite.com/page.php?prodid=100</code></p>
<p>Should be modified like this:</p>
<p><code>http://www.mysite.com/page.php?prodid=100</code><span style="color:red;"><code>&amp;utm_campaign=fall-sale&amp;utm_medium=email&amp;utm_source=female-list</code></span></p>
<p>When someone lands on your site after clicking on a tagged link, GA removes the information from the URL and stores it in a cookie.  Because the info now resides on your machine (in the cookie) GA can associate all visitor actions (like conversions and transactions) with the email. Pretty slick, huh?</p>
<h2>How Link Tagging Works</h2>
<p><img src="http://www.cutroni.com/blog/wp-content/uploads/2008/10/55067140-150x150.jpg" alt="" title="Google Analytics link tagging" width="150" height="150" class="alignright size-thumbnail wp-image-781" hspace="7" /></p>
<p>What is all that info I added to the URL?  They&#8217;re called link tagging parameters.  The name of the parameter is on the left side of the equal sign and the value of the parameter is on the right side.</p>
<p>Each parameter represents a different attribute of your email.  Looking at the example above we can identifiy the following parameters and their values:</p>
<p>utm_campaign=<span style="color:red;">fall-sale</span><br />
utm_medium=<span style="color:red;">email</span><br />
utm_source=<span style="color:red;">female-list</span></p>
<p>Each one is identified by the Google Analytics tracking code and helps GA understand that the visitor arrived on your site via an email.</p>
<p>You must use the parameters that Google provides.  However, you can specify any value for each parameter.  This is where the real power lies.  By using your own values for each parameter you can add markting information, that is specific to your business, to GA.  We&#8217;ll get to where that information appears in a second.</p>
<p>[ NOTE: All you advanced user may be calling my bluff here.  You can rename the link tagging parameters that GA uses, but it is an advanced technique that requires a change to the GA tracking code.  I'm not going to cover it in this post but you can learn more in the  <a href="http://www.google.com/support/googleanalytics/bin/answer.py?answer=55577&#038;topic=10998">GA help section</a>.  ]</p>
<p>Let&#8217;s look at each link tagging parameters and some of the logical values for each.</p>
<h3>utm_campaign</h3>
<p>This parameter identifies the marketing campaign that the email belongs to.  It may be that this email is just one part of a bigger online marketing strategy.  For example, you may be using paid search, some display advertising and this email to reach new prospects.  You can group this email with other marketing activities by using a common value of utm_campaign.</p>
<p>As for suggested values, use something that represents the campaign that your running.</p>
<h3>utm_medium</h3>
<p>The medium parameter describes how the message got the to visitor.  In the case of email I recommend that you always use the same value.  I like to use &#8216;email&#8217;.  It&#8217;s short and pretty darn descriptive.</p>
<p>Using a single value consolidates all email generated traffic into a single line item in the reports.</p>
<h3>utm_source</h3>
<p>This is where things get interesting.  Traditionally, in link tagging, the source is the &#8216;who&#8217; attribute.  It describes who you&#8217;re working with to push a message out.  But how does the concept of &#8216;who&#8217; map to an email?</p>
<p>When it comes to email I like to think of the &#8216;who&#8217; as the list of recipients that you&#8217;re sending the message to.  This may be a segment of your email list (like a specific gender segment, age segment of purchase history segment) or your entire email list.  For example, some potential utm_source values might be:</p>
<p>utm_source=<span style="color:red;">gender:female</span><br />
utm_source=<span style="color:red;">gender:all</span><br />
utm_source=<span style="color:red;">purchase:last-30-days</span><br />
utm_source=<span style="color:red;">purchase:last-60-days</span><br />
utm_source=<span style="color:red;">purchase:free-shipping-offer</span></p>
<p>The key here is that by identifying the segment in the utm_source parameter you&#8217;ll be able to measure the performance of that segment in GA.  You are segmenting your email list, right?</p>
<h3>utm_content</h3>
<p><img src="http://www.cutroni.com/blog/wp-content/uploads/2008/10/anylab-test.jpg" alt="" title="Testing email with Google Analytics." width="233" height="180" class="alignright size-medium wp-image-783" hspace="7" /></p>
<p>The final parameter is named utm_content and helps us test emails.  The content parameter identifies the actual content of the email.  So if you&#8217;re producing different versions of the email for an A/B test you can mesaure the performance of each by varying the value of utm_content.  For example:</p>
<p>utm_content=<span style="color:red;">free-shipping-offer</span><br />
utm_content=<span style="color:red;">20-off-offer</span><br />
utm_content=<span style="color:red;">product-creative</span><br />
utm_content=<span style="color:red;">value-creative</span></p>
<p>Some folks like to use utm_content to describe not only the version of the email that the recipient received, but also the actual location of the link in the email.</p>
<p>utm_content=<span style="color:red;">top-nav</span><br />
utm_content=<span style="color:red;">call-to-action</span><br />
utm_content=<span style="color:red;">image-link</span></p>
<p>Sometimes this can be overkill as it leads to a lot of very granular data.  Normally we just use this to measure which email variation performed better.</p>
<p>Think about how powerful this can be.  <span style="font-weight:bold;">Using utm_content and utm_source you can measure the performance of a specific message to a specific segment of your customer base (i.e. email list).</span>  This is a great way to measure if you&#8217;re sending the right message to the right person!</p>
<h2>How to Tag Your Links</h2>
<p>So now that we know what paramters we can use to track our email, how do we actually tag the links?  It starts by assigning a value to each parameters.  You could use the <a href="http://www.google.com/support/analytics/bin/answer.py?hl=en&#038;answer=55578">Google Analytics URL builder</a>: a free tool in the GA help center.  Just enter a value for each parameter, along with the URL from your email, and the tool will automatically generate a tagged URL that you can place in your email.</p>
<p><img src="http://www.cutroni.com/blog/wp-content/uploads/2008/10/picture-6.png" alt="" title="Google Analytics URL Builder" width="500" height="356" class="aligncenter size-full wp-image-800" hspace="7" /></p>
<p>But I find the URL builder can be cumbersome when tagging a large number of links. Just think of all the links that you might have in a single email!</p>
<p>Instead I use a small <a href="http://spreadsheets.google.com/ccc?key=p7c_HKcmspSUfEYSO0gskKw">Google Spreadsheet</a> that has a built in formula.  Just enter your campaign values in the columns, along with the URLs from your email, and drag a pre-programmed formula to automatically created your tagged URLs.  Then place the URLs in your email.</p>
<p><iframe src="http://spreadsheets.google.com/pub?key=p7c_HKcmspSUfEYSO0gskKw" width="500" height="250"></iframe></p>
<p>You may have noticed that a tagged URL is pretty ugly.  If you&#8217;re sending an HTML email to you can hide the long URL using an anchor tag, but if you&#8217;re using a text based email the recipient will see the entire crappy URL.  Try using a service like Tiny URL to hide the query string parameters.</p>
<p><img src="http://www.cutroni.com/blog/wp-content/uploads/2008/10/picture-1.png" alt="Use Tiny URL to shorten an ugly looking tagged URL." title="Tiny URL" width="343" height="129" class="size-full wp-image-766" hspace="7" /></p>
<p>I should note that some email platforms (the cool ones!) have begun to integrate GA link tagging into their tools.  Check with your email provider to see if they offer this service.</p>
<h2>The Reporting</h2>
<p>As I mentioned before, the values used in your link tags get pulled directly into Google Analytics.  Each parameter becomes the foundation for a report.  Let&#8217;s start with the Traffic Sources > Campaigns report:</p>
<p><img src="http://www.cutroni.com/blog/wp-content/uploads/2008/10/picture-3.png" alt="" title="Google Analytics Campaign Report" width="500" height="408" class="aligncenter size-full wp-image-770" hspace="7" /></p>
<p>This report lists all the values of your utm_campaign parameters.  You can measure the performance   of your email campaigns by finding the values you use for utm_campaign.  But be aware, this report will also contain the titles of your AdWords ad campaigns.  They&#8217;re automatically imported from AdWords.  Also remember that you might use the same value of utm_campaign in activities other than email.</p>
<p>Remember utm_source and utm_medium?  We can drill into a campaign to determine how the email medium, for a specific source, performed in the campaign.  Select a campaign by clicking on the name.  Then use the dimension drop down to view all the sources within the campaign.</p>
<p><img src="http://www.cutroni.com/blog/wp-content/uploads/2008/10/picture-7.png" alt="" title="Segmenting a campaign in Google Analytics." width="352" height="265" class="aligncenter size-full wp-image-812" /></p>
<p><img src="http://www.cutroni.com/blog/wp-content/uploads/2008/10/picture-8.png" alt="" title="Source value for a campaign." width="424" height="241" class="aligncenter size-full wp-image-814" /></p>
<p>The above report shows just one source within this campaign, but that&#8217;s all that was used.  The important thing to understand is how you can see certain sources, specifically email segments, contributed to the success of a campaign.</p>
<p>But what about evaluating a source across multiple campaigns?  Try using the Traffic Sources > All Traffic Sources report:</p>
<p><img src="http://www.cutroni.com/blog/wp-content/uploads/2008/10/picture-4.png" alt="" title="All Traffic Sources Report" width="500" height="432" class="aligncenter size-full wp-image-771" hspace="7" /></p>
<p>The first column shows all sources and mediums, so in our case we can see how a segment of the email list performed cross all campaigns.  We can quickly filter this report by &#8216;email&#8217;, the medium,  to identify how well a segment performed.  Remember how</p>
<p>What about the utm_content parameter?  Where can we find that data?  It&#8217;s in the Traffic Sources > Ad Versions report.</p>
<p><img src="http://www.cutroni.com/blog/wp-content/uploads/2008/10/picture-5.png" alt="" title="Google Analytics Ad Versions report" width="500" height="431" class="aligncenter size-full wp-image-775" hspace="7" /></p>
<p>Here&#8217;s where we can evaluate the performance of our different email variations.  The Ad Versions report not only contains the values from utm_content, but also the titles from your AdWords campaigns.  This is another piece of data that GA automatically pulls in.</p>
<p><img hspace="7" src="http://www.cutroni.com/blog/wp-content/uploads/2008/11/picture-3-300x191.png" alt="" title="Business process." width="300" height="191" class="alignright size-medium wp-image-907" /></p>
<p>And let&#8217;s not forget that all of these reports have three tabs full of metrics: site usage, goal conversions and ecommerce (if you choose to use ecommerce tracking).  All of these metrics provide insight into the sales or conversion process.</p>
<p><a href="http://www.kaushik.net/avinash/2007/08/standard-metrics-revisited-3-bounce-rate.html">Bounce rate</a> provides insight into the begining of the process.  A high bounce rate probably indicates a disconnect between the message in the email and the content on the landing page.</p>
<p>You can quickly switch to the goal conversions tab to measure the other end of the process by looking at the conversion rate for your email.  And if you&#8217;re using the ecommerce tab you can look at a metric like revenue to qualify the conversion rate.</p>
<h2>Don&#8217;t Forget the Pre Click Data</h2>
<p>While all this data is great, don&#8217;t forget that your email provider has a number of metrics that give insight into what happened before the visitor arrived on your site.  Such metrics include # emails sent, # emails received, # bounces, # emails opened and click throughs.</p>
<p>I know that metrics like open rate are inherently flawed due to the tracking technology, but you can&#8217;t evaluate things like subject line effectiveness using the data in GA.  Don&#8217;t be afraid to look at metrics like # of bounces when evaluating the performance of email.</p>
<h2>Create your Advanced Segment</h2>
<p>With GA&#8217;s new <a href="http://www.cutroni.com/blog/2008/10/22/google-analytics-advanced-segmentation/">Advanced Segments</a> we can really drill into the email traffic segment.  At the very least, you should create one advanced segment to evaluate email traffic.</p>
<p>To create the advanced segment use the &#8216;medium&#8217; dimension and enter a value of &#8216;email&#8217;.  Remember, &#8216;email&#8217; is the value we used for utm_medium in the link tagging.  Talk about coming full circle!</p>
<p><img src="http://www.cutroni.com/blog/wp-content/uploads/2008/11/picture-2.png" alt="" title="Creating a GA email segments" width="483" height="241" class="aligncenter size-full wp-image-906" /></p>
<p>Using an advanced segment helps you easily identify what content the email segment found interesting, if they converted, how well the progressed through various processes, etc.</p>
<h2>Common Problems</h2>
<p>The most common problem we see with link tagging is that people forget to tag their links.  Link tagging is usually a process related issue, not a tech related issue.  Before your organization sends any email communication make sure the links are tagged.</p>
<p>A simple way to test your links is to send the email to a few coworkers and ask them to click on some links.  In a few hours you should see the data in your GA reports.</p>
<p>The second most common problem has to do with redirects.  Many times a site may have a redirect that strips off the campaign tracking parameters.  The simple test mentioned above should tell you if you have a redirect issue.  Remember, when you click on a tagged link you should see your link tagging parameters in the URL of your site.</p>
<h2>A Note on Privacy</h2>
<p>A few people have mentioned that it is possible to add a visitor&#8217;s email address to your GA data using link tagging.  While this is possible, keep in mind the <a href="http://www.cutroni.com/blog/2007/06/26/understanding-the-google-analytics-terms-of-service/">GA terms of service</a> specifically forbids the collection of personally identifiable information with Google Analytics.</p>
<p>If you&#8217;re still reading, and you&#8217;re trying to understand how to track other types of online ads, then you may be interested in these posts:</p>
<ul>
<li><a href="http://www.cutroni.com/blog/2006/11/10/google-analytics-campaign-tracking-pt-1-link-tagging/">Google Analytics Campaign Tracking Pt. 1: Link Tagging</a></li>
<li><a href="http://www.cutroni.com/blog/2006/11/10/google-analytics-campaign-tracking-pt-2-the-epikone-link-tagging-tool/">Part 2: EpikOne Link Tagging Tool</a></li>
<li><a href="http://www.cutroni.com/blog/2007/03/04/google-analytics-campaign-tracking-part-3-reports-and-analysis/">Part 3: Reports and Analysis</a></li>
</ul>
<p><a href="http://cutroni.com/blog/2008/11/04/email-tracking-with-google-analytics/">Tracking Email with Google Analytics</a> is a post from: <a href="http://cutroni.com/blog">Analytics Talk by Justin Cutroni</a></p>

<div class="sociable">

<ul>
	<li class="sociablefirst"><a rel="nofollow"  target="_blank" href="http://twitter.com/home?status=Tracking%20Email%20with%20Google%20Analytics%20-%20http%3A%2F%2Fcutroni.com%2Fblog%2F2008%2F11%2F04%2Femail-tracking-with-google-analytics%2F" title="Twitter"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/twitter.png" title="Twitter" alt="Twitter" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2008%2F11%2F04%2Femail-tracking-with-google-analytics%2F&amp;title=Tracking%20Email%20with%20Google%20Analytics" title="StumbleUpon"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/stumbleupon.png" title="StumbleUpon" alt="StumbleUpon" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fcutroni.com%2Fblog%2F2008%2F11%2F04%2Femail-tracking-with-google-analytics%2F&amp;title=Tracking%20Email%20with%20Google%20Analytics&amp;bodytext=%0A%0AIn%20the%20past%20few%20weeks%20I%27ve%20gotten%20a%20lot%20of%20questions%20about%20how%20to%20track%20email%20with%20Google%20Analytics.%20While%20I%20did%20cover%20the%20broad%20topic%20of%20online%20ad%20tracking%20in%20a%20previous%20series%20of%20posts%2C%20email%20tracking%20has%20certain%20nuances%20that%20I%20think%20should%20be%20ad" title="Digg"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/digg.png" title="Digg" alt="Digg" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://delicious.com/post?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2008%2F11%2F04%2Femail-tracking-with-google-analytics%2F&amp;title=Tracking%20Email%20with%20Google%20Analytics&amp;notes=%0A%0AIn%20the%20past%20few%20weeks%20I%27ve%20gotten%20a%20lot%20of%20questions%20about%20how%20to%20track%20email%20with%20Google%20Analytics.%20While%20I%20did%20cover%20the%20broad%20topic%20of%20online%20ad%20tracking%20in%20a%20previous%20series%20of%20posts%2C%20email%20tracking%20has%20certain%20nuances%20that%20I%20think%20should%20be%20ad" title="del.icio.us"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/delicious.png" title="del.icio.us" alt="del.icio.us" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.facebook.com/share.php?u=http%3A%2F%2Fcutroni.com%2Fblog%2F2008%2F11%2F04%2Femail-tracking-with-google-analytics%2F&amp;t=Tracking%20Email%20with%20Google%20Analytics" title="Facebook"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/facebook.png" title="Facebook" alt="Facebook" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.linkedin.com/shareArticle?mini=true&amp;url=http%3A%2F%2Fcutroni.com%2Fblog%2F2008%2F11%2F04%2Femail-tracking-with-google-analytics%2F&amp;title=Tracking%20Email%20with%20Google%20Analytics&amp;source=Analytics+Talk+&amp;summary=%0A%0AIn%20the%20past%20few%20weeks%20I%27ve%20gotten%20a%20lot%20of%20questions%20about%20how%20to%20track%20email%20with%20Google%20Analytics.%20While%20I%20did%20cover%20the%20broad%20topic%20of%20online%20ad%20tracking%20in%20a%20previous%20series%20of%20posts%2C%20email%20tracking%20has%20certain%20nuances%20that%20I%20think%20should%20be%20ad" title="LinkedIn"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/linkedin.png" title="LinkedIn" alt="LinkedIn" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.friendfeed.com/share?title=Tracking%20Email%20with%20Google%20Analytics&amp;link=http%3A%2F%2Fcutroni.com%2Fblog%2F2008%2F11%2F04%2Femail-tracking-with-google-analytics%2F" title="FriendFeed"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/friendfeed.png" title="FriendFeed" alt="FriendFeed" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://sphinn.com/index.php?c=post&amp;m=submit&amp;link=http%3A%2F%2Fcutroni.com%2Fblog%2F2008%2F11%2F04%2Femail-tracking-with-google-analytics%2F" title="Sphinn"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/sphinn.png" title="Sphinn" alt="Sphinn" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.google.com/bookmarks/mark?op=edit&amp;bkmk=http%3A%2F%2Fcutroni.com%2Fblog%2F2008%2F11%2F04%2Femail-tracking-with-google-analytics%2F&amp;title=Tracking%20Email%20with%20Google%20Analytics&amp;annotation=%0A%0AIn%20the%20past%20few%20weeks%20I%27ve%20gotten%20a%20lot%20of%20questions%20about%20how%20to%20track%20email%20with%20Google%20Analytics.%20While%20I%20did%20cover%20the%20broad%20topic%20of%20online%20ad%20tracking%20in%20a%20previous%20series%20of%20posts%2C%20email%20tracking%20has%20certain%20nuances%20that%20I%20think%20should%20be%20ad" title="Google Bookmarks"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/googlebookmark.png" title="Google Bookmarks" alt="Google Bookmarks" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://reddit.com/submit?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2008%2F11%2F04%2Femail-tracking-with-google-analytics%2F&amp;title=Tracking%20Email%20with%20Google%20Analytics" title="Reddit"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/reddit.png" title="Reddit" alt="Reddit" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="mailto:?subject=Tracking%20Email%20with%20Google%20Analytics&amp;body=http%3A%2F%2Fcutroni.com%2Fblog%2F2008%2F11%2F04%2Femail-tracking-with-google-analytics%2F" title="email"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/email_link.png" title="email" alt="email" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://technorati.com/faves?add=http%3A%2F%2Fcutroni.com%2Fblog%2F2008%2F11%2F04%2Femail-tracking-with-google-analytics%2F" title="Technorati"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/technorati.png" title="Technorati" alt="Technorati" /></a></li>
	<li class="sociablelast"><a rel="nofollow"  target="_blank" href="http://buzz.yahoo.com/submit/?submitUrl=http%3A%2F%2Fcutroni.com%2Fblog%2F2008%2F11%2F04%2Femail-tracking-with-google-analytics%2F&amp;submitHeadline=Tracking%20Email%20with%20Google%20Analytics&amp;submitSummary=%0A%0AIn%20the%20past%20few%20weeks%20I%27ve%20gotten%20a%20lot%20of%20questions%20about%20how%20to%20track%20email%20with%20Google%20Analytics.%20While%20I%20did%20cover%20the%20broad%20topic%20of%20online%20ad%20tracking%20in%20a%20previous%20series%20of%20posts%2C%20email%20tracking%20has%20certain%20nuances%20that%20I%20think%20should%20be%20ad&amp;submitCategory=science&amp;submitAssetType=text" title="Yahoo! Buzz"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/yahoobuzz.png" title="Yahoo! Buzz" alt="Yahoo! Buzz" /></a></li>
</ul>
</div>
]]></content:encoded>
			<wfw:commentRss>http://cutroni.com/blog/2008/11/04/email-tracking-with-google-analytics/feed/</wfw:commentRss>
		<slash:comments>72</slash:comments>
		</item>
		<item>
		<title>Tracking YouTube Videos with Google Analytics</title>
		<link>http://cutroni.com/blog/2008/07/29/tracking-youttube-videos-with-google-analytics/</link>
		<comments>http://cutroni.com/blog/2008/07/29/tracking-youttube-videos-with-google-analytics/#comments</comments>
		<pubDate>Tue, 29 Jul 2008 19:13:15 +0000</pubDate>
		<dc:creator>Justin Cutroni</dc:creator>
				<category><![CDATA[Campaign Tracking]]></category>
		<category><![CDATA[Event Tracking]]></category>
		<category><![CDATA[Tracking]]></category>
		<category><![CDATA[google-analytics]]></category>
		<category><![CDATA[video-tracking]]></category>
		<category><![CDATA[Web Analytics]]></category>
		<category><![CDATA[web-2.0]]></category>

		<guid isPermaLink="false">http://www.epikone.com/blog/2008/07/29/tracking-youttube-videos-with-google-analytics/</guid>
		<description><![CDATA[A while back, Google Analytics and YouTube introduced YouTube Insight, a tool to provide more information about the people viewing your videos on www.youtube.com. It&#8217;s pretty cool stuff and if you&#8217;re posting videos to YouTube it provides a lot of great information. But what about YouTube videos that are embedded in a site? What&#8217;s the [...]<p><a href="http://cutroni.com/blog/2008/07/29/tracking-youttube-videos-with-google-analytics/">Tracking YouTube Videos with Google Analytics</a> is a post from: <a href="http://cutroni.com/blog">Analytics Talk by Justin Cutroni</a></p>
]]></description>
			<content:encoded><![CDATA[<p>A while back, Google Analytics and YouTube introduced <a href="http://analytics.blogspot.com/2008/03/youtube-now-offers-more-analytics.html">YouTube Insight</a>, a tool to provide more information about the people viewing your videos on <a href="http://youtube.com">www.youtube.com</a>.  It&#8217;s pretty cool stuff and if you&#8217;re posting videos to YouTube it provides a lot of great information.</p>
<p><img id="image525" src="http://www.cutroni.com/blog/wp-content/uploads/2008/07/picture-2_530x439shkl.png" alt="YouTube Insight: Information about those viewing your videos on www.youtube.com." /></p>
<p>But what about YouTube videos that are embedded in a site?  What&#8217;s the best way to measure interactions with these videos?  You could use some basic metrics like Avg. Time on Page and Avg. Time on Site, but they&#8217;re averages and, well, averages suck.  Fear not, there is a better way.</p>
<p>We can track almost every aspect of an embedded YouTube video using Event Tracking, a Google Analytics beta feature.</p>
<p><img id="image526" hspace="7" vspace="7" src="http://www.cutroni.com/blog/wp-content/uploads/2008/07/chrome-motorcycle1_300x225shkl.jpg" alt="CHROME" align="right"/></p>
<p>There is one catch.  In order to track an embedded YouTube video you must use the &#8216;chromeless&#8217; YouTube player.  A chromeless video player has no controls which means you must create all of the controls yourself.  This results in a fair amount of coding.</p>
<p>Why do we have to use the chromeless player?  The chromeless player let&#8217;s us add JavaScript code (i.e. GA Event tracking code) to user actions, thus giving us the ability to capture visitor actions as events.  I&#8217;ll do my best to walk you through all of the code.</p>
<p>You can read more about the <a href="http://code.google.com/apis/youtube/chromeless_player_reference.html">chromeless YouTube player</a> on the <a href="http://code.google.com/apis/youtube/developers_guide_protocol.html">YouTube developer site</a>.</p>
<p>Let&#8217;s get started.</p>
<h2>Event Data Model</h2>
<p>Before we look at any code let&#8217;s talk about data and analysis.  One of the keys to any successful event tracking implementation is a clear definition of the data we want to collect.  Remember, event tracking is really a flexible data collection tool.  We need to explicitly define the data we want to collect.</p>
<p>I want to track three primary things related to the embedded video:</p>
<p>1.  Which video does the visitor choose to watch?<br />
2.  How do they interact with the video player (i.e how do they use the controls)?<br />
3.  How much time do they spend watching each video?</p>
<p>Now let&#8217;s translate these needs into the Google Analytics Event model which consists of Objects, Actions, Labels and Values.</p>
<h3>Objects</h3>
<p>The object is the part of the page that we want to track. Defining the object in this case is pretty simple: we want to track the YouTube video player, so we&#8217;ll create one object and call it &#8220;YouTube Video Player&#8221;.  The object will literally be created in the code and I&#8217;ll explain how later.</p>
<h3>Actions</h3>
<p>Actions are the interactions that the visitor exerts on the object. What we want to track, and what we can track, really depend on what interactions we can capture.  In this example, the actions we can capture are directly related to the chromeless YouTube player and what it &#8216;bubbles up&#8217; for visitor interactions.</p>
<p>Based on the chromeless player, and the data needs we have defined, here are the actions that we are going to track:</p>
<ul>
<li><strong>Player Loaded</strong>: Indicates the YouTube player has loaded.  No video has been loaded into the player, but the player is ready for a video.</li>
<li><strong>Video Started</strong>: Indicates the user has chosen a video and it has started playing in the player.</li>
<li><strong>Play</strong>: User has restart the video after it has been paused.</li>
<li><strong>Pause</strong>: Video has been paused.</li>
<li><strong>Mute</strong>: Video has been muted.</li>
<li><strong>Unmute</strong>: Video has been unmuted.</li>
<li><strong>Error</strong>: An error has occurred.</li>
<li><strong>Ended</strong>: Selected video has ended, either intentionally or on purpose by the visitor.</li>
<li><strong>Get Embed Code</strong>: Request HTML code to embed the video in a site.</li>
<li><strong>Get Video URL</strong>: Request YouTube URL for the current video.</li>
</ul>
<p>Like the object, actions are actually created in the code and we&#8217;ll see how later.</p>
<p>There are other things that we can track, but I&#8217;ve decided to limit it to the above list.  Why?  I don&#8217;t think there is a lot of insight that can be gained from some of the other information that is available to us.  Plus the above actions will cover the data needs we&#8217;ve defined.</p>
<p><img id="image531" src="http://www.cutroni.com/blog/wp-content/uploads/2008/07/sew-label_300x300shkl.jpg" alt="Google Analytics Event Labels." align="right" hspace="7" vspace="7" /></p>
<h3>Labels</h3>
<p>Labels are the content of the object.  In the case of most video player object, the label will be the name of the video playing.  In this example you can choose three potential videos from a drop down box.  The name of the video will become the label that is tracked in Google Analytics.</p>
<ul>
<li>Apollo 11 Launch</li>
<li>About the YouTube API</li>
<li>Phish &#8211; Weekapaug Groove</li>
<li>Authors@Google: Avinash Kaushik</li>
</ul>
<h3>Values</h3>
<p>This is where things can get a bit unique.  The value collected by GA&#8217;s Event tracking is just a plain integer.  All values associated with actions are summed and averaged.  So we <em>can&#8217;t</em> mix different types of data, like monetary values (which may be in dollars) and time (which may be in seconds).  For this example, we&#8217;re going to track time, so the values will be in seconds and will represent the total time that each video played.</p>
<p>I&#8217;m only going to associate a value with a single actions: Ended.  When a video ends we&#8217;re going to record the total number of seconds played for that video.</p>
<h2>The Example</h2>
<p>Now that we&#8217;ve created the data model for tracking a YouTube player, we need to create a YouTube player to track. :) Remember we can only access visitor actions when we use the chromeless YouTube player.</p>
<p>Here&#8217;s a simple page that I created using the chromeless player and Google Analytics Event Tracking.</p>
<p><iframe src="http://sandbox.epikone.us/ytanalytics/index2.html" height="500" width="535"></iframe></p>
<p>If the above iFrame is not visible, you can view the entire code <a href="http://sandbox.epikone.us/ytanalytics/index2.html">here</a>.</p>
<p>For those interested, this test page is actually a modification of the <a href="http://code.google.com/apis/youtube/js_example_1.html">YouTube API example</a>.</p>
<p>To start the tracking, select a video from the drop down and it will start playing.  Then experiment with some of the controls.  All actions that we defined in our event model will be tracked.</p>
<p>If you want to change videos just choose a new video from the drop down box.</p>
<p>I don&#8217;t want to go over too much of the code, but here&#8217;s the JavaScript behind the tracking.</p>
<p><iframe src="http://sandbox.epikone.us/ytanalytics/index2.txt" height="500" width="535"></iframe></p>
<p>If the above iFrame is not visible, you can view the entire code <a href="http://sandbox.epikone.us/ytanalytics/index2.txt">here</a>.</p>
<p>A majority of the code is not Google Analytics code, but rather YouTube player code.  What I&#8217;ve done is added the Event Tracking code in the appropriate places to capture the visitor interactions.  Setting up the event tracking code is really pretty simple.</p>
<p>The first thing I did was create the Object, which is called &#8216;YouTube Video Player&#8217;.  I created the object in the main GA page tag.</p>
<pre>
<code>&lt;script type='text/javascript'&gt;
var pageTracker = _gat._getTracker("UA-XXXXXXX-X");
pageTracker._initData();
pageTracker._trackPageview();

// Create the event tracking object
var ytpEventTracker =
pageTracker._createEventTracker("YouTube Video Player");
var eventLabel;
&lt;/script&gt;</code>
</pre>
<p>After creating the object I added the _trackEvent() method wherever I want to capture a visitor action, like Play or Pause. Here&#8217;s how I capture the Play action:</p>
<pre>
<code>function play() {
  if (ytplayer) {
    ytplayer.playVideo();
    ytpEventTracker._trackEvent("Play",eventLabel);
  }
}</code>
</pre>
<p>Most of the Play code is actually YouTube code.  The only GA specific code is <code>ytpEventTracker._trackEvent("Play",eventLabel);</code>.</p>
<p>We pass three values to <code>_trackEvent()</code>.  The first is the name of the action and this value will appear in the GA Actions report.  The second value is the lable value which will appear in the Labels report.  I should note that <code>eventLabel</code> is the name of the video (per the data model) that is currently playing when the visitor clicks on Play.</p>
<p>The final value, which is not shown above, is the value value.  In this example, the value is the total number of seconds played.  This is only recorded for the Ended action.</p>
<p>If you look at the example code, all I really did was add <code>ytpEventTracker._trackEvent()</code> to all the actions that I wanted to track.</p>
<h2>The Results</h2>
<p>Enough with all the techno-mumbo-jumbo.  Let&#8217;s look at some of the data starting at the top of our hierarchy: the Object report.</p>
<p><img id="image532" src="http://www.cutroni.com/blog/wp-content/uploads/2008/07/picture-6_560x210shkl.png" alt="Google Analytics Object report." /></p>
<p>Noting too exciting here.  We&#8217;re only tracking a single object here, hence the one line of data.  The data can be a little confusing.  The total number of events is really the total number of actions that occurred.  The number of unique events is the number of visits that included an event.</p>
<p>But let&#8217;s dig a bit deeper.  Let&#8217;s see which video was most popular by viewing the labels associated with the YouTube Video Player object.  All I need to do is click on the Object name to view the associate labels and actions, and then choose &#8216;Labels&#8217; using the Detail Level link above the table tabs.</p>
<p><img id="image533" src="http://www.cutroni.com/blog/wp-content/uploads/2008/07/picture-7_560x330shkl.png" alt="Google Analytics Label report." /></p>
<p>Here we can see that &#8216;Phish-Weekapaug Groove&#8217; was the most popular video, when based on time.  It had a higher total value than the other videos.  Sorry Avinash. :)</p>
<p>One thing to notice is that measuring the popularity of each video based on Events is not correct.  Just because a label has the most actions does not mean that it is the most popular.</p>
<p>Remember, an action can occur ever time a visitor interacts with the player.  In this example it would be more accurate to judge popularity based on time.</p>
<p>Now let&#8217;s see how people interacted with the most popular video.  What actions did visitors perform when &#8216;Phish-Weekapaug Groove&#8217; was playing?</p>
<p>All I need to do is click on the label name to see the actions associated with the label.</p>
<p><img id="image534" src="http://www.cutroni.com/blog/wp-content/uploads/2008/07/picture-8_560x399shkl.png" alt="Google Analytis Action report." /></p>
<p>Cool, here we can see that the video was started 32 times, but only completed  12 times.  It was viewed a total of 1775 seconds but only an average of 143 seconds.</p>
<p>What does it all mean?  I know that the Phish video is 179 seconds long.  So, on average, visitors viewed 80% of it.  I can also tell, by the number of unique events, that the Phish video was viewed multiple times in the same visit.  It must be pretty popular.</p>
<p>I also want to point out that we can view the data in other ways.  We can navigate directly to the Actions report to see a list of all the actions, regardless of the object or label they are associated with.  This is a great way to get a feel for the most commonly used features of our YouTube player.</p>
<p><img id="image536" src="http://www.cutroni.com/blog/wp-content/uploads/2008/07/picture-9_560x406shkl.png" alt="Google Analytics Actions report." /></p>
<h2>Conclusion</h2>
<p>So was this really worth it?  Sure, I think so.  I wanted to create a real life example that demonstrates some of the ways to use Event Tracking.  I also wanted to use YouTube as an example because so may people use it as a platform to distribute video.</p>
<p>While it may seem like a lot of work to track video and other web 2.0 technologies it is vital.  If you&#8217;re spending money producing videos, or if you&#8217;re selling video ad space, you need to know how people interact with your player and content.  It&#8217;s the perfect use for Event Tracking.</p>
<p><a href="http://cutroni.com/blog/2008/07/29/tracking-youttube-videos-with-google-analytics/">Tracking YouTube Videos with Google Analytics</a> is a post from: <a href="http://cutroni.com/blog">Analytics Talk by Justin Cutroni</a></p>

<div class="sociable">

<ul>
	<li class="sociablefirst"><a rel="nofollow"  target="_blank" href="http://twitter.com/home?status=Tracking%20YouTube%20Videos%20with%20Google%20Analytics%20-%20http%3A%2F%2Fcutroni.com%2Fblog%2F2008%2F07%2F29%2Ftracking-youttube-videos-with-google-analytics%2F" title="Twitter"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/twitter.png" title="Twitter" alt="Twitter" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2008%2F07%2F29%2Ftracking-youttube-videos-with-google-analytics%2F&amp;title=Tracking%20YouTube%20Videos%20with%20Google%20Analytics" title="StumbleUpon"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/stumbleupon.png" title="StumbleUpon" alt="StumbleUpon" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fcutroni.com%2Fblog%2F2008%2F07%2F29%2Ftracking-youttube-videos-with-google-analytics%2F&amp;title=Tracking%20YouTube%20Videos%20with%20Google%20Analytics&amp;bodytext=A%20while%20back%2C%20Google%20Analytics%20and%20YouTube%20introduced%20YouTube%20Insight%2C%20a%20tool%20to%20provide%20more%20information%20about%20the%20people%20viewing%20your%20videos%20on%20www.youtube.com.%20%20It%27s%20pretty%20cool%20stuff%20and%20if%20you%27re%20posting%20videos%20to%20YouTube%20it%20provides%20a%20lot%20of%20gr" title="Digg"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/digg.png" title="Digg" alt="Digg" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://delicious.com/post?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2008%2F07%2F29%2Ftracking-youttube-videos-with-google-analytics%2F&amp;title=Tracking%20YouTube%20Videos%20with%20Google%20Analytics&amp;notes=A%20while%20back%2C%20Google%20Analytics%20and%20YouTube%20introduced%20YouTube%20Insight%2C%20a%20tool%20to%20provide%20more%20information%20about%20the%20people%20viewing%20your%20videos%20on%20www.youtube.com.%20%20It%27s%20pretty%20cool%20stuff%20and%20if%20you%27re%20posting%20videos%20to%20YouTube%20it%20provides%20a%20lot%20of%20gr" title="del.icio.us"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/delicious.png" title="del.icio.us" alt="del.icio.us" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.facebook.com/share.php?u=http%3A%2F%2Fcutroni.com%2Fblog%2F2008%2F07%2F29%2Ftracking-youttube-videos-with-google-analytics%2F&amp;t=Tracking%20YouTube%20Videos%20with%20Google%20Analytics" title="Facebook"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/facebook.png" title="Facebook" alt="Facebook" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.linkedin.com/shareArticle?mini=true&amp;url=http%3A%2F%2Fcutroni.com%2Fblog%2F2008%2F07%2F29%2Ftracking-youttube-videos-with-google-analytics%2F&amp;title=Tracking%20YouTube%20Videos%20with%20Google%20Analytics&amp;source=Analytics+Talk+&amp;summary=A%20while%20back%2C%20Google%20Analytics%20and%20YouTube%20introduced%20YouTube%20Insight%2C%20a%20tool%20to%20provide%20more%20information%20about%20the%20people%20viewing%20your%20videos%20on%20www.youtube.com.%20%20It%27s%20pretty%20cool%20stuff%20and%20if%20you%27re%20posting%20videos%20to%20YouTube%20it%20provides%20a%20lot%20of%20gr" title="LinkedIn"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/linkedin.png" title="LinkedIn" alt="LinkedIn" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.friendfeed.com/share?title=Tracking%20YouTube%20Videos%20with%20Google%20Analytics&amp;link=http%3A%2F%2Fcutroni.com%2Fblog%2F2008%2F07%2F29%2Ftracking-youttube-videos-with-google-analytics%2F" title="FriendFeed"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/friendfeed.png" title="FriendFeed" alt="FriendFeed" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://sphinn.com/index.php?c=post&amp;m=submit&amp;link=http%3A%2F%2Fcutroni.com%2Fblog%2F2008%2F07%2F29%2Ftracking-youttube-videos-with-google-analytics%2F" title="Sphinn"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/sphinn.png" title="Sphinn" alt="Sphinn" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://www.google.com/bookmarks/mark?op=edit&amp;bkmk=http%3A%2F%2Fcutroni.com%2Fblog%2F2008%2F07%2F29%2Ftracking-youttube-videos-with-google-analytics%2F&amp;title=Tracking%20YouTube%20Videos%20with%20Google%20Analytics&amp;annotation=A%20while%20back%2C%20Google%20Analytics%20and%20YouTube%20introduced%20YouTube%20Insight%2C%20a%20tool%20to%20provide%20more%20information%20about%20the%20people%20viewing%20your%20videos%20on%20www.youtube.com.%20%20It%27s%20pretty%20cool%20stuff%20and%20if%20you%27re%20posting%20videos%20to%20YouTube%20it%20provides%20a%20lot%20of%20gr" title="Google Bookmarks"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/googlebookmark.png" title="Google Bookmarks" alt="Google Bookmarks" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://reddit.com/submit?url=http%3A%2F%2Fcutroni.com%2Fblog%2F2008%2F07%2F29%2Ftracking-youttube-videos-with-google-analytics%2F&amp;title=Tracking%20YouTube%20Videos%20with%20Google%20Analytics" title="Reddit"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/reddit.png" title="Reddit" alt="Reddit" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="mailto:?subject=Tracking%20YouTube%20Videos%20with%20Google%20Analytics&amp;body=http%3A%2F%2Fcutroni.com%2Fblog%2F2008%2F07%2F29%2Ftracking-youttube-videos-with-google-analytics%2F" title="email"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/email_link.png" title="email" alt="email" /></a></li>
	<li><a rel="nofollow"  target="_blank" href="http://technorati.com/faves?add=http%3A%2F%2Fcutroni.com%2Fblog%2F2008%2F07%2F29%2Ftracking-youttube-videos-with-google-analytics%2F" title="Technorati"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/technorati.png" title="Technorati" alt="Technorati" /></a></li>
	<li class="sociablelast"><a rel="nofollow"  target="_blank" href="http://buzz.yahoo.com/submit/?submitUrl=http%3A%2F%2Fcutroni.com%2Fblog%2F2008%2F07%2F29%2Ftracking-youttube-videos-with-google-analytics%2F&amp;submitHeadline=Tracking%20YouTube%20Videos%20with%20Google%20Analytics&amp;submitSummary=A%20while%20back%2C%20Google%20Analytics%20and%20YouTube%20introduced%20YouTube%20Insight%2C%20a%20tool%20to%20provide%20more%20information%20about%20the%20people%20viewing%20your%20videos%20on%20www.youtube.com.%20%20It%27s%20pretty%20cool%20stuff%20and%20if%20you%27re%20posting%20videos%20to%20YouTube%20it%20provides%20a%20lot%20of%20gr&amp;submitCategory=science&amp;submitAssetType=text" title="Yahoo! Buzz"><img src="http://cutroni.com/blog/wp-content/plugins/sociable/images/yahoobuzz.png" title="Yahoo! Buzz" alt="Yahoo! Buzz" /></a></li>
</ul>
</div>
]]></content:encoded>
			<wfw:commentRss>http://cutroni.com/blog/2008/07/29/tracking-youttube-videos-with-google-analytics/feed/</wfw:commentRss>
		<slash:comments>28</slash:comments>
		</item>
	</channel>
</rss>
