Basic principle: container, tags, triggers, and variables
GTM is a tag management system: a layer installed once in the site's code, the container, that then lets you add, edit, or remove tracking tags without touching that code again. Before GTM, every new marketing tool, a Meta Pixel, a Google Ads conversion, a third-party vendor's script, meant asking a developer to insert one more line in the page's
. With GTM, that job moves into an interface someone on the marketing team can run, usually without writing any code, sometimes writing a few lines only inside a single tag.This needs to be said up front, because it's the most common mix-up: GTM is not an analytics tool. It doesn't collect its own data, doesn't count sessions or users, and has no traffic report of any kind. It's common for someone to open GTM looking for visit numbers or a conversion chart and find nothing like that, because that data simply doesn't live there. GTM only fires the GA4 tag, or whichever tag applies; GA4 is the one that collects, processes, and displays those numbers in its own reports. Confusing the two means looking in the wrong place, and worse, assuming that if a tag "is in GTM" the data is already analyzed, when it's only been sent.
Every setup is built from four pieces. The container is the package that holds a site's or app's entire configuration, installed through a couple of code snippets in the HTML. Tags are the scripts or snippets that actually fire: a GA4 configuration tag, a Google Ads conversion, a Meta Pixel event, or a custom HTML tag. Triggers are the conditions that decide when each tag fires: on any page load, on a click on a specific button, on a form submission, past a scroll-depth threshold, or on a custom event pushed into the dataLayer. And variables are the dynamic values tags and triggers rely on to work: the page URL, the text of a click, a value pulled from the dataLayer, a cookie, or a URL parameter.
