Google Analytics is a powerful tool that helps website owners to track and analyze their website traffic. Google Tag Manager (GTM) is a popular tag management system that makes it easy to add and manage Google Analytics tracking code on a WordPress website. In this post, we will discuss how to add Google Analytics with Google Tag Manager in a WordPress website in detail.

Step 1: Create a Google Analytics account

The first step is to create a Google Analytics account by visiting the Google Analytics website. If you already have a Google account, you can sign in using your existing credentials, or you can create a new account for free.

Step 2: Create a new property in Google Analytics

After creating an account, you need to create a new property, which is a virtual property that holds all your website data. Click on the “Create Property” button and follow the instructions to create a new property.

Step 3: Copy the Google Analytics tracking code

Once you have created a new property, you will see a tracking code snippet that you need to add to your WordPress website. Copy this tracking code snippet to your clipboard.

Step 4: Install the Google Tag Manager plugin

To add the Google Analytics tracking code to your WordPress website, you need to install the Google Tag Manager plugin. Go to the WordPress dashboard and click on the “Plugins” option, then click on the “Add New” button.

In the search bar, type “Google Tag Manager” and click on the “Install Now” button next to the Google Tag Manager plugin. After installation, click on the “Activate” button.

Step 5: Configure the Google Tag Manager plugin

After activating the plugin, you will see a new option called “Google Tag Manager” in the WordPress dashboard. Click on it and then click on the “Settings” option.

In the settings page, you will see a field where you can paste the Google Analytics tracking code that you copied in step 3. Paste the code and click on the “Save Changes” button.

Step 6: Create a new Google Analytics tag in GTM

Now that the Google Tag Manager plugin is installed and configured, you can create a new Google Analytics tag in GTM. To do this, go to the GTM website and create a new tag.

In the tag configuration, select the “Google Analytics – Universal Analytics” tag type and enter the Google Analytics tracking ID that you obtained in step 2. Leave the other settings as default.

Step 7: Create a trigger for the Google Analytics tag

After creating the Google Analytics tag, you need to create a trigger that will fire the tag. The trigger can be based on various actions, such as clicks, page views, and form submissions.

Once you have created the trigger, you need to associate it with the Google Analytics tag. This will ensure that the tag fires only when the specified action occurs.

Step 8: Publish the changes in GTM

After creating the Google Analytics tag and the trigger, you need to publish the changes in GTM. This will make the Google Analytics tracking code live on your WordPress website.

Step 9: Verify the Google Analytics installation

To verify if the Google Analytics tracking code is installed correctly, go to the Google Analytics website and click on the “Admin” option in the bottom left corner. From there, select the property that you created in step 2 and click on the “Tracking Info” option. Then, click on the “Tracking Code” option to see if the code is installed correctly.

In conclusion, adding Google Analytics with Google Tag Manager to your WordPress website is a straightforward process that can be completed in a few simple steps. By using GTM, you can easily manage various tracking codes, including Google Analytics,

Read- How to Add Google Tag Manager to Your WordPress Website

Leave a Reply

Your email address will not be published. Required fields are marked *