BLOG

Track Your Website Statistics with Google Analytics Tracking Code

Are you ready to start tracking website statistics?

If you were following along with my last blog you should have:

  • Written your goals and a measurement plan for your website
  • Prepared your website
  • Added your property (website) to Google Analytics.

Now that we’ve signed up with Google Analytics, we have a tracking code available.

In this blog, I’ll go over what the code is for, how to use it, and how to get people to your website, so you can test your measurement plan.

 

Setting up Google Analytics

It’s not enough to just sign up for Google Analytics. You also have to take the code that’s assigned for your specific property (website) and insert it into your website code. It should be on every page of your website or at least every page you want to track.

Think of the code as a flag to Google – it tells it where to look and what information to track.

Now, let’s go into Google Analytics and pull up your tracking code.

  • Sign into your Google Analytics account
  • Click on Admin-bottom left of the screen
  • Select your account from the Account column-if you have more than one
  • Select your property from the Property column
  • Under Property select Tracking Info
  • From the drop down under Tracking Info select Tracking code

In this example, I’ve used Kickassatsocialmedia.com. You should have a screen that looks like the following:

Google Analytics Tracking Code Example

  1. Tracking ID is the ID number for your website
  2. Status shows the current status of tracking for your website. Yours (like mine) should show “no data received” because we haven’t added the code to our website yet.
  3. Website Tracking is our code we need to add to our website
  4. Don’t worry about anything below 4 – unless you’re comfortable with PHP and other options.

 

Leave this page open in a browser tab while we move on to the next step. We’ll be back to copy the code.

 

Adding the code to your website

Adding the code to your website is fairly straightforward. However, if you’re not comfortable with adding code, you should contact a professional who can set this up for you.

Below are instructions for the Divi theme, as well as other options.

If you have WordPress with the Divi theme

Most themes in WordPress make it simple to add your Google Analytics code. In this example we will use Divi, one of the most popular themes for WordPress.

To add the code:

1. Open a new tab on your browser
2. Sign in to your WordPress website
3. Click on Divi on the left side navigation
4. Click on Integration
5. Scroll down to the section headed “Add code to the < body > (good for tracking codes such as google analytics)”

Divi tracking integration example

6. Go to your Google Analytics website
7. Copy the code from the Website Tracking section
8. Go to your WordPress website and insert the copied code into the “Add code…” section
9. Scroll to the bottom of the page and select Save

Note: If you ever change your theme, you’ll have to add the code back into your website.

 

If you have WordPress with a different theme

It’s easiest to add a plugin to do the work for you. Below are two of my recommended plugins, and each will walk you through the process of adding your code.

 

If you have a non-Wordpress website

If you’re not comfortable with adding code, you should contact a professional who can set this up for you.

However, if you are comfortable with editing code and you know how to access your HTML code for your website, then do the following:

  1. Copy the tracking code for Google Analytics
  2. Go to your website HTML code
  3. Locate the closing head tag    – that is </header>
  4. Put your cursor above that tag and paste your code in
  5. Save your changes

Make sure that you’ve inserted the code into every header you have for each page.

Verify the code

Now that the code is in, it’s time to make sure we’ve inserted it and it’s working.

  1. Go back to the Google Analytics Tracking page.
  2. Under Status, click on Test Traffic
  3. When you click on the link it should open the site as a new browser tab
  4. Click on the browser tab to go back to Google Analytics
  5. The system should show one person is currently on the website (you)

If this didn’t work, I’d suggest making sure you went through all the necessary steps for your type of website.

 

Checking the code

This section is for those of you who might have added the code years ago, and don’t remember what pages you added it to.

Head to GA Checker and enter your web url. This website will check all of your pages and list out all of them that currently have the code.

Getting people to your website

Wow! You did all this work on your website so now it’s time to send people to check it out. Keep in mind, this is so you can start your measurement plan that you created from blog 1.

 

Below are some of the ways you can get people to your website:

  • Share a link to your friends on Facebook and ask them to check out your website.
  • Share a link on your business social media – tell people why they should visit your website.
  • Create a Facebook ad.
  • Talk to bloggers who write in your field to see if they’ll write about your subject/area and would include a link to your website.
  • Write a newsletter to your email list and include a reason why they should go visit the website.
  • Create an ad for a newspaper or magazine with your website listed.
  • Create an ad on Craigslist.

Note: When you do any of these posts or ads, create a spreadsheet to track each item. For example, track the: Type, Date, Time, and responses to the post so you understand how well each one worked.

In the next blog, I’ll explain the Google Analytics reports, and share information on how to tell if your measurement plan is working.

In the meantime, to begin keeping track, download our free analytics management audit excel to help you track your efforts.

 

analytics management audit excel

 

Other articles you may be interested in

Thumbnail image
Sonja D.

As in instructor at the University of New Mexico Continuing Education, Sonja Dewing has been working with small businesses for over ten years on their social media, blogging, marketing and website plans.

Thumbnail image
Amar T.

Amar is the president and co-founder of AmDee. He has been an industry leader in accessibility compliance—auditing and remediating websites, publishing articles, delivering presentations to national audiences, and training content editors and developers in accessibility best practices.

You May Also Like

Measuring the User Experience of a Website

Having a website is an absolute necessity for any business. Gone are the days when you could simply update your website once and forget about it for months on end. In today’s ever-changing digital landscape it is important to constantly track and measure how well your website performs, as well…

read more >
Modernize Your Website: 5 Key Updates for 2024

Thomas Bertram (T. Bert) Lance famously said, "If it ain't broke, don't fix it." Unfortunately, T. Bert Lance couldn’t foresee the future. He didn’t know that over 94% of Americans would be on the internet by 2024. If your website doesn't receive periodic updates or isn't accessible, users can become…

read more >