Google Tag Manager detector

Google Tag Manager logo

How can you check if a website has Google Tag Manager installed by looking at the source code?

Detecting Google Tag Manager (GTM) on a website involves identifying specific markers characteristic of GTM in the website’s source code.

Here’s a step-by-step guide on how to do it:

  1. Open the Page Source: Right-click on the webpage and select “View Page Source” or press Ctrl+U (Windows) or Cmd+Option+U (Mac) to open the page’s source code.
  2. Search for GTM-Specific Scripts: Use Ctrl+F (Windows) or Cmd+F (Mac) to open the search function and look for the following keywords: <script src="https://www.googletagmanager.com/gtm.js?id=GTM-XXXXXXX"></script>.
  3. Search for the dataLayer variable: GTM uses a JavaScript array called dataLayer to pass information: <script> window.dataLayer = window.dataLayer || []; </script>