How to track Goals in Google Analytics

How to track Goals in Google Analytics

Google Analytics is perhaps the greatest tool that web marketers have for free. More than half of all websites use it, Phew!

With such phenomenal usage, you’d like to think that people are really making the most of it, but in actual fact, many webmasters don’t look beyond the basic graphs delivered by GA. This is a real shame because there are some fantastic features which can really help you to drill down into your statistics and make the most of the information gathered by the program.

Don’t worry though – just because they’re slightly more advanced features doesn’t mean that they’re difficult to implement and use. Here are some tips.

Don’t just focus on traffic

Web traffic is all well and good, but if people are just browsing, then a high figure is simply a vanity project. It doesn’t matter if lots of people are visiting your site if they’re not following call to actions and actually carrying out the task that you want them to. What you really want to be looking at are conversions.

There are lots of things you can do to improve your conversion rate but you need to be tracking conversions to see if it is making any difference.

In Google Analytics, conversions are known as goals. These are the actions that users take that you want to track. Goals might seem slightly limited because you can only track a few options. For example, you might think you can only track email newsletter signups if the visitor comes to an exclusive page when they have signed up. That’s not true – with a developer’s help you can attach JS to all sorts of occurrences to generate events. Button clicks, video plays, time on page – if you can trigger an event when it happens you can pretty much track it. Will get to that later.

To set up a basic goal, you need to go to Conversions > Goals > Overview. This is at the bottom of the left hand menu.

Select a template that you would like to use.

Click Next. Now you have the chance to name your goal. Choose something descriptive so that when you come back to look at it you know what you are staring at!

Add the URL of the page you’d like tracking and then you’re done! This will add a graph to your GA account and a column for your goal.

Track Events

No, not the 100m – tracking events means tracking clicks on your website. For example, you can track how many times a visitor clicks on a page element. You can use it to track:

  • Downloads
  • Link clicks
  • AJAX page elements interactions
  • Video (or element) plays

The event tracking code looks like this:

_trackEvent(category, action, opt_label, opt_value, opt_noninteraction)

In English this means:

  • category – the type of event. This label is mandatory, however, you can call it anything you’d like such as ‘video’ or ‘affiliate links.’
  • action – this is mandatory. Here you specify a type of action such as ‘click’ or ‘download.’
  • opt_label –  label you use to describe the event—optional.
  • opt_value – another optional field but useful if you want to add numerical values to your tracking –   Don’t include currency symbols: simply use ‘5’ for £5.
  • opt_noninteraction – when this event completes you can set it up to affect the page’s bounce rate by entering ‘True’ or ‘False’ if you do want it to affect it.

Let’s say you have a PDF of your favourite cat pictures for people to download. The event tracking code would say:

_trackEvent(‘awww causer’, ‘download’, ‘cat pictures’, 3, True)

This code alone is no good. You need to add it to an ‘onClick’ property in the link’s URL, with some slight syntax tweaks to make it work.

<a href=”/downloads/marketing-tricks.pdf” onClick=”_gaq.push([‘_trackEvent(‘awww causer’, ‘download’, ‘cat pictures’, 3, True]]);”>Download the Lovely Cats.PDF</a>

You can make this easier by using a tracking code generator like this one here.

Now you can keep track of all the events you are trying to monitor to see how successful you are in getting users to carry out the tasks.

Author Owen Radford

More posts by Owen Radford