How to Check if a Website Uses Google Tag Manager
Google Tag Manager leaves clear signals: a gtm.js script, a GTM-XXXXXX container ID, the dataLayer array and a noscript iframe. Here is how to detect it.
To check if a website uses Google Tag Manager, view the page source and search for GTM-: every GTM container has an ID in the form GTM-XXXXXX, loaded by a gtm.js script from googletagmanager.com. Finding that ID is close to conclusive. You can confirm it in two more ways — open the DevTools Console and type typeof dataLayer (GTM uses a dataLayer array), or watch the Network tab for the request to googletagmanager.com/gtm.js. This guide covers every signal, the official Google Tag Assistant tool, and the important distinction between GTM (a tag container) and the tags it actually loads.
It is a focused companion to how to find out what analytics a website uses and the broader how to find out what technology a website uses.
What Google Tag Manager is
Google Tag Manager (GTM) is a free tag management system. Rather than hardcoding every tracking snippet — Google Analytics, ad pixels, conversion tags — directly into a site's code, a team installs GTM once and then adds, edits and removes tags through GTM's web interface. The container loads in the browser and fires the configured tags according to rules (on page load, on a click, on a form submit, and so on). The crucial mental model for detection is that GTM is a container, not a tag: detecting GTM tells you a tag manager is orchestrating the site's tracking, and you then look at what it loads to see the actual analytics and marketing tools. GTM is extremely widely deployed, so it is a common find on professional sites.
Signal 1: the gtm.js script and GTM- ID
The primary fingerprint is the loading script and its container ID. GTM is installed with a snippet that loads gtm.js from googletagmanager.com, passing the container ID as a URL parameter — something like googletagmanager.com/gtm.js?id=GTM-ABC123. The GTM- container ID is the definitive marker: no other common tool uses that exact format. So a request to googletagmanager.com/gtm.js in the Network tab, or a GTM- string in the page source, is essentially proof that GTM is present. The specific ID also identifies that particular container, which is useful for distinguishing accounts.
Signal 2: the dataLayer array
GTM passes information to its tags through a JavaScript array called dataLayer. The install snippet initialises it (window.dataLayer = window.dataLayer || []), and the site pushes events and variables into it for GTM to act on. So a quick Console check is a great confirmation: open DevTools (F12), go to the Console, and type typeof dataLayer. If it returns "object", a dataLayer exists, which strongly indicates GTM. You can even type dataLayer and press Enter to see its contents — the events and variables the site is tracking. One nuance: GA4's gtag.js also interacts with a dataLayer, so on rare setups you might see one without a full GTM container; pair this check with the GTM- container ID for certainty.
Signal 3: the noscript iframe
GTM's standard install includes a <noscript> fallback — an <iframe> pointing at googletagmanager.com/ns.html?id=GTM-XXXXXX, placed right after the opening <body> tag. It exists so that some tags can still function for visitors with JavaScript disabled. For detection, it is another place the GTM- ID appears in the raw HTML, and because it sits in a <noscript> block it is present in the server-rendered source even before scripts run. Searching the source for ns.html or GTM- will surface it.
The signal table
| Signal | Where to find it | What it means |
|---|---|---|
googletagmanager.com/gtm.js?id=GTM-... | Network tab, View Source | GTM container loading — definitive |
GTM-XXXXXX container ID | View Source | The specific GTM container — definitive |
dataLayer array (typeof dataLayer) | DevTools Console | GTM data channel — strong signal |
<noscript> iframe to ns.html?id=GTM-... | View Source | GTM no-JavaScript fallback — confirms install |
| Tags firing from within GTM (G-, pixels) | Network tab | What GTM actually loads (GA4, ads, pixels) |
Method 1: View Source (search "GTM-")
The fastest single check is View Source. Open the page, press Ctrl/Cmd + U, and search for GTM-. If you find a GTM-XXXXXX ID — in the gtm.js script URL or the noscript iframe — Google Tag Manager is installed, and you have the container ID. This works because the GTM snippet is placed directly in the HTML head and body, so it is in the server-rendered source. It is the quickest way to both confirm GTM and capture the specific container ID in one go.
Method 2: the DevTools Console and Network tab
For a live confirmation, use DevTools. In the Console, typeof dataLayer returning "object" indicates GTM's data channel is present; inspecting dataLayer shows the events being tracked. In the Network tab, reload and look for the googletagmanager.com/gtm.js request, then watch which other tags fire — you will often see a gtag/js?id=G-XXXX (Google Analytics 4 loading through GTM), a connect.facebook.net call (Meta Pixel), or other pixels, all orchestrated by the container. This is where the container/tag distinction becomes concrete: GTM is the conductor, and the Network tab shows the orchestra it is directing.
Method 3: Google Tag Assistant
For the official, detailed view, use Google Tag Assistant (tagassistant.google.com), Google's own tool for inspecting GTM and the tags it manages. You connect it to the site and it shows the container ID, whether GTM loaded correctly, and a breakdown of the tags firing and the events triggering them. It is more thorough than eyeballing the Network tab, and it is the right tool when you need to verify exactly what a container does rather than simply confirm it exists. For routine detection the source and Console checks are enough; Tag Assistant is the deep-dive option.
GTM versus hardcoded tags
A useful distinction: tracking tags can be hardcoded (the snippet placed directly in the site's code) or managed through GTM (added via the container's interface). Detecting GTM tells you tags are managed centrally — convenient for marketers, since they can change tracking without code deploys. Detecting a hardcoded tag (say, a GA4 gtag.js snippet placed straight in the page, with no GTM container) tells you it was installed directly. Many sites use both: GTM for most tags, plus a hardcoded snippet or two. So when you confirm GTM, do not assume it loads everything — watch the Network tab to separate what GTM fires from what is hardcoded alongside it. This nuance matters for an accurate read of the tracking stack, the same care urged in the analytics detection guide.
What GTM loads: the real tracking stack
Because GTM is a container, the interesting question after "is GTM present?" is "what does it load?". Commonly, GTM fires Google Analytics 4 (a G- measurement ID), Google Ads conversion and remarketing tags, the Meta (Facebook) Pixel, and LinkedIn, TikTok or other pixels — plus assorted marketing and analytics scripts. So a single GTM container can be the gateway to an entire tracking stack. Watching the Network tab as the page loads and as you interact with it reveals these downstream tags firing from within GTM. The breadth of what GTM loads is itself a signal: a container firing GA4 plus several ad pixels and a session-replay tool indicates a sophisticated, multi-channel measurement operation.
A worked example
You want to know how a site manages its tracking. You open View Source and search for GTM- — there it is: googletagmanager.com/gtm.js?id=GTM-ABC123, plus the matching noscript iframe to ns.html?id=GTM-ABC123. GTM is confirmed, container ID captured. You open the Console and type typeof dataLayer, which returns "object"; inspecting it shows page-view and event pushes. Then you watch the Network tab on reload and see GTM fire gtag/js?id=G-XXXX (GA4) and a connect.facebook.net request (Meta Pixel). So the picture is: this site uses Google Tag Manager (container GTM-ABC123) to manage its tracking, currently loading GA4 and the Meta Pixel through it. In a minute you have not just "yes, it uses GTM" but the container ID and the actual tags it orchestrates.
Why detecting GTM matters
Knowing a site runs GTM is informative on several fronts. For competitive research, GTM plus the tags it fires reveals how a rival measures itself and which channels they invest in. For a privacy review, GTM is the hub through which trackers load, so it is the place to understand what data flows where (and whether a consent tool gates it). For performance, GTM and the tags it loads add weight and execution cost, which is relevant to page speed — heavy tag setups are a common cause of sluggishness, as discussed in how to reduce JavaScript and speed up your site. And for technographic qualification, a mature GTM setup signals a data-driven operation. The container is small to detect but opens a window onto how seriously a site approaches measurement.
How accurate is GTM detection?
Very accurate. The GTM- container ID and the gtm.js request are unambiguous and intrinsic to how GTM installs, so confirming the container's presence is reliable. The dataLayer is a strong supporting signal (with the minor caveat that GA4/gtag can also use one, so pair it with the container-ID check). The one thing detection alone does not fully resolve is everything GTM loads at runtime, since tags can fire conditionally on events you have not triggered — Google Tag Assistant or careful Network-tab interaction closes that gap. So "does this site use GTM?" is answerable with confidence; "what is the complete set of tags it can fire?" sometimes needs a little more digging. Confirm the container, then watch what it orchestrates.
The workflow
- View Source and search
GTM-to confirm the container and capture its ID. - Open the Console and run
typeof dataLayeras supporting confirmation. - Check the Network tab for
googletagmanager.com/gtm.jsand the tags GTM fires. - Use Google Tag Assistant for a detailed, official breakdown when needed.
- Separate GTM-managed tags from hardcoded ones for an accurate stack read.
Go deeper
- The wider tracking picture: how to find out what analytics a website uses.
- The whole stack: how to find out what technology a website uses.
- The metadata layer: how to read a website's HTTP response headers.
- The performance cost of tags: how to reduce JavaScript and speed up your site.
Want GTM, the tags it loads and the full stack identified automatically? Analyse any site with StackOptic — free, no sign-up.
Frequently asked questions
How do I check if a website uses Google Tag Manager?
View the page source and search for GTM- — Google Tag Manager containers have an ID in the form GTM-XXXXXX, loaded via a gtm.js script from googletagmanager.com. You can also open the DevTools Console and type typeof dataLayer; if it returns 'object', GTM (or a similar setup) is present. In the Network tab, a request to googletagmanager.com/gtm.js confirms it. Any of these is a strong signal.
What is the GTM container ID?
It is the unique identifier for a Google Tag Manager container, written as GTM- followed by a short alphanumeric code (for example GTM-ABC123). The site loads its container by that ID via the gtm.js script, so the ID appears in the page source and in the script's URL parameter. Finding a GTM- ID is the definitive sign that Google Tag Manager is installed, and the specific ID identifies that particular container.
What is the difference between Google Tag Manager and a hardcoded tag?
A hardcoded tag is a tracking snippet placed directly in the site's code, so changing it means editing the site. Google Tag Manager is a container that loads and manages tags through a web interface instead, so marketers can add or change tags without touching the code. Detecting GTM means tags are managed centrally; detecting a hardcoded tag (like a direct GA4 snippet) means it was placed in the page itself. Many sites use both.
What tools can Google Tag Manager load?
Almost any tag. GTM commonly loads Google Analytics 4, Google Ads conversion and remarketing tags, the Meta (Facebook) Pixel, LinkedIn and TikTok pixels, and various marketing and analytics scripts. So a site running GTM may fire a whole stack of tracking through it. Detecting GTM tells you a tag manager is present; to see what it loads, watch the Network tab as the page runs and note the tags that fire from within it.
Is the dataLayer always a sign of Google Tag Manager?
Usually, but not always. The dataLayer is the array GTM uses to pass information to tags, so its presence strongly suggests GTM. However, Google Analytics 4 and gtag.js also interact with a dataLayer, so on rare setups you might see it without a full GTM container. The reliable confirmation is the GTM- container ID and the gtm.js request; the dataLayer is a strong supporting signal that is best paired with the container-ID check.
Analyse any website with StackOptic
Get the full technology stack, performance, security and SEO report in seconds — free.
Analyse a websiteRelated articles
How to Tell if a Website Uses Progressive Web App (PWA) Features
A web app manifest, a registered service worker, installability and a theme-color tag are the PWA signals. Here is how to detect them in Chrome DevTools.
How to Tell if a Website Uses Akamai, Fastly, or CloudFront
Each major CDN leaves distinct header fingerprints — Fastly's x-served-by, Akamai's ghost markers, CloudFront's x-amz-cf-pop. Here is how to tell them apart.
How to Tell if a Website Uses Google reCAPTCHA
Google reCAPTCHA leaves signals: a recaptcha/api.js script, a grecaptcha global and a g-recaptcha data-sitekey. Here is how to detect it and tell v2 from v3.