Ready To SKYROCKET Your Blog Traffic?? Get an instant access to the ULTIMATE List of 350+Pinterest Group Boards and FB Groups. Subscribe and get regular updates and tips about Blogging!

How to add Google Analytics to WordPress?

Sharing is caring!

If you have no idea about google analytics or too scared to get into it then this post is for you. In this post, I’m going to show you how to add Google Analytics to WordPress in a very easy way, the way I understood.

Last time, I installed Google Analytics at the starting of my blog but never really tried to understand it except for checking page views because it looked too technical and boring. I didn’t understand it’s importance and missed few good chances to grow my blog., hence it failed.

You can read more about it here.

I don’t want you to make the same mistake like me so here I go trying my best to explain how to add google analytics to WordPress in a Simple and straightforward way.

Add google Analytics to wordPress


Google Analytics is a software that creates reports and gives live information about your audience, content, traffic source, demographics of your audience to name a few. Google analytics is one the most important part of your blog.  If you want to grow your blog, make a good relationship with Google Analytics.

Why do you need Google Analytics?

You need Google Analytics because it helps answer many important questions regarding your blog performance. Some of them are: –

  • The number of people that visit your website
  • The popular blog post or content on your site
  • The demographics of your audience
  • The popular pages on your site
  • If your readers are on mobile, desktop or tablets
  • The geographic location of your audience.
  •  Which website or social media site is sending visitors to your site?

All these answers will help you to create more audience-focused content. Shift your focus to one or two well performing social media account. Choose right day to publish your post. Get to know the busiest day and time of your blog.

If make yourself more aware of GA then it’ll help you a lot in taking your blog to next level.


First, you need a Google Analytics account. If you have an account with Google (Gmail or any other account) then you can use that account to create GA.

Click on Sign in button on Google Analytics to set up your account. You will then be greeted with the three steps you must take to set up Google Analytics.

add Google Analytics to WordPress

Click the Sign Up button and fill out information on your website.

add Google Analytics to WordPress

The process is pretty simple and easy to follow along:-

What would you like to track: Choose website

Account Name: Enter your name here.

Website Name: This is to help you keep track of all the websites you have on your account.

Website URL: Enter your domain name.

Industry Category: Choose a category that your website fits into from the drop-down menu.

Reporting Time Zone: Choose your corresponding time zone.

Data Sharing Settings: This is to decide if you want to share your Google Analytics data with Google representative and receive emails from them. I usually uncheck them all.

Google Analytics

Once you are finished, you will click the Get Tracking ID button. You will get a popup of the Google Analytics terms and conditions, which you have to agree to. Then you will get your Google Analytics code.

Congrats!! Your Google Analytics account is Set up.


To start tracking your website performance and get the full picture of your blog, you’ll have to add the Google Analytics code to your website header.

There are two ways to do this:-

Step 1: What I did was installed a plugin called Header and Footer in my WordPress and added the code in the header section of the plugin. It’s very simple.

To install a plugin, go to your WordPress Dashboard and click on plugin> add new > type Header& footer or any other plugin that you want to install.

Some people prefer plugins like Monster insight but the reason I choose Header & footer plugin is this plugin is multi -useable. Any code that you need to add to the header or footer of your site can be added using this plugin. For example, tracking code of your ads or in my case, I have added the sign-up form at the header using this plugin.

By the way, you can check your GA report straight in google so there is no need for an extra plugin.

add Google Analytics to WordPress

Step 2: To add the code to the header section of your theme.

I wouldn’t recommend messing with your theme unless you are sure of it. Move over when your theme gets updated there is a high chance that you might have to re-add those codes, double work.

But, if you insist then click on Appearance on WordPress Dashboard> Editor> Theme header> and add your code.

That’s It. Congratulation!! Your Google Analytics is set up and ready to track the performance of your Site.



The one screen where I have my eyes glued is REAL-TIME. I think most of the bloggers are obsessed with their pageview numbers, at least I’m.

Especially in the beginning when you are trying to see if people are coming to your site. Are they enjoying your work? Thousand times I’ve told myself that I’ll only check Google Analytics at the end of the day but am I listening to myself??? NOPE!!

Ok, let see what can we learn from the real-time report.

add Google Analytics to WordPress

To get this screen, click on Real-Time on the right side of the dashboard and hit Overview.

On this screen, you can see –

  • the total number of users browsing your site at that very moment
  • pages and post they are reading,
  • their location as well as
  • the source that referred them to your site like Pinterest, Facebook etc
  • devices that your readers are using to access your site like mobile, desktop or tablet.

Amazing huh???


As the name suggests, this report is important to check your business health. Here you can check the number of users who visited your site as per days, weeks, months and year. It’s important to understand this report. Check the below screenshot.

add Google Analytics to WordPress

From this screen, I can find out the number of users who visited my site from 18th – 27th of March. The total number of page views, users, new users and bounce rate – is the rate at which users are leaving your site (lower the bounce rate, better it is. )

If a bounce rate is higher then you’ll have to find out what is making your readers leave your site? It could be many things like less number of posts, the standard of content, site performance, site load time, font, ads etc. Among these, load time and overall site performance are the major ones. Also, for me, small font size means bye-bye.

You can also see if you are retaining old readers in the pie chart.

Familiarise yourself with different subreports, it’ll help you a lot to understand your audience.


Aquisition report is mainly for your traffic source. This report helps you to find out your traffic source. From here you can figure out which platform to focus on – Pinterest, Facebook, Instagram or SEO. You can also find out which landing page is performing better.

If there is any website referring traffic to you?? You’ll know every point of source for your traffic and accordingly focus on a well-performing source, work on strategies that are working.


This is one of the most important reports as it gives you more info about your content. From this report, you can find out your most popular post and create more content on that topic, add affiliate links to that post.

If you are writing about multiple topics and not able to figure out your focus area then this report will help you to find your direction.

You can also check your site speed from this report which is very important for good user experience. More on this in next post.


add Google Analytics to WordPress


These are few important reports that will help you tremendously to understand your business progress and decide your next step.

If you keep a close eye on your reports then you’ll understand your audience, their preference and you’ll be creating more useful content for your audience. I’m sure you must have read many times that you need to know your audience to create valuable content. Do you know how to find out your audience and serve them right content???

YES, you do now!!

Just check your Google Analytics reports. You’ll not only know what kind of content your audience like but also where are they based. What are the busy time for your site and the busy day?

This information will help you in Creating useful content for your readers, schedule your content properly, choose a  right time to be on social media and focus on your successful social media account etc.

Google Analytics is not just to check the page views but it’s a lot more than that. I hope this how to add Google

Analytics to WordPress guide will help you understand your analytics better and make the best use of it.

Good Luck!


Have you set up your blog??? If not then check the step by step tutorial to set up a blog with SiteGround.

If you need any help then don’t hesitate to contact me or Join my Facebook community to get in touch with me daily plus network with fellow blogger and grow your BIZ.

Subscribe to my newsletter and get more updates from


Sharing is caring!

3 thoughts on “How to add Google Analytics to WordPress?”

  1. This is such a comprehensive guide! I could have used this when I was trying to set analytics up on my blog. I’m obsessive about checking my stats too!

    1. I guess Catherine, we all -bloggers are obsessed with our Stats. I have even installed WP app on my Phone and if my laptop is off then I’m on my phone…lol. Thanks for stopping by.

Leave a Comment

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

This site uses Akismet to reduce spam. Learn how your comment data is processed.