Updated
Google Tag Manager Setup That Controls All Your Tracking Tags in One Place
We build and clean up GTM containers so GA4, Google Ads, Meta, TikTok and LinkedIn tags run from one documented, versioned place, with consent handled first and values from a proper data layer.
- web-container
- server-container
- consent-mode-v2
- data-layer
- tag-assistant-qa

What Is Included in a Google Tag Manager Setup?
A Google Tag Manager setup means creating a GTM container, installing it on every page, and building the tags, triggers, variables, data layer and consent rules that send clean data to each ad platform. Done well, marketing can change tracking without a developer, and anyone can read the container a year later.
What’s the difference between the Google tag and Google Tag Manager?
The Google tag (gtag.js) is one piece of code that sends data to Google products such as GA4 and Google Ads. Google Tag Manager is a container that manages the Google tag and every other tag on your site, including Meta, TikTok and LinkedIn, with triggers, versions and permissions. Most sites want the Google tag inside GTM.
The Google tag vs Google Tag Manager choice, with server-side GTM as a third option:
| Question | Google tag in site code | Google tag inside GTM | Server-side GTM added |
|---|---|---|---|
| Meta, TikTok, LinkedIn tags | Each pasted into code separately | Added from templates in one place | Also forwarded from your server |
| Change without a developer | No | Yes | Yes, once the server is running |
| Version history and rollback | Only through your code repository | Every publish is a version you can restore | Separate versions for the server container |
| Consent Mode v2 | Coded by hand | Consent platform template plus built-in consent checks | Reads the consent state sent from the browser |
| Ad blockers and browser limits | Exposed | Exposed | More resilient on a first-party subdomain |
| Best for | A small site running GA4 only | Almost every business running ads | Brands on two or more ad platforms |
Per Google’s Tag Manager documentation as of November 2026.
GTM Container Setup: Tags, Triggers and Variables
How does Google Tag Manager work?
GTM listens for events on your site, such as a page load, a click or a data layer push. Each event is checked against your triggers. When a trigger matches, its tags fire and read their values from variables. Nothing fires that a trigger does not allow, so the trigger list is the real rulebook.
That is the core of any GTM container setup. Read each row as a sentence, and keep IDs in variables: a GA4 ID typed into 30 tags means 30 edits.
- Tag
Google Tag - SiteTriggerInit - All PagesVariablesConst - GA4 ID - Tag
CMP - Consent BannerTriggerConsent Init - All PagesVariablesDefault states by region - Tag
GA4 - Event - purchaseTriggerCE - purchaseVariablesDLV - ecommerce.value, DLV - transaction_id - Tag
GAds - Conv - LeadTriggerCE - generate_leadVariablesUPD - Enhanced Conv (hashed email) - Tag
Meta - Event - PurchaseTriggerCE - purchaseVariablesDLV - ecommerce.value, DLV - event_id

GTM Data Layer Design for Ecommerce and Lead Events
Why does GTM need a data layer?
A data layer is a JavaScript object your site fills with facts, such as order value, currency, product IDs or form name, at the moment something happens. GTM reads those facts instead of scraping text off the page, so a redesign or a renamed button does not quietly break purchase tracking.
// Clear the previous ecommerce object first window.dataLayer = window.dataLayer || []; dataLayer.push({ ecommerce: null }); dataLayer.push({ event: "purchase", event_id: "ord_10482", ecommerce: { transaction_id: "10482", value: 148.00, currency: "GBP", items: [{ item_id: "SKU-221", price: 74.00, quantity: 2 }] } });
The spec we hand your developer
- One push per real event, with Google’s recommended names:
add_to_cart,purchase,generate_lead. - Numbers as numbers.
148.00, never"£148.00". - A
transaction_idon every order, plus anevent_idthe server copy of the event can reuse for deduplication. ecommerce: nullbefore each ecommerce push, as Google’s developer documentation recommends.- Pushes only after success: the confirmed order, the validated form.
Which events GA4 should report is a separate decision, covered on our Google Analytics 4 setup and key events page.
Consent Mode v2 and Server-Side Google Tag Manager
How do you set up Consent Mode v2 in GTM?
Install your consent platform’s template from the Community Template Gallery, fire it on the Consent Initialization trigger, and set default states for ad_storage, analytics_storage, ad_user_data and ad_personalization by region. Google tags then adjust themselves; other tags get additional consent checks so they wait for permission.
- Templates exist for Google-certified platforms such as Cookiebot, OneTrust and Usercentrics.
- Advanced mode lets Google tags send cookieless pings when consent is denied, which feeds conversion modelling; basic mode blocks them until consent.
Do I need server-side GTM?
If you advertise on two or more platforms and rely on purchase or lead data, usually yes. Server-side Google Tag Manager puts a container on your own subdomain that receives events from the web container and forwards them to GA4, Google Ads, Meta and others, so you decide exactly what each platform gets.
- Hosted on Google Cloud Run or a managed host, on a subdomain such as data.yourbrand.com.
- Server tags reuse the data layer
event_idso browser and server copies deduplicate. Our Meta Pixel and Conversions API setup page covers that side in depth.
Reference: Google’s server-side tagging documentation.
GTM Naming Conventions, Workspaces and Publishing Rules
A container is only as useful as it is readable, so the naming convention is agreed before anything is built.
- Tags
- Platform – Type – Detail
GA4 - Event - purchaseMeta - Event - Lead - Triggers
- Type – Detail
CE - purchaseClick - Header PhoneInit - All Pages - Variables
- Type – Name
DLV - ecommerce.valueConst - GA4 IDURL - Path - Folders
- One per platform, numbered
01 Consent02 Google03 Meta09 Utilities - Versions
- Date and change; why and how tested in the notes
2026-11-04 Meta purchase via server
Workspaces and versions
Free GTM gives each container three workspaces. One job per workspace keeps half-finished changes out of live. Every publish is a version, so a bad change is undone by republishing the last good one.
Who should get publish rights?
Very few people, because Publish is the permission that matters. GTM has four container permissions: Read, Edit, Approve and Publish. We give most of your team Read or Edit, one or two owners Publish, and keep account Administrator with your business, never with an agency alone.
- ReadAnalysts and stakeholders
- EditMarketers and agencies
- ApproveA senior reviewer
- PublishOne or two owners
Preview and Tag Assistant QA Before Anything Goes Live
How do you test GTM tags before publishing?
Open Preview in GTM, which connects Tag Assistant to your site, then do the real actions: view a product, add to basket, place a test order, submit a form. For each event, Tag Assistant shows which tags fired, which did not, and what every variable held at that moment.

- OnceOne fire per event, not again on refresh.
- ValuesA number, the right currency, an order ID.
- ConsentAccept and decline both behave as promised.
- TimingNothing fires before the banner answers.
- PlatformsMatched in GA4 DebugView and Meta Test Events.
Google Tag Manager Audit and Container Clean-Up
Inherited a container? A Google Tag Manager audit starts with an export, then we clean up in a separate workspace while live keeps running.

Copy of GA4 purchase (2)
Duplicates that count one order twice.UA - Pageview
Universal Analytics tags left behind; standard UA properties stopped processing data in July 2023.FB pixel OLD
Custom HTML where a template now exists.All Pageson a conversion tag
A lead recorded on every page view.AW-123456789typed into 20 tags
Hardcoded IDs instead of one Constant variable.- Ex-staff with Publish
Old employees and agencies who can still go live.
If the container is fine but the campaigns are not, our Google Ads account audit is the better first step.
How We Set Up Your GTM Container, Step by Step
How long does a GTM setup take?
A standard web container with the core tracking tags typically takes under a week. Adding a server-side container, a data layer that needs developer time, or untangling a large existing container takes longer, and we give you a dated plan after the audit.
Audit or fresh start
Admin › Export ContainerExport and list everything, or create a clean container owned by your company.
Measurement plan and naming
FoldersEvents, platforms, naming card and folders, agreed before any tag is built.
Data layer spec
Variables › Data Layer VariableWe write the spec, your developer (or ours) adds it, and each field becomes a variable.
Consent first
Admin › Container SettingsConsent template on Consent Initialization, defaults by region, Consent Overview on.
Build in a named workspace
Workspaces › NewGoogle tag, GA4, Google Ads with enhanced conversions, Meta, TikTok and LinkedIn, then the server container if warranted.
Preview and QA
Preview › Tag AssistantEvery event tested on real pages, consent accepted and declined, desktop and mobile.
Publish, permissions and handover
Submit › Publish and Create Version · Admin › User ManagementA version with a real description, access reviewed, and the container map handed over. You keep full ownership.
Tracking First, Then Scale: What the Shot Vet Case Shows
EmergingAds is a performance marketing agency founded in 2021 and based in Gurugram, India, working with brands in the US, UK, UAE, India and Australia. We have served 85+ brands.
Shot Vet: fixed tracking first
Shot Vet · Veterinary · USA · Meta + Google Ads
FoundMeta ads running on broken conversion tracking, so scaling decisions rested on incomplete data.
Fixed firstThe data foundation came first: leads counted correctly and checked against real enquiries. Then the Meta campaigns were rebuilt and Google Ads added.
Result, as on the case pageHow we approach your container
- Read-only access in week one. No edits until you see the audit.
- A clean Google Tag Manager setup before campaign changes, because bidding learns from what the tags send.
- Results judged against your real orders or CRM.
The Shot Vet case page describes the tracking repair, not the tools used, so we claim no more than it says.
Related Tracking and Google Ads Services
GTM is the delivery layer for these services and for the Google Ads management service that depends on them.
Google Tag Manager Questions, Answered
What is Google Tag Manager used for?
It manages marketing and analytics tags, such as GA4, Google Ads and Meta, from one interface instead of site code. It is free, and every change is versioned.
Do we need Tag Manager if our developer already added tracking tags?
Not strictly, but you will want it. Hardcoded tags work, yet every future change needs a developer again. GTM lets marketing change tags without a code release.
How long does it take to set up Google Tag Manager properly?
Usually under a week for a standard web container with the core tags. Server-side, new data layer work or a large clean-up adds time.
Is server-side GTM worth it for a small business?
Often not at first. On one platform with modest traffic, a clean web container with enhanced conversions is the better start. On two or more platforms, server-side is usually worth the extra setup.
Can you clean up our existing messy container?
Yes, it is one of our most common requests. We export it, remove dead and duplicate tags, apply a naming convention and move repeated values into variables, all in a separate workspace.
Will changes in GTM slow down or break our website?
Not when they are tested. Every change goes through Preview first, and any bad version can be rolled back in minutes.
Who owns the GTM container after you finish?
You do. Your business holds the account Administrator role, we work with the access you grant, and you keep the container map and naming card.
Does Google Tag Manager work on Shopify and WordPress?
Yes, with one Shopify caveat. On WordPress GTM goes in the theme or a plugin. Shopify checkout pages no longer accept theme code, so purchase events come through Shopify’s Customer Events instead.
Do I need Consent Mode v2 if I only sell in the US or India?
Google does not require it there, but we still recommend it. Google requires the signals for users in the European Economic Area, and US state laws and India’s data protection law point the same way.
How is this different from conversion tracking setup?
GTM is the tool that deploys and organises tags; conversion tracking setup decides what counts as a conversion and how each platform receives it. We usually do both together because one depends on the other.
Set Up Google Tag Manager as the Single Control Point for Your Tracking
Give us read access. We check tags, triggers, consent and data layer, and tell you what to fix first.
Free GTM and tracking audit
A written list of broken, duplicate and missing tags, in priority order.
