On this page
What this issue is
A self-referral is a visit where GA4 reports your own site as the traffic source. It shows up in Reports > Acquisition > Traffic acquisition as a referral from something like shop.example.com or book.example.com.
GA4 normally handles subdomains of one site well. Its cookie is set on the main domain (.example.com), so the same visitor keeps one client ID across www, shop and book. Self-referrals appear when something breaks that: a different measurement ID on a subdomain, a cookie that is only set on one host, a tag that loads late or not at all on the landing page, or a hosted tool on another domain that is not in your cross-domain setup.
Why it costs you leads or sales
Your marketing decisions depend on knowing which channel produced a lead or sale. When a self-referral takes over, the conversion is credited to your own domain, and Google Ads, Meta, email or organic search get no credit. Campaigns look worse than they are, and budget moves to the wrong places.
- Ad clickVisitor lands on www.example.com with gclid
- Click to shop.example.comDifferent cookie or ID on the subdomain
- New sessionSource shows as www.example.com / referral
- PurchaseRevenue credited to referral, not the ad
One visit becomes two sessions, and the second one blames your own site.
Example: a shop sends 100 purchases. Before the fix, 40 are credited to a self-referral. After the fix, they return to their real channels.
How to check if your site has it
Open the traffic acquisition report
Go to Reports > Acquisition > Traffic acquisition. Change the first column to Session source / medium.
Look for your own hostnames
Search for your domain. Any row such as www.example.com / referral or shop.example.com / referral is a self-referral.
Check the landing pages
Add Landing page as a secondary dimension. Self-referral sessions that land on checkout, booking or thank-you pages point to the subdomain that lost the source.
Compare client IDs by walking the journey
In a browser, open your site, open DevTools > Application > Cookies and read the _ga cookie. Move to each subdomain and check the cookie value and its Domain column. It should be the same value and set on .example.com.
Check the measurement ID on each host
In DevTools > Network, filter for collect and read the tid parameter on every subdomain. All should match the same G- ID.
How to fix it
Use one measurement ID on every subdomain
Every host (www, shop, book, blog) should send to the same GA4 data stream. Remove any second property you set up for a subdomain unless you truly need it.
Make sure the tag loads on the first page of each subdomain
The GA4 tag must load on the landing page of every subdomain, not only after a click, so the existing cookie is read before any event is sent.
Add your domain to unwanted referrals
In GA4 go to Admin > Data streams > your web stream > Configure tag settings > Show all > List unwanted referrals. Add a rule with Referral domain contains and your root domain (example.com). This stops GA4 treating your own hosts as a new source.
Set up cross-domain measurement for separate domains
If the booking or checkout runs on a different domain (not a subdomain), go to Admin > Data streams > your stream > Configure tag settings > Configure your domains and add every domain.
Check session timeout and test again
Open Configure tag settings > Adjust session timeout if you changed it. Then repeat the walk-through from the checking section.
Use one container on all subdomains
Install the same GTM container on every host, with one GA4 configuration tag using the same measurement ID.
Set the cookie domain if needed
In the GA4 configuration tag, open Fields to Set and add cookie_domain with the value auto, or your root domain such as example.com.
Fire on Initialization
Set the GA4 configuration tag trigger to Initialization - All Pages so it runs before event tags.
Add cookie_domain to the config call
Use the same gtag config on every subdomain and set cookie_domain to auto or your root domain.
Check each site's analytics plugin
If a subdomain runs its own WordPress install, check that its plugin (such as Site Kit or a GA4 plugin) uses the same measurement ID as the main site.
Match the shop domain with the main site
If your shop runs on shop.example.com, add the same GA4 ID in Settings > Customer events or your GA4 app, and list your domains in the GA4 stream settings.
Add the tracking ID to funnels and sites
Put the same GA4 measurement ID in the funnel or website tracking settings for each custom domain or subdomain you use.
<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', {
cookie_domain: 'auto'
});
</script>Broken
- Subdomain uses a different ID or cookie
- Your own domain appears as a referral
- One visit counts as two sessions
- Ad source lost before the purchase
Fixed
- One ID and cookie across subdomains
- Own domain excluded as a referral
- One visit stays one session
- Purchase credited to the real channel
How to confirm it's fixed
Start from a tagged link
Open your landing page with a test UTM, such as ?utm_source=test&utm_medium=cpc&utm_campaign=selfref, in a clean browser window.
Move to the subdomain
Click through to the shop, booking or checkout page.
Watch it in Realtime or DebugView
In GA4 open Admin > DebugView (use the Tag Assistant or GTM preview to turn debug on). Check that both pages share one session and the source stays as test / cpc.
Recheck the report after 24-48 hours
Return to Traffic acquisition and confirm self-referral rows have stopped growing.
How to prevent it happening again
- Keep a list of every subdomain and tool domain your funnel touches
- Use one GA4 measurement ID everywhere
- Keep your root domain in the unwanted referrals list
- Add new domains to the cross-domain list before launch
- Test the full journey with a UTM link after theme, GTM or hosting changes
- Review Session source / medium for your own hostnames each month
How FunnelGuard handles this
FunnelGuard does not check for self-referrals yet. It is a possible future check, and today it will not tell you that your subdomains are splitting sessions.
What FunnelGuard does cover nearby: a robot visitor runs your real customer journeys on a schedule and checks each step and the tracking hits sent to GA4 and ad platforms. If a GA4 tag stops firing on a funnel page, you can be alerted to that. It will not tell you whether the session source was kept across subdomains.
To watch for self-referrals yourself, add a monthly check of Traffic acquisition for your own hostnames, or build a GA4 Exploration with Session source / medium filtered on your domain and set an email schedule for it. You can also run the manual journey test above after every site change.
Questions people ask
Why is my own website showing up as a referral in GA4?
GA4 is treating a visit to your own domain as coming from an outside site. This usually happens when a subdomain uses a different measurement ID or cookie, loads the tag late, or sits on a domain not listed in your cross-domain settings. The session restarts and the source becomes your own hostname.
How do I exclude my own domain from referrals in GA4?
Go to Admin > Data streams, open your web stream, then Configure tag settings > Show all > List unwanted referrals. Add a condition where the referral domain contains your root domain. GA4 will then stop treating it as a new source.
Does GA4 track subdomains automatically?
Mostly yes. GA4 sets its cookie on your root domain, so subdomains of the same site share one client ID if they use the same measurement ID and the tag loads on each page. Separate domains are different and need cross-domain measurement.
Why does GA4 count one visit as two sessions between www and shop?
The subdomain is probably not reading the same cookie, or it sends data to a different property. GA4 then sees a new visitor and starts a new session. Use one measurement ID and a shared cookie domain.
Do I need cross-domain tracking for subdomains?
Normally not, because subdomains share the cookie. You need it for separate domains such as a hosted booking tool on another domain. Add those domains in Configure your domains in the data stream.
Will fixing self-referrals change my past GA4 data?
No. GA4 does not reprocess old sessions, so past self-referral rows remain. The fix improves data from the day it takes effect.
Does FunnelGuard detect GA4 self-referrals?
No. FunnelGuard does not check for this yet. It can check that GA4 tracking hits fire on your funnel steps, but you need to review session sources in GA4 yourself.
Related issues
- TRK-005Two GA4 measurement IDs sending to the same propertyFix guide
- TRK-003Wrong GA4 measurement ID (staging or another client's property)Fix guide
- TRK-013GA4 missing on hosted checkout or booking domainFix guide
- TRK-014GA4 data stream web URL pointing to an old domainFix guide
- TRK-006GA4 installed twice (gtag.js and GTM) causing double page_viewsFix guide
- TRK-001GA4 tag missing from a funnel pageFix guide