How to install Google Tag Manager in your Website, WordPress, Squarespace & Wix | 2019 | Part 2

Опубликовано: 05 Март 2025
на канале: Web3
8,235
24

You can easily mess up your website and your Analytics data if you don’t install Google Tag Manager correctly. In this video, I’ll show you how to install Google Tag Manager correctly into your website code, WordPress, Wix & Squarespace.

If you haven’t done this already, Please feel free to check out my previous video where I show you how to install Google Analytics into Google Tag Manager.

What I’m going to show you in this video is:

1. How to put Google Tag Manager directly into your website source code.

2. How to do this in WordPress through both a direct
implementation into the code and also through the Google Tag Manager for WordPress plugin.

3. How do install Google Tag Manager in Squarespace

4. How to install Google Tag Manager in Wix.com

We start the video from inside Google Tag Manager. The first thing you need to do is get the website integration code out of Google Tag Manager.

To do this, go over to your Google Tag Manager container and find the ‘GTM-' and then a bunch of letters and numbers button. This will be sitting beside the preview button inside your container.

Click on that and that will open up a little window that will give you two pieces of code. One will be an integration code for your website header. The second one is a backup integration code for web browsers that have JavaScript disabled.

What you want to do with that integration code that you have retrieved from Google Tag Manager is to put it as high up in the head of the website is possible.

Place the second script immediately after the opening body tag in the website.

Here's how to set it up for WordPress websites:

1. From your child theme, open up the header PHP file

2. Next, do exactly what you did with the HTML website. Take the head code from Google Tag Manager, and then place that just after the meta titles and profiling information in the head of the website.

3. Secondly, place the backup script, the no script, just after that opening first body tag in the website.

4. Hit Save and that’s going to push it into the web server.

5. Refresh the website page. Next, open up the website source code again.

6. Double check that Tag Manager is working. Go back to Tag Manager, hit the preview button which will reload Google Tag Manager in preview mode. Go back to the website where you have Google Tag Manager installed. Refresh the page and you will see the Tag Manager's preview window or window fire at the bottom of the page.

7. Go over to my Google Analytics profile and open up the real-time overview report. You'll be able to see it working if your session appears on this screen.

Here's how to install Google Tag Manager into WordPress through a plugin:

1. Go to the plugin section

2. Hit 'Add Plugin'

3. Search 'Google Tag Manager'

4. Install the 'Duracell Tomi’s Google Tag Manager for WordPress by Thomas Geiger' plugin

5. Open the plugin's settings

6. Get your Google tag manager ID and paste it into the plugin settings

There’s a number of ways this plugin can pass Google Tag Manager code into your website.

Codeless injection is the one that we always recommend going with first. That way, you don’t actually have to do anything. You can set codeless injection. Save it, and once that’s been saved, you can go back to your website and do the same process we did before to check that it's working.

Next, let’s move on to how to install Google Tag Manager into Squarespace.

1. Inside your Squarespace Control panel, go to Settings / Advanced / Code injection.
2. Place the two scripts that have been used in our direct implementation. The head code has gone into the header section in the Squarespace editor. And the body backup no script code has gone into the footer section.

Although this is not semantically the right place to do it, it does actually work fine.

Keep in mind, if you want to install Google Tag Manager into Squarespace, you’re going to need the premium plan to do this.

Once that has been saved, go back and now open up your website into the full view. Check that Google Tag Manager is working with preview mode and Google Analytics is firing.

Finally, let's go through how to install Google Tag Manager into Wix website.

1. From the Wix dashboard, go to Settings / Tracking & Analytics
2. Go to New Tools. Select the prebuilt Google Tag Manager tool.
3. Get your Google tag manager ID and drop it into the Wix pop up and hit Apply.

Once it’s installed, check that it is working correctly, and you're done!

So there you have it. That was how to install Google Tag Manager correctly into your website

If you want to learn more about Google Tag Manager & growing your business, subscribe to our channel here:    / @web3au