When the GA4 tag disappears
When the GA4 measurement ID or gtag snippet vanishes from the live HTML, reports go quiet. Traffic may still be there. The tag is not.
What it means
A direct install puts a G-XXXXXXXX snippet in the page. A lot of sites load GA4 through Google Tag Manager instead, with only a GTM-XXXX container in the HTML.
Either path can break after a theme swap, a consent banner change, a "performance" plugin that strips scripts, or a deploy that drops the tag include.
Then SEO and analytics spend days arguing past each other.
How to confirm
- View source (or the scraped HTML Google sees, not just the rendered DOM) and search for
G-andGTM-. - In Chrome DevTools Network, filter for
collect/gtag/gtmon a fresh load with ad blockers off. - Hit a page yourself and watch GA4 realtime. No hit usually means the tag never fired.
curl -s https://example.com/ | grep -E 'G-[A-Z0-9]+|GTM-[A-Z0-9]+'
How to fix
- Put the approved snippet or GTM container back in the global layout, not one landing template. Google's GA4 collection docs cover the direct gtag install.
- If you use a tag manager, confirm the GA4 config tag is published and fires on All Pages (or your real trigger). See the Tag Manager docs if the container itself is missing.
- Check consent mode and blockers. A tag can sit in the HTML and still fail to send hits.
- Verify on production. Localhost and staging often use different container IDs.
How it comes back
Redesigns, A/B tools that rewrite head, CMS "custom code" fields wiped on sync, agency handoffs that leave GTM in draft. Put measurement on the release checklist next to titles and robots, not as a glance at the dashboard next quarter.
We built Jerilo to catch breaks like this early.