Event Tracking in Google Analytics

Event Tracking in Google Analytics is a powerful tool available to you if you use Google Analytics to track user interaction with your website elements.

Event tracking could be used to track those user interactions on your web property that do not result in additional page view i.e. a visitor watching video on your webpage or a visitors browsing photo-gallery of your photograph.

I like event tracking but this could effectively help in measuring economic value as well as macro conversion i.e. someone actually purchase a product as well as micro conversion i.e. they subscribe to your newsletter, follow you on your social network or download brochure with an intent to purchase at a later date.

Another useful application of event tracking that I find is to monitor my internal links; especially the header links and footer links and do I need to promote a footer link to my header link. Event tracking is also handy to see if the internal link that I recommended with a particular post was helpful or persuasive enough to induce the intended click by the visitors.

As opposed to Urchin Tracking Module (UTM) which creates an additional URL (which unfortunately gets indexed by Google too until and unless specified not to do so through robots.txt) thereby raising some canonical issues, using event tracking in Google Analytics doesn’t create any additional HTTP protocol. For internal site based interactions banners/offers etc., event tracking is the best way to track and analyze your site performance.

Once you have set up the event tracking, you could find the reports of the same under the Content Label in Google Analytics.

So how do you set up event tracking for Google Analytics?

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

There are 5 parts to the event tracking module through which you could gauge the user interactions with elements on your page.

You may use event tracking for all the videos on your site

_gaq.push([‘_trackEvent’, ‘Videos’, ‘Play’, ‘Gone With the Wind’]);

Or for tracking clicks on Header Links of your site _gaq.push([‘_trackEvent’, ‘Header Links’, ‘Clicked’, Video Page’]);

Or for gauging efficiency of internal linking or whether they generate interest for click or not

_gaq.push([‘_trackEvent’, ‘Internal Text Link’, ‘Clicked’, ‘Anchor Text +Page Title’]);

Category: This helps you categorize the events and separate them in the reports. Categories are parts of pages with which a visitor interacts. It could be a video or a brochure or any element that you want to track on a page. Remember that it’s very important that you follow a standard event tracking implementation structure.

In the above examples, I have used three categories which I could use to track site wide event occurrences under same heading in Google Analytics. Understand that Category represent the root level of hierarchy in analytics.

You would want to define and use a consistent structure to suit your reporting needs for Event Tracking in Google Analytics.

Action: What happened that you want to track? Was it a video play, a map view or brochure download, you can define action to know what exactly happened.

Label: Provides more information about the Action.

Suppose there are 3 brochures on your page, then a label could help you differentiate between them to know which one of them was viewed or downloaded.

Value: Is the numerical value for the event. It could be a monetary value or just some value to gauge the worth of one user interaction over other e.g. email subscription could be more valuable than watching a product video.

The other significant use of value is in case of brochure, video, and content performance especially if you have blog. Your value could be the download time or the time when a page completely loads or when someone starts to scroll content on the page or when the visitor reaches the bottom of your page.

Non-Interaction: This tells Event Tracking in Google Analytics to determine whether you want this event to impact bounce rate and time calculations or not.

For example this event tracking code:

 _gaq.push([‘_trackEvent’,’Reading’,’ArticleLoad’,’Page’,100,true]);

Above code will fire when an article loads in the browser. True is used to tell Google that you don’t want this event occurrence to affect your bounce rate.

Another could be to track whether the visitors has actually started to read and finished the bottom of your page.

_gaq.push([‘_trackEvent’,’Reading’,’StartReading’,’Page’,50]);

It means that this event will fire when an article loads in the browser. True is because you don’t want this event to affect your bounce rate. One of the most important things to consider while setting up event tracking is that if it will automatically executes on page load then the bounce rate for the page will be zero. Do use Non-interaction to avoid such occurrences as you know that by default opt_noninteraction is set to false.

If you are wondering how to use it on your site then follow this example:
<a href=”http://www.example.com/brochure.html” onClick=”_gaq.push([‘_trackEvent’, ‘header menu link’, ‘click’, ‘Brochure’]);”>Brochure</a>

What I did in this code is I told an event Header Link to fire in case visitors click on the link to Brochure page in the header menu. The event will fire on click and the data pushed will be Category=header menu link, Action=click and label=brochure. Since it will result in a page visit, I have not used non-interaction parameter=true.

Let me know if you have any doubts, questions or comments on event tracking  in Google Analytics.

(Visited 123 times, 1 visits today)

Leave a Reply

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