Fixed Knowledge Base

Get all the help you need here.

Installing Google Analytics

Posted 04th октомври, 2018

Google Analytics is a free analytics tool which analyses and displays website traffic data. It consists of the following:

  • User behaviour tracking, including pages opened, traffic sources.
  • Information about each user's sessions
  • Detailed informations on videos watched and other site usage data.

Before you start using the service, you will need to firstly make an account with Google Analytics. If you already have an account with google, you can use this to log in directly.

You will ned to validate your domain name: to do that follow these steps:

  1. Log into Google Analytics.
  2. Select Create new property option from the panel on your right.
  3. Add your domain name (select the preferred protocol and add it without any characters following the name, including a trailing slash (yoursite.com, not yoursite.com/)).
  4. Download the html validation file.
  5. Upload the validation file to the site directory on your hosting panel.
  6. Confirm uploading the file from the Google Analytics panel.

You will not be given a tracking code (in the format UA-) to add to your website.

Add Google Analytics to WordPress

Analytics can be added to the theme as follows:

  1. Connect to the file system on your hosting.
  2. Navigate to wp-content/themes/YourTheme/
  3. Using a text editor by choice edit your header.php file and right under the < body > paste the Google Analytics tracking code.

You may wish to create a child theme.

Alternatively you could install a Google Analytics Plugin to your website.