How to install Google Analytics on a Blogger blog

google analytics to blogger Google Analytics (GA) is a free service that generates detailed statistics about the traffic and visitors to a website or blog. In addition to the usual traffic metrics (pageviews, visits, unique visitors, bounce rate,  time on site etc.), GA also provides comprehensive statistics on website/blog audience, traffic sources, content, keywords and more.

Adding Google Analytics to a Blogger blog is easy, and it doesn’t even involve copy-pasting Javascripts.


I) Creating an account with Google Analytics

  1. Go to Google Analytics, click the Sign-Up Now link on top right corner of the page and sign in to your Google Account.
  2. On the next page click the Sign up button. 
  3. Next supply all the necessary details -account name, blog URL you wish to track, time zone, data sharing preferences, and your country or territory. create google analytics account
  4. Read the terms of service and  tick the “Yes, I agree to the above terms and conditions” checkbox.
  5. Click Create Account button and you’ll be taken to Tracking Code Configuration tab.
  6. The next step is to find the Web Property ID (a.k.a UA number) -a unique ID given to the account you just created. Disregard all other items in this tab, the only thing you need is the UA number.GA web property id UA number
  7. Copy the UA number as you’ll need to paste it later on.

II) Installing Google Analytics on your blog

This is a two-step process. First you need to register the Web Property ID with Blogger, and then import the tracking code into your template.

  • Adding Google Analytics ID to your blog
    1. If you are using the new Blogger interface, click the dropdown menu next to the name of the blog you wish to track and navigate to Settings > Other > Google Analytics. (For old interface, go to Settings > Basic > Google Analytics Web Property ID). GA web property ID in blogger
    2. Paste in the UA number into the Google Analytics Web Property ID text box. 
    3. Click Save Settings.
  • Adding your tracking code

    The following <include> tag will import your GA tracking code into your blog:

    <b:include name='google-analytics' data='blog'/>

    If you are using a latest Layout or Dynamic Views template from Template Designer gallery, you can skip the following steps because it already has the <include>  tag built-in. The same applies to mobile templates.

    But if you are using an older Layout template or a third party template you might need to add it into your template manually. Here’s how:

    1. Go to Template > Edit HTML  (for old interface it’s Design > Edit HTML) and locate the </body> tag.
    2. Insert the code right above the tag (if the code isn’t already there).
    3. Save your template.

It could take 24 hours before your first data to appear in your account. This is because Google Analytics updates reports every 24 hours. Come back to Google Analytics Dashboard the next day and if everything is in order you will see your stats!

Enjoy!

95 comments to "How to install Google Analytics on a Blogger blog"

Aditya Sam January 7, 2012 at 4:44 PM    

Thank you so much... Saved some page speed :)

shree@SOFTECHNOGEEK January 7, 2012 at 9:02 PM    

added this to my blog

zulkbo January 7, 2012 at 9:34 PM    

b egitu senang sekarang
berbanding sebelum ini
kita perlu masukkan dalam
bentuk script dalam css

Raj January 8, 2012 at 12:12 AM    

I wish it was as easy as this in WP too... When I first had a look at all the code, I sort of freaked out. But these days I am more comfortable with inserting small things into the code!

Gaurang January 8, 2012 at 5:04 PM    

Very useful info. Thanks a lot. :)

conference gifts January 10, 2012 at 12:21 PM    

google analytics is a great tool since it shows you accurate stats and report monthly. Or even daily were in it sends you statistics and current status of your site.

custom items January 12, 2012 at 2:42 PM    

Doesn't Blogger have it as a plugin? I always thought they did. Anyways, I'll check it out again. Could be my mistake though.

kingrpg January 15, 2012 at 9:24 PM    

my sub-domain of blogspot is work, but my domain is not work, how to fix?

Greenlava January 16, 2012 at 7:04 PM    

@kingrpg
As long as your (custom) domain uses Blogger, the process is same...and it will work.

Unknown January 23, 2012 at 8:06 PM    

just tried mine, would check it tomorrow to see if it works.Thanks

ohcikgu January 24, 2012 at 8:42 PM    

Its easy. I also already do that. Hehe..

Blogging Made Easy January 29, 2012 at 5:37 PM    

Thanks. I have added this Code in my blog. Nice tool, I can now able to find my traffic source, visits, users etc. in detail.

Anonymous,  January 29, 2012 at 8:33 PM    

I added this to my site as well. Hope it works. Steps were easy to follow, so should be ok. Thanks!!

Website Consultancy February 23, 2012 at 12:37 AM    

Easiest find on the web for adding Google Analytics to a Blogger Blog.

Many Thanks

Mumbai Tamil People March 6, 2012 at 5:19 PM    

Short and Sweet Explanation, All the new bloggers have to read this blog as it explains the Google analytics in a single page and no one could ask doubts once they come across this blog. Thanks to the writer, keep this work going and make your post more valuable

figuretech April 6, 2012 at 2:09 PM    

I am a fan of google analytics,although that am using wordpress right now...it helps to track events on your blog...it is essential for bloggers that want to succeed online.

Rackmount Monitor April 21, 2012 at 5:17 PM    

It is a nice blog; I can say that you have vast about getting your business on your site. Its excellent information in its field, Thanks for sharing this useful information.

live4footy.com May 6, 2012 at 3:52 AM    

my existing code has 8 numbers and blogger says there should be 6

Greenlava May 7, 2012 at 6:56 PM    

@live4footy.com
Mine is 8 digits too.

Home Remedies May 15, 2012 at 6:28 PM    

Actually everybody don't knows how to install google analytics in blogger. Your blog is very helpful for those type of people.
Thanks for sharing this useful information.

Real Estate News May 17, 2012 at 11:43 AM    

very useful information for me

Unknown May 22, 2012 at 7:18 PM    

U shud disable this no copy stuff on ur blog
it makes it hard to copy html codes

Greenlava May 24, 2012 at 5:40 PM    

@Derek Odum
All codes are selectable/copyable. Only normal text inside a post is select-disabled.

Unknown May 25, 2012 at 2:36 PM    

Thank you SO much! I've needed this help for a while now lol

Unknown May 27, 2012 at 4:32 PM    

i find this helpful for my blogging

Watch Movies Online June 7, 2012 at 2:11 AM    

In new interface I am facing problem to add Google analytics code to my blog

Tom,  June 22, 2012 at 6:52 PM    

Thank you! Great post. You've saved me a lot of time and frustration.

Max Valentine July 2, 2012 at 4:14 PM    

I'm such a newb, can't seem to add the code to the page even with instructions. What's happened is that I've added it to all the appropriate location(s) but it still says tracking code wasn't installed. HELP! PLEASE! SOMEONE! =.=;; lol

Greenlava July 7, 2012 at 1:26 PM    

@Max Valentine
I see 3 instances of the same Google Analytics code in your source code. You need to remove the 2 that you added manually. Just keep the one added using this tutorial.

Nitin Samant July 15, 2012 at 7:07 PM    

Thanks for helpful posts.

Unknown July 17, 2012 at 10:06 AM    

Seriously? That was so easy! I had been working on this for a few days before stumbling on your post. Thank you!!!

KR RAHMAN July 18, 2012 at 4:44 PM    

I applied mine and waiting for the outcomes. About the this article, it is undoubtedly a rich and easy to apply.

Sop July 19, 2012 at 10:15 PM    

Thank you
now i know how... :)

Mortgages July 25, 2012 at 4:37 PM    

nice one

Google Web Analytics July 25, 2012 at 9:04 PM    

Nice Blog!

Google Analytics is a great tool to measure your results and modify your SEO strategies accordingly.

synthesis essay July 27, 2012 at 6:05 PM    

thanks for sharing! Thanks. I have added this Code in my blog. Nice tool good to read this!

Soikot ahmed August 2, 2012 at 12:15 AM    

tnx u very much

Anya August 5, 2012 at 4:53 PM    

Thank you. It was very useful for me.

Anonymous,  August 30, 2012 at 2:11 AM    

Easiest guide to follow

Paolo August 31, 2012 at 12:10 AM    

Thank you! :)

Unknown September 8, 2012 at 5:59 AM    

When I did the first part where it said to sign up, there are two choices.. share and don't share. does it matter which of those you click? the beta real time is working.

also, when I got done, there was a code I had to copy and paste.. was I suppose to just ignore that? In the older versions you have to paste that into html under add gadget.. do you no longer do that?

Greenlava September 9, 2012 at 3:51 PM    

@Judy Susan
1. No it doesn't matter whether you select share and don't share.
2. Just ignore the code.

toni ts September 24, 2012 at 1:07 PM    

thank you very much greenlava..

it is very easy add google analytic on new blogger.
I almost doing a dirty work by putting script from g.analytic on html code.

just add the ID.. very simple

regards

Unknown September 25, 2012 at 3:03 AM    

thanks for this great post i am new to blogging world and i am countineous reader of your blog

Issac Landry September 26, 2012 at 10:38 PM    

I just applied these steps, hope this will work soon.

Greenlava September 29, 2012 at 11:17 PM    

@Ali Jutt
Have you added the second CNAME record in DNS setting?
How To Setup/Host Custom Domain On Blogger

Epoca Libera October 21, 2012 at 4:58 PM    

Hello,
thank you for your help, I have also liked your excellent facebook page.
I am using an older blogger layout template.
After I have pasted my UA number into the Google Analytics Web Property ID text box of blogger,
I have followed your tip and added the <include> tag:
<b:include name='google-analytics' data='blog'/>
above the </body> tag by editing the HTML.
It worked and started receiving views in Real-Time (BETA) dashboard of Google Analytics.
Although I am receiving views, if i go to Google Analytics account:
Admin>profile>Tracking Info , I get this message:
"Tracking Status: Tracking Not Installed
The Google Analytics tracking code has not been detected on your website's home page..."

Greenlava October 22, 2012 at 9:33 AM    

@Epoca Libera
Check again after a day or two.

Epoca Libera October 23, 2012 at 3:00 AM    

Hello Greenlava, and thanks for replying.
Indeed today the message was fixed, as you said:
At my Google Analytics account:
Admin>profile>Tracking Info , now I get this message:
Tracking Status: Receiving Data
and google analytics data are working smoothly.
Best!

Ethnicity in Pakistan October 27, 2012 at 3:54 PM    

I am having troubles with embeding the code into my template. It says on Google Analytics, that no tracking code was found on your website. I've added it before the < / body > tag closes but the problem persists

Greenlava October 30, 2012 at 4:54 PM    

@Ethnicity in Pakistan
I'm seeing the analytics code in your source code so it's just a matter time of before the status changes.

The Blond November 21, 2012 at 5:17 AM    

Wow! Is this how easy it is? Thanks for that! I've been trying to use the Google instructions, but they confuse me so much! what can i say? I'm only a blond girl :)

Michelle November 23, 2012 at 7:08 PM    

Thank you so very, very much...It was super easy. I saved the original template HTML just in case I stuffed it up... but it loos all good to go ... at least the blog preview showed normal... now to wait the 24 hours.
Everything else I had read up until now jsut confused me to blazes... and I am NOT blond... ;-)

Michelle November 23, 2012 at 7:12 PM    

But now you have me confused... what is the escape tool for??? Yech... more reading... Oh well you made the first bit easy... I will move on to that page now! Bye

Greenlava November 24, 2012 at 1:59 AM    

@Michelle
You need the escape tool if you want to post codes in the comments.
Most codes are not allowed in the comments or they simply don't show up when published.
Escape is not needed for normal text.

Destiny Renze November 30, 2012 at 12:23 PM    

i had it done with my Blog, i have to wait for 24 hours to re check.. thanks for this info, i hope i did it right :)

Unknown December 8, 2012 at 5:16 AM    

thanks. I am going to try it.

Mike Cleveland December 12, 2012 at 3:37 PM    

The other day, I copied the UA number into my Blogger blog. I could not see anything tracked except traffic coming from 'Blogger.com'.

When I looked at stats in Blogger, I saw traffic coming from different sources.

I Google this, and your blog post came up. I am using a third party template so I installed the include code. This is what I needed. Thank you.

Dickson December 13, 2012 at 7:49 AM    

Thanks for the information and tutorial, can we display the pagevisits info to our blogger?

Greenlava December 13, 2012 at 6:13 PM    

@Dickson
I'm not sure about Google Analytics, but Blogger has a widget just for that. It' s called Blog's stats gadget.

justsomethoughts December 26, 2012 at 2:48 AM    

Nice resource. I've been blogging on wordpress for two reasons--this was based on two years ago--wordpress seemed more professional and had cleaner layouts. Also privacy options seemed better.

I've now just as an experimented imported one of my blogs to blogger, and the reason is because inexplicably, wordpress doesn't allow Google Analytics. I have a question for you about Analytics and Blogger in general:

1. I got to the Google Analytics code (adding the ID) part. However, how do I know whether I need to do the part? I can't tell if I'm on a "dynamic view or latest layout".

2. Unrelated but hope you can help--how is Blogger on privacy? It seems to immediately link and publicize you to ALL other aspects of your google identity. Some of my blogs are more "professional" and academic in tone and subjec matter, and I'm hesitant of linking them to my google profile. My fear with blogger is that it automatically links all that stuff--for example.

3. Last question returning to the Analytics, is whether Analytics and described on this post can be done through one analytics account, but applied to many personal blogs or sites.

rdpatz December 27, 2012 at 4:45 PM    

thanks

Glamamama December 29, 2012 at 10:11 AM    

Thx. This was really helpful!

Web Development Company Faridabad December 29, 2012 at 8:28 PM    

Informative Blog !!

Thanks for Sharing

Rafayet Ullah December 31, 2012 at 10:54 PM    

This looks great. I was looking for this, couldn't find. Thanks a lot to the writer. I have added my site to analytics to my site.

Chinaza Daniel January 6, 2013 at 5:12 AM    

Google analytic tool is my best tool when it comes to web statistics.it help me track my traffic fast.

visionerial January 6, 2013 at 8:40 PM    

wow, great article bro, i will added Google Analytics in my blog

Rose McCauley January 12, 2013 at 3:22 AM    

Hope someone can help! I have followed the directions above and got as far as settings and basic, but see nowhere that says "Google Analytics" or gives me a box to input my number. What am I doing wrong? thanks!

Peter January 18, 2013 at 6:31 PM    

Greenlava Thanks for this splendid article, You've done a great service by simplifying the process Google tip is not as compelling as yours is. Thanks once again

Michelle Carvalho January 22, 2013 at 12:17 AM    

Just used this, now we'll see if it all works, thanks a ton!

Unknown February 7, 2013 at 9:18 AM    

Very Helpful, Thank You.

Alejandra Ramos February 14, 2013 at 1:40 PM    

This is fantastic! I have literally been trying to figure this out for years. Even my husband (a software engineer) couldn't figure it out. The instructions on the Google Analytics page just overcomplicated it. So happy to finally have it properly installed thanks to your simple instructions.

The Stylumnist February 22, 2013 at 8:43 PM    

Thanks so much! It really is so much more simple than explained on Google Analytics. I just followed the steps above and now we'll see how it goes :). Thanks again :).

Chef Mireille March 2, 2013 at 6:39 AM    

very helpful...thanks

Admin March 5, 2013 at 2:05 AM    

thanks a lot!

kodandapani March 5, 2013 at 12:54 PM    

Thank you Sooo much,needful information..

Unknown March 8, 2013 at 5:46 PM    

thenks a lot

Miss Kips March 11, 2013 at 11:02 PM    

Really useful!

vikram March 28, 2013 at 5:48 PM    

Thanks for this post,helped me a lot.

Google Website Traffic April 3, 2013 at 2:26 PM    

Your blog is totally interesting also extraordinary blog beautiful points.

Salesforce for Google Adwords April 10, 2013 at 10:18 PM    

Love analytics, should be installed on everyones site for accuracy.

Cricket April 11, 2013 at 11:33 PM    

Thanks a lot!ULTRA SUPER GIGA HELPFUL!

Anonymous,  April 14, 2013 at 11:04 PM    

thnx a lot...

Real Estate in Vietnam April 16, 2013 at 11:25 AM    

Google Analytics help me earn more money, it's a very helful tool

KR April 28, 2013 at 5:50 PM    

Along with the tracking code. they gave me a tracking code of 5-6 lines in javascript. Please tell me if I need to paste that as well??
My website is Kolkata Restaurants

Jobs in India April 30, 2013 at 3:07 AM    

Thanks for your support and your help. now i have learnt everything about google analytics.

Greenlava April 30, 2013 at 12:41 PM    

@KR
You only need the UA number.

rain May 8, 2013 at 8:29 AM    

thank you. it works ;)

Unknown May 8, 2013 at 3:06 PM    

thank you very much for this great information.

Unknown May 9, 2013 at 8:21 AM    

Thank you for this post, it was very helpful

Shivam Annapure June 10, 2013 at 12:33 AM    

Thank you so much .. it works :)

Myhox August 17, 2013 at 3:37 PM    

Hi GreenLuva !
Thank you for your helpful guideline. your guideline works for me and i would like to appreciate to you.

Unknown October 18, 2013 at 1:25 PM    

Thank you so much. This is so very helpful :)

MrDadi December 6, 2013 at 10:52 PM    

thank you so much that was very helpful

Tarun Singh December 31, 2013 at 1:42 AM    

Thanks so much.I added with the help of this post.