Track your blog in Blogger with Google Analytics

Tracking visits and activity on your blog is very important. The better the tool the better you can make your blog and when it comes to Tracking web-user statistics "Google Analytics" is the best tool out there, which is why I would recommend every blogger to start using it instead of(or in conjunction with) the Blogger Stats feature.

This tutorial aims to help you through setting up "Google Analytics" for your Blogger blog.

Open a Google Analytics Account and Use it with Blogger
Assuming you already have a Google account for GMail or Google+ visit:http://www.google.com/analytics. You will come across this screen:
Sign Up for Google Analytics

Whether you choose "Access Analytics" or "Sign Up Now", you will end up at the same place, which is shows in the screen shot below:



In the above page will click the "Sign Up" button. You will come across the page below. In this page you need to enter the following information:


A name/label for your Google Analytics account. This can be anything you want. I have chosen to call mine "Jenson Taylor Analytics"
The website address(URL) of your blog. Mine is " technologyfly.blogspot.co.uk"
You can choose how you want to share your data. This doesn't make a difference at this point. I have chosen the options which will integrate my Google Analytics account better with other Google services such as Ad Words. I would recommend that you choose the same options as I have in the screen below. (If you would like more explanation on these options please leave a comment and I will get back to you)
Choose the country you live in
After reading the terms and conditions, assuming that you agree with all of them. Tick the check box which says "Yes, I agree to the above terms and conditions."
Google Analytics First Create New Account Page


Click on "Create Account".

You will then see the page below which contains a unique identified called the "Tracking ID" and looks like UA-22222222-1. Make a note of this identifier (you will need to enter this identifier in your Blogger settings).

Generating Tracking code in Google Analytics
In the screen shot above you will see that I have highlighted the options for the section under "What are you tracking?". You can choose either one of those options that I have highlighted using the red arrows. The first option is what I would have recommended previously. However Blogger has started to roll out some changes recently that would affect this. Your blog address is going to change based on the country you are in, so previously the address of my blog was technologyfly.blogspot.com however it has now changed to  technologyfly.blogspot.co.uk; It is because of this change that I would now recommend you to choose the last option on the screen above.

Now click "Save" and you're done with Google Analytics.

Note: Ignore the number 2 option in the screenshot above. (You do NOT need to copy/paste code anywhere)

Go to you blogger dashboard then browse to "Settings" > "Other" and enter the "Tracking ID" for your blog in the field which is labelled "Analytics Web Property ID" (You can see the Tracking ID in your Google Analytics - see screen shot above for details)
Blogger Web Property Tracking ID for Google Analytics
Click "Save" and you're done.

Older Templates (To be ignored for most bloggers)
Most bloggers do not need to worry about this issue but if you are using a really old template then adding your blog's Analytics Tracking ID here might not work correctly. So you will need to go back to Google Analytics and copy the code given to you in Google Analytics into your template. For this go to your blogger's dashboard then browse to "Template" > "Edit HTML" > "Proceed"
You should now see all the code, search for "</head>" without the quotes. Once you find it, insert the code just before it. So before changes your code will be:
</head>

After adding your Google Analytics code, it will look like this:

<script type='text/javascript'>
var _gaq = _gaq || [];
_gaq.push([&#39;_setAccount&#39;, &#39;UA-222222-1&#39;]);
_gaq.push([&#39;_setDomainName&#39;, &#39;blogspot.co.uk&#39;]);
_gaq.push([&#39;_setAllowLinker&#39;, true]);
_gaq.push([&#39;_trackPageview&#39;]);
(function() {
var ga = document.createElement(&#39;script&#39;); ga.type = &#39;text/javascript&#39;; ga.async = true;
ga.src = (&#39;https:&#39; == document.location.protocol ? &#39;https://ssl&#39; : &#39;http://www&#39;) + &#39;.google-analytics.com/ga.js&#39;;
var s = document.getElementsByTagName(&#39;script&#39;)[0]; s.parentNode.insertBefore(ga, s);
})();
</script>
</head>
Click "Save Template" and you're done.
Previous
Next Post »
loading...