Guide to Google Tag Manager: From a Google Tag Manager Consultant
If you are an SME business owner or marketing manager, you have likely experienced the headache of fragmented tracking. You add a Google Analytics snippet to your site template, then a marketing agency requests a Meta pixel for a specific page, and soon after, you need a Google Ads conversion tag. Before long, it becomes incredibly difficult to manage, and it is entirely too easy to lose track of where tags have been installed.
Throughout my years working on data tracking for multiple clients through agency life, I've seen just how crucial it can be to give yourself a bit of a Google Tag Manager audit every now and again.
If your data feels unreliable or disorganised and you want to ensure data accuracy, then Google Tag Manager (GTM) is the solution. GTM acts as a centralised bridge between your website and third-party platforms. Instead of hardcoding individual tracking snippets across various pages, you place one master code on your website and manage all subsequent tracking directly through GTM.
This comprehensive guide will walk you step-by-step through setting up GTM, implementing standard analytics, deploying advertising pixels, and tracking critical conversions.
1. Understanding the Core Framework
Before we build, we must define the tools. GTM relies on four primary components:
The Container
This stores all of the tracking elements for your website. When you "install GTM", you are actually placing the container code onto your site.
Tags
These are typically snippets of JavaScript code that collect data and send it to a specific platform (e.g., Google Analytics, Meta, or an A/B testing tool like Crazy Egg).
Triggers
These dictate the rules. Triggers control exactly when a tag should or should not fire. For example, you might use an "initialisation - all pages" trigger for standard analytics, or a custom trigger that only fires on a specific "Thank You" page.
Variables
These act as placeholders for dynamic information. You can use built-in or custom variables to capture details, such as the specific link a user clicked or your overarching Google Analytics measurement ID.
2. Creating Your Account and Installing GTM
To begin, navigate to tagmanager.google.com and click Create Account. Name your account, select your country, and name your container (ideally, identifying the website it will be installed on). Select Web as your platform and click create.
You will be presented with two pieces of code. The first is the critical JavaScript container code, which belongs high up within the <head> tag of every page on your site. The second is a <noscript> fallback for users with JavaScript disabled, though omitting this will not severely impact your core data collection.
Installing on WordPress For WordPress users, implementation is straightforward:
Navigate to your WordPress dashboard and install the GTM for WordPress plugin, which is highly recommended as it enables future e-commerce transaction tracking.
Activate the plugin and go to its settings.
Paste your Container ID (found at the top of your GTM workspace, beginning with "GTM-").
Ensure the "Container code" option is toggled to ON, and save your changes. Check twice to ensure the ID has saved correctly.
(Note: If you use Shopify or Squarespace, official support documentation provides specific implementation routes for those platforms).
3. Deploying Your Analytics Foundation (GA4)
With the container installed, we will now implement your first tag: Google Analytics 4 (GA4).
In GTM, click New Tag and name it logically, such as "Google tag - GA4 Page View".
Under Tag Configuration, select Google tag.
You will need your GA4 Measurement ID (found in the Admin > Data Streams section of Google Analytics).
Pro-Tip: Instead of pasting the ID directly, click the variable icon next to the Tag ID field, then the + sign to create a new variable. Name it "GA4 Measurement ID", set the variable type to Constant, and paste your ID here. Saving this as a constant variable allows you to reuse it across multiple tags seamlessly.
Under Triggering, select the default Initialization - All pages trigger. This ensures your analytics tag fires early on every pageview, prior to other tags.
Click Save.
Critical Step: If you are migrating to GTM, ensure you remove any hardcoded Google Analytics snippets from your site when you publish your GTM container. Running both simultaneously will result in duplicated, inaccurate data.
4. Supercharging Advertising Tags
To capture ROI from your paid campaigns, you need marketing pixels. Here is how to configure the essentials using the exact same "Initialization - All pages" trigger:
Google Ads Remarketing: Create a new tag, select Google Ads Remarketing, and paste the Conversion ID found in the Audience Manager of your Google Ads account.
Google Ads Conversion Linker: Always add this tag alongside your Ads setup. Select Conversion Linker in tag configuration. This crucial tag improves tracking accuracy by storing ad-click information via first-party cookies in the user's browser.
LinkedIn Insight Tag: Create a tag, search for LinkedIn Insight, and simply paste your Partner ID.
Meta Pixel: Meta requires a different approach. Create a tag and select Custom HTML. Paste the base code provided by your Meta Events Manager. Critically, under Advanced Settings, change the tag firing option from "Once per event" to Once per page to prevent duplicate reporting.
5. Tracking Critical Conversions
Knowing who visited is good; knowing what they did is business-critical. Let us configure a tag that fires exclusively when a user completes a lead form and lands on a "Thank You" page.
Step A: Configure the Trigger
Navigate to Triggers and create a new one named "Thank You Page".
Choose Page View - Window Loaded or Some Initialization Events.
Set the condition to Page Path > contains > /thank-you (or whatever your specific URL slug is). Save the trigger.
Step B: Pass the Conversion to Ads and Analytics
For Google Ads: Create a new Google Ads Conversion Tracking tag. Input the Conversion ID and Conversion Label generated when you set up the conversion action in your Google Ads dashboard. Apply your newly created "Thank You Page" trigger.
For GA4: Create a GA4 Event tag. Select your GA4 Measurement ID variable. Name the event logically, using Google's recommended naming conventions, such as generate_lead. Apply the "Thank You Page" trigger.
Step C: Tracking Dynamic Actions (Button Clicks)
If you want to track when a user interacts with a specific element, such as a drop-down quantity selector, you can use built-in variables.
Go to Variables > Configure, and enable the Click ID variable.
Create a trigger set to Click - All Elements > Some Clicks, and set the rule to trigger when the Click ID equals 'quantity' (or whatever HTML ID is attached to your button).
Create a GA4 Event tag named select_item, and under Event Parameters, map the parameter to your {{Click ID}} variable. Assign your new click trigger to this tag.
Moving Forward
Once your configuration is complete, you must publish the changes to push them live by clicking the Submit button in your workspace.
By centralising your data collection through Google Tag Manager, you transition your website tracking from a brittle, developer-dependent chore into a robust, marketer-controlled system. You now have the foundation to track visitors, attribute campaign success, and reliably measure the conversions that drive your SME forward.
If you feel slightly overwhelmed, don't panic. It can be a lot to get your head around but once you've played around, you'll be surprised how much you pick up and how quickly.
If you're looking for an extra set of eyes and some google tag manager services then feel free to get in touch with us at Align & Scale and we can look into your tracking needs.

