Setting up and configuring a web GTM container
The web container is where your tags live: one snippet on the site, and every pixel, event and tweak after that is a container change instead of a code change. This guide creates one from scratch and wires it to the GA4 property from the previous step, including the one setting that routes its events through your server container.
Create the account and container
In Google Tag Manager, click Create account: the account is your company, the container is the site. Choose Web as the target platform. You get a container ID (GTM-XXXXXXX); this is the ID your site's loader references, and the ID your server container will later whitelist.
Find your way around
Three building blocks do all the work: tags (the things that fire: a Google tag, a conversion pixel), triggers (when they fire: a page view, a click, a form submit) and variables (the values they read: page URL, click text, a dataLayer field). Everything happens in a workspace and nothing is live until you publish a version, so you can experiment freely.
Install the loader, the Measurebase way
GTM's install screen offers Google's default snippet, loading gtm.js from googletagmanager.com. It works, but it's exactly the third-party pattern ad blockers and Safari clamp down on. On Measurebase you install a first-party loader instead: open your domain in the dashboard, click Generate script, enter this container ID and choose the Standard or Enhanced loader. The generated pair of snippets replaces Google's: same container, same tags, but loaded from your own tagging subdomain. The complete setup guide covers the install step by step, including removing an old snippet so nothing double-fires.
Add the Google tag
Create your first tag: Tags → New → Google tag, paste the Measurement ID (G-XXXXXXX) from your GA4 property, and set it to fire on Initialization – All Pages. That single tag is what sends page views and enhanced-measurement events to GA4.
Route events through your server container
Still in the Google tag, open Configuration settings and add server_container_url, set to your tagging subdomain: https://mbase.yoursite.com. This is the switch that makes the whole server-side setup real: instead of posting straight to Google, the tag sends events to your own subdomain, where your server container receives, processes and forwards them.
Preview, then publish
The Preview button opens Tag Assistant connected to your site: every tag that fires (or doesn't) is listed per event, before anything goes live. One Measurebase note: preview behaves exactly like a stock install on the Standard loader; if you run the Enhanced loader and want debugging to behave identically to stock GTM, the setup guide explains the trade-off. When it looks right, Submit → Publish creates a version; that's the moment changes reach real visitors, and the version history is your undo button.
One word on consent
If your site needs a consent banner, its CMP should set Consent Mode defaults before the container loads and update them on the visitor's choice; tags in the container then respect that state automatically. Set that up once, early: retrofitting consent behavior after dozens of tags exist is far more work.
Next in the series: the server GTM container that receives what this one now sends.