How To Set Up Google Analytics

December 22, 2010 - 2 minutes read

One reason for me setting up my blog is to share all of the lessons that I am learning whilst starting out my career in SEO. This is so that for all others out there that think they may be interested in getting into SEO, or simply wish to have a play with some of the tools that SEO’s use, they will look to my website as a useful reference point.

An early lesson to learn if you have your own blog, is to set up Google Analytics tracking for it. To do this it is really quite simple, Google Analytics records a vast amount of information by placing a small hidden piece of JavaScript on your site. You can check this on some of your favourite sites by viewing the ‘page source’ of a page. There are a number of ways of doing this, all dependent on what browser you are using:

  • For Firefox users, either go view/page source (see below) or simply press Ctrl + U (Windows) and Cmd + U (Mac)

Image showing how to locate 'View Page Source' in Firefox

  • For Chrome users, click view/developer/page source (see below) or simply press Ctrl + U (Windows) and Cmd + Option Modifier icon + U (Mac)

Image showing how to locate 'View Page Source' in Google Chrome

  • For Internet Explorer users, click view/source

This will show you a scary amount of code (like that shown below for which, if you have no experience with code don’t fret about. The key to getting to know and understand HTML code is to use the ‘find’ function. With the source page open click Ctrl + F (Windows) and Cmd + F (Mac) and in the find box search for ‘UA-‘ this will show you the unique code that Google uses to track that URL. You can see below that the code that Google is using to track my site is ‘UA-19608868-1’:

Image showing the Page Source for

If you have a WordPress blog then I would recommend using the Google Analytics for WordPress plugin from WordPress wizz Yoast which will handily help you manage this very easily.