On this page
What this issue is
Every GA4 web data stream has a measurement ID that starts with G-. The tag on your pages uses that ID to decide which GA4 property receives the hits. If the ID in your code is not the one from your production stream, the data goes somewhere else.
It usually happens in three ways: a staging site was cloned to production with its own ID still in place, an agency reused a template from another client, or someone pasted an ID from the wrong property while setting up a tag in Google Tag Manager (GTM) or a plugin.
- Visitor landsPage loads normally
- GA4 tag firesUses G-STAGING123
- Wrong propertyStaging or other client
- Your reportsEmpty or very low
The page works and the tag fires, so nothing looks broken on the site. The data simply goes to the wrong place.
Why it costs you leads or sales
Your production GA4 property shows little or no traffic and no conversions. Ad platforms that import GA4 conversions get nothing to optimise on. Reports you send to clients or your boss are wrong, and you may not notice for weeks because the site itself works fine.
If the ID belongs to another client, you also pollute their data with your visitors. That is a privacy and trust problem as well as a reporting one.
Example: the site gets 1,000 real visits a day, but the production property only sees the few that still use the right ID.
How to check if your site has it
Get the correct ID
In GA4 open Admin > Data streams, choose your web stream and copy the Measurement ID at the top right.
Find the ID your pages send
Open your live site, press F12, go to the Network tab, filter by
collectand reload. Click a request togoogle-analytics.com/g/collectand read thetidparameter. That is the ID in use.Or search the source
View page source and search for
G-. Check every match, since a page can contain more than one.Check GTM if you use itGoogle Tag Manager
In Tag Manager open your Google tag or GA4 Configuration tag and read the Tag ID field. Also check any variable it references.
Test key pages
Repeat on the home page, a landing page, the form page and the thank-you page. Templates and builders sometimes hold different IDs.
How to fix it
Replace the wrong ID everywhere it lives. The place depends on how GA4 was installed.
Find the plugin or theme setting
Check your analytics plugin (for example Site Kit or a GA plugin) and your theme's header scripts settings. Replace the ID in each place.
Search for leftovers
Search theme files and any header/footer injection plugin for the old
G-ID and remove it.Clear caches
Purge page, plugin and CDN caches so the new ID is served.
Check the Google & YouTube channel
In Admin open Sales channels > Google & YouTube and check the connected GA4 property. Under Settings > Customer events, check any custom pixels.
Check theme code
In Online Store > Themes > Edit code, search theme.liquid for
G-and fix any hard-coded ID.
Edit the Google tag
Open the tag, change the Tag ID to the correct G- ID. If it uses a constant variable, edit the variable once instead.
Check the container
Make sure you published the container that is installed on the live site, not a copy from another workspace or client.
Preview, then publish
Use Preview to confirm the new ID, then Submit and Publish.
Update project settings
Go to Site settings > Integrations > Google Analytics and enter the correct ID, or check Custom code in Site settings if you paste the script manually.
Publish
Publish to all domains, including the custom domain.
Check funnel and site tracking
In each funnel or website, open Settings > Tracking Code (header) and look for the old ID. Also check the sub-account's Settings > Business Profile integrations if used.
Save and republish
Save each funnel and check every step, as the code can differ per step.
Open Marketing integrations
In the dashboard go to Marketing & SEO > Marketing Integrations > Google Analytics and correct the ID.
Check custom code
Open Settings > Custom Code and remove any pasted gtag snippet with the old ID.
Update the setting
Go to Settings > Developer Tools > External API Keys (or the Analytics area, depending on your version) and fix the measurement ID.
Check code injection
Open Settings > Advanced > Code Injection and remove old snippets.
Replace the ID in the snippet
Update both the script URL and the config call. Use an environment variable so staging and production cannot share a value.
<script async src="https://www.googletagmanager.com/gtag/js?id=G-XXXXXXXXXX"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'G-XXXXXXXXXX');
</script>Wrong ID
- Page sends tid=G-STAGING123
- Production property shows almost no traffic
- Conversions imported to ads are empty
Correct ID
- Page sends your production G- ID
- Sessions and events appear in your property
- Conversions available for reports and ads
How to confirm it's fixed
- Network tab shows
collectrequests withtidequal to your production ID on every key page - No other G- ID appears in page source unless you deliberately use two
- GA4 Realtime in the correct property shows your test visit (turn off internal filters or use another device)
- Admin > Data streams shows the stream receiving data
- The old staging or client property no longer receives your hits
- A test form submit or purchase event appears in Realtime
How to prevent it happening again
- Keep a list of site, domain, property and measurement ID in one place
- Use separate IDs per environment through config or GTM environments
- After cloning a site or template, replace the ID before launch
- Never reuse a client's container or theme without auditing the IDs
- Add the ID check to your launch checklist
- Monitor the live ID on a schedule so a change is caught fast
How FunnelGuard handles this
FunnelGuard detects this issue. A robot visitor loads your funnel pages on a schedule, and its discovery step pins the tag IDs it finds, including the GA4 measurement ID. If the ID changes or does not match what was pinned, the check fails.
A failure is re-checked from a second region before one alert goes out, with a screenshot and a likely cause. Test traffic is marked (utm_source=funnelguard, fg_test=1) so you can filter it. The Free plan covers 1 site and 2 journeys with daily checks, no card needed, and paid plans have a 3-day free trial.
| Location | What to look for |
|---|---|
| Page source | gtag.js URL and config call |
| GTM tag | Tag ID field or constant variable |
| Plugin or app | Connected property or ID field |
| Theme or builder custom code | Pasted old snippets |
Day 0
Staging site is cloned to production with its G- ID.
Week 1
Site works, ads run, nobody opens GA4.
Week 3
Monthly report shows near-zero traffic.
Week 3
ID replaced and verified in Realtime.
Questions people ask
Why is my GA4 not showing any data?
One common cause is that your site uses a different measurement ID than your production data stream. Compare the tid value in the collect requests in your browser's Network tab with the ID in Admin > Data streams. Other causes include a missing tag or an internal traffic filter.
How do I find my GA4 measurement ID?
In GA4 go to Admin > Data streams, click your web stream and copy the Measurement ID at the top right. It starts with G-. It is different from your property ID, which is just numbers.
How do I check which GA4 ID a website is using?
Open the site, press F12, go to the Network tab, filter by collect and reload. Click a request to google-analytics.com and read the tid parameter. You can also view the page source and search for G-.
Can my data be going to another client's GA4 property?
Yes. If you reused a template, container or snippet from another client and kept their G- ID, your visitors are counted in their property. Replace the ID and tell them so they can clean their reports.
Will changing the measurement ID bring back my old data?
No. GA4 does not move data between properties. The fix applies from the moment the new ID goes live, and past hits stay in the property that received them.
Is the measurement ID the same as the property ID?
No. The measurement ID (G-XXXXXXXXXX) belongs to a data stream and is used in tags. The property ID is a numeric ID used in the admin and API. Using the wrong one in a tag will not collect data.
Why does staging data appear in my production GA4?
Usually the staging site shares the production ID, or a clone kept it. Give staging its own property or block tracking there, and make sure live pages use the production ID.
Related issues
- TRK-001GA4 tag missing from a funnel pageFix guide
- TRK-005Two GA4 measurement IDs sending to the same propertyFix guide
- TRK-006GA4 installed twice (gtag.js and GTM) causing double page_viewsFix guide
- TRK-014GA4 data stream web URL pointing to an old domainFix guide
- TRK-018GA4 data stream deleted or property in trashFix guide
- TRK-022Test traffic not marked internal (pollutes reports)Fix guide