Skip to main content

How to Set Up Event Tracking in Google Analytics

Google Analytics’ Event Tracking is a great tool for monitoring activities on your site that aren’t related to a specific URL destination.
Whereas Google Analytics typically tracks activities on your site related to page loads, Event Tracking tracks actions where no URL destination is recorded, such as clicks on social media links or PDF downloads.

How to Install Event Tracking

Before you can add Event Tracking to your site, you need to make sure that you’re using the new Asynchronous Google Analytics tracking code.
The biggest difference is that the new code is placed at the top of your page, just before the closing </head> tag in your HTML file, whereas the traditional code is placed at the bottom of your page, just before the closing </body> tag.
If you’re not using the new code, here’s how to install it.
If you have a large site with a lot of events to track, you’ll need to install the Event Tracking code in the <head> section of your site. To do this, read Google’s Guide to installing Event Tracking.
For a smaller site, however, you can insert the HTML directly onto your page within the link. The formula is:
<a href=“http://www.url.com” onClick=“_gaq.push([‘_trackEvent’, ‘Category’, ‘Action’]);” target=“_blank”>Name of Your Link</a>

1. How to Track Social Media Links
Here is how you can track links to your social media profiles or other websites that you link to.
This link:
<a href=“https://www.facebook.com/facebookpagename” target=“_blank”>Follow us on Facebook</a>
Becomes:
<a href=“https://www.facebook.com/facebookpagename” onClick=“_gaq.push([‘_trackEvent’, ‘Follow’, ‘Facebook’]);” target=“_blank”>Follow us on Facebook</a>
When people click on this link, it will show up in Analytics under Content > Events. “Follow” will be your Event Category and “Facebook” will be your Event Action.

2. How to Track PDF Downloads
If you have white papers or registration forms on your site, here’s how to track the number of times they are downloaded.
This link:
<a href=“http://url.com/registration-form.pdf” target=“_blank”>Download the registration form.</a>
Becomes:
<a href=“http://url.com/registration-form.pdf” onClick=“_gaq.push([‘_trackEvent’, ‘Download’, ‘Registration Form’]);” target=“_blank”>Download the registration form.</a>
When people click on this link, it will show up in Analytics under Content > Events. “Download” will be your Event Category. “Registration Form” will be your Event Action.

2. How to Track Member Sign Up via a Popup Window
If you use popup windows on your site, here’s how to track activity within them, such as member sign up, member sign in or contest entry submission.
Within the form action code, you will have something like this:
<input type=“submit” name=“LoginButton” class=“submit” id=“sign_in” value=“Sign Up” />
And you’ll change it to this:
<input onClick=“_gaq.push([‘_trackEvent’, ‘Join’, ‘Sign Up’, ‘linkURL=homepage’]);” type=“submit” name=“LoginButton” class=“submit” id=“sign_in” value=“Sign Up” />
This means that the button for “Sign Up” has extra code behind the scenes that says on clicking the button, tell analytics that an event occurred in the category called “Join”, and that event action was a “Sign Up” submission. Label that entry as coming from the “homepage”.

So if you have sign up across multiple pages, you could track what exact page the visitor was on when they signed up. But, if the sign up pop-up is only accessible from a single page, you can remove ‘linkURL=homepage’ from the code.
When people click on the sign up button, it will show up in Analytics under Content > Events. “Join” will be your Event Category. “Sign Up” will be your Event Action.

Once you have Event Tracking set up, if any of the actions you’re tracking are related to business goals, you should have them listed as conversions in the Goal section of Google Analytics.

And don’t forget, you can set up Events as Goals in Google Analytics.

Popular posts from this blog

The Affect of Debt Management Plan (DMP) on Credit Score

If you have settled you debts through debt management plan agreement and miss any payments you have to make to your creditors, then your credit rating will be affected very badly. And if you will pay less to your creditors each month than you originally agreed then they will view your account as in default and issue you with a default notice. Your creditors will put down that you have missed the payment on your credit file and will issue a notice to you. That’s why your credit score is badly affected. How Long a Debt Management Plan Affect Your Credit Rating: If you start your debt management plan for the first time then it is likely that your creditors will issue a default notice against you. It will be registered in your credit file and will remain there for 6 years. Meanwhile all late payment records and default notice will be seen if anyone carries out a credit check against you and they will hesitate to lend you more money. After six years if you are unable...

About Garcinia Cambogia Extract

It is a rather all-natural technique to shed body weight. We hereby review and attract out the aspects of the couple Herbs and suggest a couple like the HS Trim Fat Reduction & Slimming Dietary supplement to guide you aid in your closing alternative. Thousands of folks are shedding weight the pure way by harnessing the ability of pure herbs and health supplements. elevated risk of diabetic issues and Blood clotting are more disadvantages of smoking cigarettes. Mangosteen fruit can be applied in the sort of ointment to mend eczema, skin rashes and other pores and skin ailments. It begins with the sub-cutaneous and body fat in the mid-area and commonly would seem to exercise from there. The most sought after result of applying diet plan patch is excess weight reduction by signifies of lowering hunger and rising metabolic process. Other than fat decline, this therapeutic massage also will help in bettering the skin and its complexion. Rewards: It is handy in lowering ...