How to Add Google Analytics to WordPress

Last modified: June 17, 2020
You are here:
Estimated reading time: 2 min

Google Analytics is a free web analytics service provided by Google which tracks and reports website traffic. Google has launched this service in November 2005 after acquiring Urchin. It is the most widely used web analytics service on the internet today. Google Analytics is easy to set up for any kind of website. It is because you just have to add a piece of code that Google Analytics provides you.

But, if you are using WordPress, the process to install Google Analytics is even easier. It is because WordPress has tens of plugins specially built to install Google Analytics on the site. There are some advanced plugins that you can use to customize the tracking. In this tutorial, I am going to show you how to add Google Analytics to the WordPress site. To configure analytics in our WordPress site, we first have to create an account in Google Analytics. Let’s do it first.

Create a Google Analytics Account

Log in to the Analytics dashboard using your Google account. Once there, create a new property. You will see a form just like the following image.

Google Analytics

In this form, Enter all the required information like Site name, URL, Time zone and category. Once done, click on the Get Tracking ID button given at the bottom of the page.

Google Analytics

Now, It will generate a unique tracking number for your site. Once done, it will redirect you to a page where you can find the tracking ID as well as the tracking code. See the following screenshot to locate the Tracking ID as well as the Tracking code. Copy the tracking code, we will add it to WordPress in the next step.

Google Analytics

Add Google Analytics Tracking Code to WordPress

Now, log in to the admin panel of your WordPress site. Hover over the Plugins option given in the left sidebar and click on the Add New button to search and install new plugins.

In the WordPress plugin repository, search for Google Analytics and install the plugin that is highlighted in the following screenshot. You can also use different analytics plugins if you want, but the one we are going to install is the simplest from all.

Google Analytics

Install and Activate that plugin. After that, click on the Settings -> Google Analytics option from the left sidebar of the admin panel. On that page, you will see a form with one field and one submit button, just like the following image. Enter your tracking ID in the Web Property ID field and hit the Save Changes button.

Google Analytics

Now, Google Analytics will start tracking visitors on your website. So, this is how you can install Google Analytics on a WordPress site. If you have any questions regarding this, please let us know in the comment section given below.

LEAVE A REPL

Was this article helpful?
Dislike 0
Views: 9