Tracking and monitoring your website traffic play a vital role in your website success.

How is your website or blog doing? Is your traffic growing according to your goals?

While growing your traffic is another topic altogether, monitoring your website traffic will give you a big picture of how well or bad your website is performing.

With the data you captured, it is easy to measure what online strategies are working and what needs to be fixed. It’s never too early to track and monitor your site traffic.

Tips: Start capturing and monitoring your website data right from day one.

In this post, you will learn how you can add Google Analytics to WordPress without installing a plugin.

Let’s get started.

Adding Google Analytics to WordPress site without a plugin

Why do you need to set up Google Analytics?

Most of you are probably familiar with Google Analytics.

Google Analytics is a freemium web analytics service offered by Google that tracks and reports website traffic. It is the most widely used web analytics service on the internet.

With Google Analytics, you could track these key metrics on your site:

  • Sessions
  • Page Views
  • Traffic Sources
  • Bounce Rate
  • Conversion Rate
  • Devices type

These key metrics will provide you with answers to the following basic questions:

  • How many visitors visit your website on a daily, weekly or monthly basis? You could track based on a certain date range.
  • What’s the average number of page views per visitor?
  • How many visitors are exiting your website without any clicks? What’s the average time a visitor spends on your website?
  • What are the most popular landing pages on your website?
  • How do your visitors find your website?
  • Where is your audience from?
  • On what devices are your visitors visiting your website?

Once you are able to answer these questions, you can formulate better online strategies for your website and fixes any issues.

For example, if the majority of traffic visiting your website comes from a mobile device, you need to make sure that your website is mobile friendly.

[clickToTweet tweet=”How to add Google Analytics to WordPress without a plugin? #wordpress #analytics” quote=”How to add Google Analytics to WordPress without a plugin?”]

How to add Google Analytics to WordPress without a plugin?

If you’re on WordPress, you might find out there are so many plugins that let you set up Google Analytics.

But, that’s not the goal of this post.

If you prefer to install a plugin, check out our step by step guide on how to install a WordPress plugin.

In this post, I am going to teach you how you can add Google Analytics in WordPress without a plugin.

Let’s get started!

Step 1: Set up your Google Analytics account

If you already set up your Google Analytics account, you could jump to step 2.

Head over to Google Analytics, and sign up for a new account. Enter your website details and add it to your account.

Google Analytics add new account

Step 2: Get your Google Analytics tracking code

Log into your Google Analytics account and click on Admin on the sidebar.

Google Analytics dashboard

Select the website that you want to get the tracking code for by selecting the right Account and Property from the drop-down.

In the Property column, click Tracking Info followed by Tracking Code.

Google Analytics select properties

On the next screen, you should be able to see the script that you need to add to your WordPress site. Simply click on it to select the script and copy it.

Google Analytics tracking code

Step 3: Add Google Analytics tracking code to header.php file

Log into your WordPress Admin dashboard and go to Appearance > Editor. Click on header.php file on the right sidebar.

Note: Make sure you’re editing your child theme so you don’t lose your tracking code when you updated your theme.

WordPress edit theme header

Paste the code that you copied right before the </head> tag.

WordPress edit theme header

Click Update and you’ done!

Final Thoughts

That’s it, you’ve added Google Analytics in WordPress without a plugin. You might also want to see our tips to speed up your WordPress site.

For more details on how to set up your own blog, check out our step-by-step guide. Or, let us create your blog for free. Find out more details here.

Now that you have Google Analytics all set up, you can start monitoring your website traffic. As you analyze the website traffic data, you will be able to identify what type of content, campaign or strategy that works for your website and audience. Check out this guide to improve your writing readability and get more traffic.

Don’t forget to share it with your friends.

If you have any questions or thoughts, drop a comment below or contact us here.


Yuyu

I am a front-end developer and I teaches entrepreneurs who want to grow their audience, start an online business, and pursue their dream life. When I spend time away from the computer, I enjoy reading books and having a cup of green tea.

All author posts