Google Analytics, How to Add a Website to Your Account and Get a Tracking ID

Setting up a Google Analytics account and adding the tracking code to your website is the first step to collecting statistics. This article presents several ways to install Google Analytics on your website (blog, online store, etc.). We'll also figure out what Google Analytics is, how to add a website to your account and get a tracking ID.
Google Analytics, How to Add a Website to Your Account and Get a Tracking ID

Ways to Add Tracking ID to Website

Setting up a Google Analytics account and adding the tracking code to your website is the first step to collecting statistics. This article presents several ways to install Google Analytics on your website (blog, online store, etc.). We'll also figure out what Google Analytics is, how to add a website to your account and get a tracking ID.

Why is it worth installing Google Analytics on your website at all?

Google Analytics is a service from Google designed for webmasters and optimizers that allows you to analyze user behavior on the site. The collected information is hosted on a remote server from Google.

When you add a website to google analytics, you will be able to get 4 main components: data collection, data processing, customization, and reporting. Each time a visitor visits the site, a tracking code is executed in their browser.

With this tool, you know:

  1. How many people visit your site.
  2. Which pages they visit.
  3. How long they spend on the site.
  4. What percentage of users have made a conversion (purchase, subscribing to a newsletter, filling out a contact form, etc.).
  5. How fast your site loads.
  6. How many people view the site on mobile devices
  7. The average number of pages users visit per visit.
  8. And so on, and so on ... there is a sea of ​​possibilities.

However, start with the basics, that is, add some basic tracking code.

Create a Google Analytics account

To get the tracking code, you must first create an account with Google Analytics and then create a service (which will have a special number UA-XXXXXXX-Y).

If you already have a Google Analytics account and service, you can skip this step.

Otherwise, go to the Google Analytics website and create an account.

Use Google's ready-to-use instructions for this. There is no point in duplicating them in this article.

If you have a Google account (for example, you use Gmail or YouTube), all you have to do is sign in with this information and create a GA account.

When you create an account, the first service and view will be ready automatically.

For your blog stats to be visible in Google Analytics, you need to add a tracking code to your website.

This can be done in the following ways:

  • Google Tag Manager (Recommended).
  • Through the site control panel.
  • Paste the code directly into the HTML of your website.

We recommend the implementation using Google Tag Manager, that is, a tag manager. In short, it is a standalone browser application from which you can add various scripts to your site.

If in the future you want to add, for example:

  • remarketing code,
  • Facebook pixel,
  • Heatmap utility script,
  • tracking events in Google Analytics.

Then you don't have to fumble in the source code of the site. You can add all of this at the Google Tag Manager level. Without developer assistance.

It is an easy to use and safe solution. Especially for non-technical people.

Adding Google Analytics using Google Tag Manager is a great way to get used to this tool and add it correctly to your website.

ATTENTION! If you run an online store and want to follow the ecommerce module through out-of-the-box integration with the store platform, it is probably best to implement Google Analytics through the store admin panel.

Failure to do so may result in tracking issues. Instead, add the Google Tag Manager container anyway - just don't create a Google Analytics tracking tag in it.

How to install Google Analytics via Google Tag Manager

First you need to create a Google Tag Manager account.

Go to https://tagmanager.google.com/, click Create Account and create a new account and container.

When the next screen appears, keep the tab closed. You will need these codes immediately.

Now for the most important part, which is adding the GTM code to the sections and on every subpage of your site.

Master Website Creation: Enroll Now!

Transform your digital presence with our comprehensive Website Creation course – start your journey to becoming a web expert today!

Enroll Here

Transform your digital presence with our comprehensive Website Creation course – start your journey to becoming a web expert today!

Store platforms or WordPress offer solutions that allow you to insert any code into or from your admin panel. Of course, without interfering with the work of the site template.

Next, we will present the installation of GTM on a site using the example of WordPress.

  • Open your WordPress admin panel in a new tab.
  • Go to Appearance - Editor.
  • In the list on the right, find and click Topic Title.
  • In the source code, find the snippet and paste the GTM code for the part directly below it (first at the top in the previous screen).
  • Now find the snippet and paste the second part of the GTM code right after this tag.
  • Click the Update button. Ready!

Tagging with Google Analytics Tracking Code

Open Google Tag Manager and add a new tag.

Enter the following details:

  • Name: UA - Page view.
  • Tag type: Universal Analytics.
  • Tracking Type: Page View.
  • Google Analytics settings.
  • Click New Variable.

Insert your tracking ID.

Rule: All Pages.

Save the tag.

Now click on the gray Preview button.

Make sure tracking is working.

Now it remains to check if you have added the GTM and GA tracking code correctly.

Go to your website.

You will see a Google Tag Manager preview pane at the bottom of the screen.

If you see UA-Pageview among the triggered tags, then everything is working.

Using plugins

Some websites have dedicated plugins with which you can easily customize the tracking code loading. This is a popular solution, especially on WordPress sites.

Popular WordPress plugins include Analytics Tracker or Google Analytics from MonsterInsights - just download and run them, then paste the tracking ID into the corresponding field in the settings. However, you can also use the ability to enter tracking code through plugins such as Yoast or All in One SEO - popular plugins to customize your site's SEO optimization.

The tracking ID in the All in One SEO plugin on your WordPress site is simply inserted into the Google Settings module.

The advantage of this solution is that you don't need access to system files - just paste the tracking code into the field specified by the plugin. This is a guarantee of the successful implementation of the UA code on the page, and not inserting the code into the header file (via Appearance - Editor - Page Header).

Why? Because it happens that when WordPress is updated, it removes the tags inserted through the editor. Therefore, using a plugin in this case is an easier solution than constantly changing the code manually in the editor.


Master Website Creation: Enroll Now!

Transform your digital presence with our comprehensive Website Creation course – start your journey to becoming a web expert today!

Enroll Here

Transform your digital presence with our comprehensive Website Creation course – start your journey to becoming a web expert today!



Comments (0)

Leave a comment