How to Set Up GA4 for Multiple Domains in a Single Analytics Property

Google Analytics 4 (GA4) marks a significant departure from Universal Analytics (UA). It is an update and a complete transformation designed for a privacy-focused, cross-platform world. Understanding these fundamental changes is essential, particularly when managing subdomains and separate domains.
From Sessions to Events: The Core Transformation
Universal Analytics relied on sessions as its primary metric, focusing on website traffic and pageviews. In contrast, GA4 is built around events, where every user interaction—including page views, clicks, scrolls, and video plays—is tracked as an event. This event-based model provides a more granular and flexible understanding of user behavior across websites and apps.
Several factors drive this shift:
- Privacy Compliance: With the rise of privacy regulations and the decline of third-party cookies, session-based tracking has become less reliable. GA4’s event-based model enhances user privacy protection.
- Cross-Platform Measurement: Users engage with brands across multiple platforms. GA4 unifies data from websites and apps, providing a holistic view of the customer journey.
- Predictive Analytics: GA4 integrates machine learning to offer predictive insights such as churn probability and revenue potential, empowering businesses to make informed decisions.
Impact on Subdomains and Separate Domains
GA4’s event-based approach influences how it handles subdomains and separate domains:
- Subdomains (e.g., blog.example.com, shop.example.com): GA4 automatically tracks users across subdomains within the same root domain without additional configuration. Since cookies are shared across subdomains, cross-domain tracking is unnecessary.
- Separate Domains (e.g., example.com, example-shop.com): Cross-domain tracking must be explicitly configured in GA4. Since different domains have separate cookies, GA4 must link user activity across these domains for a unified view.
Configuring Cross-Domain Tracking in GA4
To track users across separate domains, follow these steps:
- Use the Same Data Stream: Ensure all domains share the same Measurement ID, allowing data to flow into a single GA4 property.

- Access Cross-Domain Settings: In GA4, navigate to Admin (gear icon), then under Data collection and modification, select Data Streams, and choose your web data stream.

- Configure Tag Settings: Click on Configure tag settings.

- Add Domains for Cross-Domain Tracking: Click on Configure your domains and list all domains to include, ensuring you specify full domain names (e.g.,
example.com
,example-shop.com
).

- Save Changes: Click Save to apply your settings.
How Cross-Domain Tracking Works
When a user navigates from domainA.com
to domainB.com
, GA4 appends a unique parameter to the URL, which helps recognize that it is the same user. This allows GA4 to stitch together the user journey across domains.
Key Considerations
- Ensure Accurate Configuration: Double-check the domain list to avoid data discrepancies.
- Test Your Setup: Use GA4’s real-time report to verify cross-domain tracking functionality.
- Link Decoration: GA4 typically handles link decoration automatically, but manual configuration may be necessary in custom setups.
By understanding GA4’s fundamental shift and properly configuring cross-domain tracking, businesses can gain deeper insights into user behavior across all digital touchpoints.