TrustPulse Marketing Blog

Actionable advice to boost your website conversions.

Featured image Add Google Analytics WordPress

How to Add Google Analytics to WordPress (Step by Step)

Do you want to add Google Analytics to WordPress to grow your traffic?

By using Google Analytics, you’ll gain a deeper understanding of your audience. It’s the best way to get to know your site visitors and give them exactly what they want. That’s why if you want to increase your traffic, you need Google Analytics.

The problem is that it’s not always straightforward to install or use this important tool.

Fortunately, it’s easy to add Google Analytics to WordPress using a plugin.

By the end of this article, you’ll know exactly how to add Google Analytics to your WordPress site with and without a plugin.

Why Add Google Analytics to WordPress

There are several reasons why you should add Google Analytics to your WordPress site.

Google Analytics tracks your website traffic and tells you how people are engaging with your site. You’ll be able to uncover your most popular pages, offers, and traffic sources. Instead of guessing which content and campaigns your audience loves, you can check the stats for yourself.

Using Google Analytics, you can view:

  • Top performing content
  • Biggest referral sources
  • Length of time readers spend on your site
  • Bounce rate

You’ll also be able to learn more about your audience, like where they’re from and the devices they use to browse your site.

This information will guide the choices you make about content and marketing campaigns.

For instance, if you’re a content publisher, you can use the insights to create better content for your readers. As a result, you’ll be able to increase the time people spend on your site and even decrease your bounce rate. Online store owners can track the point of sale, determine when shoppers abandon their carts, and identify their highest converting pages. This gives you the data you need to improve your checkout process and encourage sales.

As you can see Google Analytics helps you answer so many questions about your audience.

So, you might be wondering how do I add Google Analytics to my WordPress site?

The good news is that it’s incredibly easy to add Google Analytics to your site.

You simply need a Google account and 10 minutes.

Let’s begin.

How to Add Google Analytics to WordPress

Adding Google Analytics to WordPress is quick, simple, and free.

Here are the methods we will use today:

  • Method 1: How to install Google Analytics Plugin on WordPress
  • Method 2: How to add google analytics code in WordPress without a plugin

Now, the recommended method is adding Google Analytics to WordPress with a plugin. That’s because it’s the easiest way, and you won’t have to write any code or worry about editing your WordPress theme.

Before we get into the details, we’ll need to create a Google Analytics account.

If you have already have a Google account, you’ll need to sign in to set up Google Analytics.

Or, create a new account.

Once you’re logged in with your Gmail account, you’ll be able to sign up for Google Analytics.

Google Analytics home page

Now, you will need to provide an account name. This is for internal use.

Click Next.

Name Google Analytics Account

Choose Web on the following screen.

Choose Web in Google Analytics

Next, you will need to add your:

  • Website name
  • Website URL
  • Time zone

Click Create once you’ve added your details.

Google Analytics Account details

Now, you’ll need to accept Google’s terms of the agreement.

Accept Google Analytics terms of agreement

On the next screen, you’ll see your tracking code.

Google analytics tracking code

We’ll come back to this a bit later depending on which method you choose.

Now, let’s look at two ways you can add Google Analytics to WordPress.

Method 1: Installing Google Analytics Plugin on WordPress

We’ll start with the simplest method for adding Google Analytics to WordPress.

For that, we’ll use the MonsterInsights plugin.

MonsterInsights is the best Google Analytics WordPress plugin because it comes with an easy to use dashboard and powerful features.

MonsterInsights Track your Growth Hacking Strategies

Now, we know Google Analytics offers a lot of data. That’s a good thing. But it can be overwhelming to sort through the reports to find meaningful information. With MonsterInsights, you get to view the most important statistics right from your WordPress dashboard.

All you need to do is download the plugin and view your reports from the dashboard.

With MonsterInsights, you get:

  • Access to your analytics right from inside your WordPress dashboard
  • Quick Google Analytics set up without writing any code
  • Easy to understand audience and content reports

This is why MonsterInsights has more than 2 million active installs and the most popular Google Analytics plugin for WordPress.

One of the best things about the MonsterInsights plugin is that it’s regularly tested and optimized for speed. This means it won’t slow your site down like poorly coded WordPress plugins. Of course, site speed is important because it can influence your SEO.

Below, we will walk through how to set up MonsterInsights in 5 minutes or less.

First, you need to download and activate the MonsterInsights plugin.

Once you have installed the plugin, you can set up MonsterInsights right from WordPress.

After activating the plugin, you’ll see the Insights tab in your dashboard.

Click Insights.

Select Launch Setup Wizard.

Start Monsterinsights wizard

This will start step by step instructions for you to install Google Analytics.

On the next screen, you’ll need to share more about your website.

Monstersinsights welcome screen

Click Connect MonsterInsights.

Connect to Monsterinsights

Now, you’ll need to sign in to your Google account.

Click the Allow button to add Google Analytics to your WordPress site.

Allow MonsterInsights to Access Google Analytics

The next step is to select your website and click Complete Connection. Now, MonsterInsights will add Google Analytics to your WordPress site.

That’s it. You have installed Google Analytics on your WordPress site.

Keep in mind that it will take some time for Google Analytics to show your statistics.

Once you’re up and running, you can view your data right from your WordPress dashboard.

Method 2: Adding Google Analytics Without a Plugin

The second method is adding your Google Analytics code in WordPress without a plugin.

Keep in mind this method is more complicated. Plus, you’ll be editing your website theme, and this could break your website. You’ll also need to add the tracking whenever you switch themes.

Before adding the Google Analytics code to your site, it’s a good idea to backup your site.

First, head back to your Google Analytics account.

Copy your tracking code.

Google analytics tracking code

Now, head over to your WordPress dashboard.

From the dashboard, click Appearance. Next, click Theme Editor.

Choose Theme editor

Select Theme Header.

Choose Theme Header

Paste your tracking code just before the closing head tag.

Closing head tag

That’s it.

Now, you’ll be able to track your site visitors and how they engage with your WordPress site.

We hope you found this article helpful.

Using Google Analytics is one way to turn your website into a business tool.

If you’re looking for more resources on growing your business using your website, check these articles:

There you have practical resources and strategies for using analytics to gain a deeper understanding into your audience. This means you’re one step closer to creating the content and offers they truly want.

Author Photo
Published by Bronwynne

Add a Comment

We're glad you have chosen to leave a comment. Please keep in mind that all comments are moderated according to our privacy policy, and all links are nofollow. Do NOT use keywords in the name field. Let's have a personal and meaningful conversation.

Increase Trust, Conversions and Sales NOW
Try TrustPulse 100% risk-free for 14 days!