Google Analytics Tutorial
December 17th, 2006 Posted in Website AnalyticsIn one of my last posts I briefly mentioned Google Analytics. Trying to do online marketing without a good analytics package is like trying to drive a car will blindfolded - it’s absolutely impossible and is quite likely to end in an expensive disaster. Fortunately Google Analytics is pretty simple to setup in three steps.
1. Add the Google Analytics tracking code to each page
You can get the tracking code by clicking on the ‘check status’ link on the main Google Analytics page.
There is some argument about where this tracking code should go. JavaScript usually goes into the of an HTML page but some people say that the tracking code should go onto the very end of the page so that if a page is partially loaded then it won’t be counted. It isn’t very important where it goes.
2. Define goals
Goals are the most important part of Google Analytics. For a selling website it;s very important to move away from thinking about traffic to thinking about goals. Typically a goal will be one or more of:
- Buying a product
- Requesting a free trial
- Signing up for a newsletter
- Downloading a white paper
- Sending an email
You can define goals by clicking on ‘edit’ in the Settings column on the main screen. For most goals it’s very easy to define, all you need to do is enter the URL. However if the goal is sending an email from a mailto link it’s a bit more complicated.
You’ll need add the following into your mailto link:
onclick=”javascript:urchinTracker(’/email’)”
This will make clicking on the mailto the equivalent to visiting www.braintalent.co.uk/email which you can then set as the goal. Incidentally, Google Analytics used to be called Urchin before it was bought by Google and this is one of the places where the old name lives on.
3. Add filters
If you obsessively visit your own website as much as I do then you’ll need to add some filters to make sure that your own visits don’t inflate your statistics. There is a Filter Manager on the main Google Analytics screen which lets you do just that. You’ll need to know your hostname or IP address first - and it will only work if you are on a static IP address. Some ISP’s will regularly change your IP address which will make it hard to get the filters working without blocking out your whole ISP which you probably don’t want to do.
Gotchas
The problem I tend to run across most often is that people change the domain name at some point in their website. Google Analytics relies on cookies and cookies cannot cross to a new domain name although they are fine with different host names. For example linking from www.braintalent.co.uk to planet.braintalent.co.uk would be fine (because it’s just the host name changing) but linking from www.braintalent.co.uk to www.braintalent.com wouldn’t be (because the domain name changed).
It is possible to manually pass the cookie over by using the utmLinker but that is quite awkward and makes messy URL’s.
