How to Install Google Analytics on WordPress Website in easy way

Lets learn how to install or integrate Google Analytics into your wordpress website : Once we create any WP blog or website, our primary objective is always getting huge traffic on our website. It doesn’t matter whether we are running a simple blog or some kind of ecommerce website. To make our website popular or to increase our sale its very important to have regular visitors on our website.

We use many marketing strategies to increase traffic on website but the questions comes how to see report. How to find out whether we are getting results or not. Few general questions are:

I want to know how many visitors are visiting your website?

I want to know from which country or region you are getting most of the visitors?

I want to know which post/article or page is mostly viewed by your website visitors?

I want to know that I am getting more visitors from mobile devices or desktop/latop?

We have single solution for above all questions. Use Google Analytics on your website to know about your website audience or visitors.

In this article, we will guide you how you can install Google Analytics on your website.


Google Analytics is a Google web analytics services which tracks and reports about your website traffic, it lets you know how many visitors are visiting your website day/weekly/monthly/yearly etc.

This platform is currently inside the Google Marketing Platform brand. Google Analytics lets you measure your advertising ROI as well as track your Flash, video, and social networking sites and applications.

How does Google Anlytics work?

Google Analytics works by the inclusion of a block of JavaScript code on pages in your website. When users to your website view a page, this JavaScript code references a JavaScript file which then executes the tracking operation for Analytics.

Is Google Analytics free to use?

It’s free:)

You should just open account and copy/paste Universal Analytics code to your website and start tracking.

Importance of Google Analytics.

If you have a website or blog, your number #1 goal will be to get traffic on your website. It simply means the number of visitors on your website. Google Analytic shows your stats of your website with detail reporting about your visitors, their location, the most popular content on your website etc.

Which users visit your website?

Google analytics shares with you your visitors locate. You can see from which country and location are you are getting visitors on your website. You can also see what browser they are using to visit your website. You can get some addition information like what resolution your visitors, do their browser support javascript, flash support, languages etc.

You can use this information to understand your visitors needs and you can make your website to fulfil these requirements. In this way, you can reduce the bounce rate of your website visitors.

What time people visit your website?

Google Analytics reports also let you understand what is the prime time when users visit your website and from location as well. By this this information, you can select a time to post article or update information on your website.

How do people find your website?

This information will help you to under from which sources you are getting most of these visitors. For example: you can get visitors from search engines, direct links, referral links, or direct visiting your website, social media sites like: Facebook, twitter, Instagram etc.

It will help you to understand your marketing strategic results. You can manage or update your website promotion campaign as per these results.

What people do with your website content?

You can track your website visitor’s activity. You can see which pages/posts of your websites getting viewed more. In this way you can understand the interest of your website visitors and you can manage update your website content as per your visitors interest.

How to create account on Google Analytics

To install Google Analytic on your website first you to need to have an Google Analytic account.

Step 1: First you need to visit Google Analytics sign up.

It will ask you to login using of your google account. If you already have a google or gmail account use that information to login otherwise create a google account first and then login to “Google Analytic” account.

Step 2: Once you sign in using your google account. You will see a welcome screen for “Google Analytics” page. Now, you are ready for Sign Up process.

After that, you will be asked to provide an account name. This name will be used internally so you can use anything like your business name.

Step 3: On the next screen, you will be given choice to choose between a website or mobile app. Make sure you select website.

After that, you need to enter website name, website’s URL, country, and the time zone. Now, you will be presented with Google Analytics terms and service which you must agree to, so click on ‘I Agree’ button.

Step 4: Now you will be presented with your Google Analytics tracking code. You can copy this tracking code because you will need to enter it in your WordPress site depending on the method you use below.


I am trying to make this article as simple as possible. There so so many ways to install Google Analytic code on your WP website but I will not confuse you by sharing so many methods with you.

I will share only few simple methods with you.

  • Using WP free plugins
  • Using Manual method (Putting code inside header.php)

Install Google Analytics on WP website using WP plugins:

Header Footer WP plugin

  • Install and activate the Insert Headers and Footers plugin.
  • visit Settings » Insert Headers and Footers page
  • Paste the Google Analytics code that you copied in step 4 into the headers section.
  • Save changes and you are done!

Google Analytics Dashboard Plugin for WordPress by MonsterInsights

  • Install and activate “Google Analytics Plugin for wordpress” by MonsterInsights
  • Once you install this plugin, it will add a new menu item labeled ‘Insights’ to your WordPress admin menu. Clicking on it will bring the MonsterInsights setup wizard.
  • Just follow the step by step instructions to connect it with your Google Analytics account.
  • It will ask your permission to “allow” you to connect your Google Analytic account with your website. Just allow it and you are done!

Add Google analytic code on your website on header.php manually.

If you don’t want to install any extra plugin on your WP website and just want to add this code every page of your website. You can do it by adding manually on your theme file named header.php

To do this you can either do it using WP admin panel using:

  • Login to your WP website admin panel
  • Click “Appearance > editor”, Now you will be able to see your theme files.
  • Click on “header.php” file and paste your “Google Analytic” code just before the </body> tag
  • That’s it.

You can also use FTP login details to access your website theme files as well or cpanel details J

It’s all up to you.


Google Analytics reports will show you details information about your website visitors and some of the import are :

Real Time: It will show you real time traffic of your website.

Audience: This tab will show you information about your website visitors

Acquisition: It will share location of your website visitors

Behaviour: This report will show what your visitors do normally once they visit your website.

Conversion: This report will show you how you are performing with your website goals.


It is very important to have an eye on your website results and Google Analytics helps you to do this. Almost every smart website owner add Google Analytics on their website so that they can track their website traffic and by reviewing reports in details they can make necessary changes on their website.

It’s very important to make changes/modifications on your website as per your website audience interest.
I hope this article will help you to add Google Analytics on your WP website.

One Reply to “How to Install Google Analytics on WordPress Website in easy way”

Leave a Reply

Your email address will not be published.