Server-Side Tracking with GA4: Implementation Guide 2026
Traditional web analytics is in crisis. Ad blockers, third-party cookie restrictions, Safari's ITP, and privacy regulations have created a perfect storm that silently erodes the quality of your data. If you still rely solely on client-side tracking, you're making business decisions based on incomplete information.
In 2026, server-side tracking is no longer an advanced option for technical early adopters. It's an operational necessity for any company that relies on accurate data to optimize its digital marketing investment.
In this comprehensive guide, we explain exactly how to implement server-side tracking with GA4, the real costs involved, and how this architecture will allow you to recover between 20% and 40% of the data you are currently losing.
What Is Server-Side Tracking and How Is It Different from Client-Side?
Server-side tracking (also known as server-side tracking) is a data collection model where tracking requests are processed through an intermediary server before being sent to analytics or advertising platforms.
In the traditional client-side model, the user's browser directly executes the JavaScript code of Google Analytics, Meta Pixel, or any other tracking tool. This code sends the data directly from the browser to the servers of these platforms.
Client-Side Architecture (Traditional Model)
User → Browser → GA4 JavaScript → Google Analytics ServersServer-Side Architecture (2026 Model)
User → Browser → Your GTM Server → Google Analytics Servers
→ Meta Servers
→ TikTok Servers
→ CRM / Data WarehouseThe fundamental difference lies in control. With server-side tracking, you manage an intermediary server that:
- Receives all tracking hits from the browser
- Processes, enriches, and filters the data according to your rules
- Distributes the information to multiple destinations simultaneously
- Operates on your own domain, avoiding third-party blocks
This architecture not only improves data accuracy but also provides you with sovereignty over your analytical information, something critical in the current regulatory context.
Why Does Client-Side Tracking Lose Between 20% and 40% of Data?
The data loss in client-side tracking is not a pessimistic hypothesis. It is a documented reality that affects practically all websites. Let's look at the main factors:
1. Ad Blockers and Privacy Extensions
According to Statista data updated to 2025, approximately 32% of internet users use some type of ad blocker. In markets like Germany or the Nordic countries, this figure exceeds 40%.
Modern blockers like uBlock Origin, Brave Browser, or Firefox with Enhanced Tracking Protection not only block ads: they intercept and cancel requests to known tracking domains like google-analytics.com, googletagmanager.com, or connect.facebook.net.
2. Safari's Intelligent Tracking Prevention (ITP)
Apple implemented ITP in Safari years ago, but recent versions are extraordinarily aggressive. ITP 2.3+ limits first-party cookies set by JavaScript to 7 days of lifespan, and in some cases to just 24 hours.
What does this mean? A user who visits your site from Safari and returns 8 days later will be counted as a completely new user, distorting critical metrics such as:
- Returning vs. new users
- Conversion attribution
- Customer journey analysis
- Lifetime value models
3. Browser Privacy Policies
Chrome, Firefox, and Edge have implemented or announced progressive restrictions on third-party cookies and tracking mechanisms. Although Chrome has delayed the complete removal of third-party cookies, alternatives like Privacy Sandbox still do not offer the same data granularity.
4. Unstable Connections and Hit Loss
Client-side tracking depends on the browser completing the HTTP request before the user closes the page or navigates to another site. On slow or unstable mobile connections, up to 5-10% of hits simply fail to register.
5. Consent Mode and Cookie Banners
With the mandatory implementation of Consent Mode v2 in Europe, users who reject analytical cookies generate modeled data (estimated by Google's machine learning) instead of real data. Although useful, modeled data has significant limitations for granular analysis.
Cumulative Impact: The Reality of Your Data
The good news is that server-side tracking can recover a significant portion of these lost data, especially those related to blockers and hit loss.
How Does Server-Side Architecture Work with GTM Server?
Google Tag Manager Server-Side (GTM Server) is Google's official solution for implementing server-side tracking. It functions as an intermediary layer between your website and destination platforms.
Main Components
1. Web Container (Client-Side)
Your traditional GTM container still exists, but with a crucial difference: instead of sending data directly to Google Analytics, it sends it to your Transport URL (the address of your GTM server).
2. GTM Server (Server Container)
A special container that runs on a server (not in the browser). This server:
- Receives hits from the web container
- Processes them using Clients (data receivers)
- Transforms them using Tags (output tags)
- Sends them to final destinations
3. Clients
Clients are the data receivers on the server. The most common is the GA4 Client, which interprets requests in GA4 Measurement Protocol format. There are also clients for:
- Google Ads
- Floodlight
- Custom HTTP requests
4. Server Tags
Similar to web container tags, but executed on the server. They include:
- GA4 Tag (sending to Google Analytics)
- Google Ads Conversion Tag
- Meta Conversions API Tag
- TikTok Events API Tag
- HTTP Request Tag (for custom integrations)
Complete Data Flow
1. User visits your site
2. GTM Web loads (from your domain, not googletagmanager.com)
3. Event triggers (page_view, purchase, etc.)
4. GTM Web sends hit to tracking.yourdomain.com
5. GTM Server receives the hit
6. GA4 Client processes and parses the data
7. Server tags send data to:
- Google Analytics 4
- Meta Conversions API
- Google Ads
- Your Data Warehouse
8. Response to the browser (first-party cookie)What Hosting Options Exist for GTM Server?
One of the most important decisions when implementing server-side tracking is where to host your GTM server. There are three main options:
1. Google Cloud Platform (App Engine)
This is the official option recommended by Google and the easiest to initially configure.
Advantages:
- Native integration with GTM
- Automatic deployment from the GTM interface
- Auto-scaling included
- No infrastructure management
Disadvantages:
- Variable and potentially high cost with high traffic
- Less control over server configuration
- Complete dependence on the Google ecosystem
Estimated Cost:
- Low traffic (up to 1M hits/month): 40-80€/month
- Medium traffic (1-10M hits/month): 150-400€/month
- High traffic (10-50M hits/month): 500-2,000€/month
2. Stape.io
Stape has established itself as the leading alternative for GTM Server hosting. It offers a platform specifically optimized for server-side tracking.
Advantages:
- Predictable and generally cheaper prices than GCP
- Specific control panel for GTM Server
- Specialized technical support
- Hosting options in Europe (GDPR compliance)
- Additional features (Stape Gateway, Data Layer enrichment)
Disadvantages:
- Dependence on a third-party provider
- Less flexibility for extreme customizations
Estimated Cost:
- Starter Plan: 20€/month (up to 500K requests)
- Pro Plan: 100€/month (up to 5M requests)
- Business Plan: 300€/month (up to 20M requests)
- Enterprise: Custom
3. Self-Hosted (AWS, Azure, VPS)
For organizations with robust DevOps teams, it is possible to deploy GTM Server on their own infrastructure.
Advantages:
- Total control over infrastructure
- Potentially cheaper at large scale
- Maximum configuration flexibility
- Independence from providers
Disadvantages:
- Requires significant technical expertise
- Responsibility for maintenance, updates, and security
- Complex initial configuration
Estimated Cost:
- Basic VPS: 20-50€/month + management time
- AWS/Azure with auto-scaling: 100-500€/month depending on traffic
Our Recommendation
For most companies, Stape offers the best balance between cost, ease of use, and features. We only recommend GCP for those who already have all their infrastructure in Google Cloud, or self-hosted for organizations with very specific compliance requirements.
How to Implement Server-Side Tracking Step by Step?
Below, we guide you through the complete implementation process. This procedure assumes you already have GA4 running with GTM client-side.
Step 1: Create the Server Container in GTM
- Go to tagmanager.google.com
- Click "Create Container"
- Select Server as the container type
- Assign a descriptive name (e.g., "MyCompany - Server")
- Google will show you provisioning options
Step 2: Configure Hosting
If you choose Stape:
- Create an account at stape.io
- Add a new container and connect your GTM Server
- Set up your custom subdomain (tracking.yourdomain.com)
- Stape will generate the server URL automatically
If you choose Google Cloud:
- Select "Auto-Provision" in GTM
- Authorize access to your Google Cloud account
- Select the project and region
- Wait for deployment (5-10 minutes)
Step 3: Set Up the Custom Domain
This step is critical to avoid ad blockers.
- Create a DNS record type A or CNAME pointing tracking.yourdomain.com to your GTM server
- Set up SSL/TLS (Stape does it automatically; GCP requires additional configuration)
- Update the server URL in GTM to use your custom domain
Step 4: Configure the GA4 Client
In your Server container:
- Go to "Clients" → "New"
- Select "GA4" as the client type
- Configure the options:
- Default GA4 paths: Enabled - JavaScript Managed by Server Container: Recommended to enable
Step 5: Create the GA4 Tag on the Server
- Go to "Tags" → "New"
- Select "Google Analytics: GA4"
- Configure:
- Measurement ID: Your GA4 ID (G-XXXXXXX) - Send client event: Enabled
- Trigger: "All Pages" or according to your logic
Step 6: Modify the Web Container
Now you need to update your GTM client-side container:
- Edit your GA4 configuration tag
- In "Send Options", enable "Send to server container"
- Enter your Server Container URL (https://tracking.yourdomain.com)
- Save and publish
Step 7: Verify the Implementation
- Activate Preview mode in both containers (Web and Server)
- Visit your website
- Verify that:
- The Web container sends hits to your tracking domain - The Server container receives the hits - Events appear in GA4 DebugView
Step 8: Configure First-Party Cookies
To maximize cookie durability:
- In the server's GA4 Client, enable "Set cookie on eTLD+1"
- Verify that your tracking domain is a real subdomain
- Test cookie persistence in Safari
What Is Consent Mode v2 and How Does It Affect Server-Side Tracking?
Consent Mode v2 is the updated Google framework for managing user consent in Europe. Since March 2024, it is mandatory for any company using Google Ads or GA4 for remarketing in the European Economic Area.
Differences Between Consent Mode v1 and v2
Implementation with Server-Side
Server-side tracking does not eliminate the need for Consent Mode, but allows for more sophisticated management:
- Basic Consent Mode: The server respects consent signals sent from the client
- Advanced Consent Mode: Even if the user rejects cookies, pings can be sent without identifiers to feed Google's models
- Granular Control: You can implement server-side logic for different consent levels
Recommended Configuration
// In your CMP (Cookiebot, OneTrust, etc.)
gtag('consent', 'default', {
'ad_storage': 'denied',
'ad_user_data': 'denied',
'ad_personalization': 'denied',
'analytics_storage': 'denied',
'wait_for_update': 500
});
// When the user accepts
gtag('consent', 'update', {
'ad_storage': 'granted',
'ad_user_data': 'granted',
'ad_personalization': 'granted',
'analytics_storage': 'granted'
});The server-side container will receive these signals and transmit them correctly to GA4 and other destinations.
Impact on Data Quality
With server-side tracking + Consent Mode v2 correctly implemented:
- Users who accept: Full tracking with durable first-party cookies
- Users who reject: Enhanced modeled data by Google
- Net Result: Greater accuracy than client-side in both scenarios
How Much Does It Really Cost to Implement Server-Side Tracking?
The total cost of server-side tracking includes several components:
Infrastructure Costs (Hosting)
Implementation Costs
Hidden Costs to Consider
- Monthly Maintenance: 2-4 hours for monitoring and adjustments
- Updates: Google updates GTM Server periodically
- Debugging: Server-side issues are more complex to diagnose
- Training: Your team will need training
Expected ROI
The return on investment depends on the volume of data recovered and its impact on your decisions:
- E-commerce with 50K€/month in ads: Recovering 25% of conversions can mean 12,500€ in correct attribution
- Lead generation B2B: Better attribution data can increase ROAS by 15-30%
- SaaS: Accurate funnel tracking reduces CAC and improves projected LTV
What Specific Use Cases Benefit Most from Server-Side Tracking?
E-commerce: Recover Lost Conversions
E-commerce is perhaps the vertical that benefits most from server-side tracking:
Typical Problem:
- High use of Safari/iOS among premium buyers
- Multi-day purchase journeys (ITP destroys attribution)
- Ad blockers in technical audiences
Server-Side Solution:
- First-party cookies with 2 years of duration
- Sending transaction data directly from the server
- Integration with Meta's Conversions API for precise remarketing
Recommended Implementation:
- Server-side GA4 for all events
- Meta CAPI for purchase and add_to_cart events
- Google Ads Enhanced Conversions via server
- Deduplication of events between client and server
Lead Generation B2B: Multi-Touch Attribution
B2B companies with long sales cycles face unique challenges:
Typical Problem:
- 30-90 day cycles between first contact and conversion
- Multiple stakeholders visiting from different devices
- CRM disconnected from web analytics
Server-Side Solution:
- Persistence of first-party data throughout the cycle
- Enrichment of leads with browsing data
- Direct integration with HubSpot, Salesforce, Pipedrive
Recommended Implementation:
- Server-side tracking with user_id when available
- Webhook to CRM on form submissions
- Offline conversion synchronization to GA4
SaaS: Unified Product + Marketing
SaaS companies need to connect marketing data with in-app behavior:
Typical Problem:
- Users blocking tracking after registration
- Product data separated from marketing data
- Difficulty calculating CAC by channel
Server-Side Solution:
- Unified tracking pre and post-login
- Product events sent from backend
- Data warehouse as a single source of truth
Recommended Implementation:
- Hybrid tracking: client-side for marketing, server-side for product
- Measurement Protocol for backend events
- BigQuery as an additional destination from GTM Server
How to Measure the Success of Your Server-Side Implementation?
Once implemented, you need to verify that you are indeed capturing more data:
Key Metrics to Compare (Before vs. After)
- Unique Users: Should increase (less fragmentation by ITP)
- Conversion Rate: More accurate (not necessarily higher)
- Registered Events: Higher total volume
- Cookie Retention: Verify duration in Safari
- Platform Discrepancy: Less difference between GA4 and backend
A/B Test of Tracking
During 2-4 weeks after implementation:
- Keep client-side active in parallel
- Compare hits received by both methods
- Calculate the "lift" of server-side
- Document the percentage of data recovered
Continuous Monitoring
Set up alerts for:
- 5xx errors on the GTM server
- Response latency over 500ms
- Abrupt drops in event volume
- Integration failures (Meta CAPI, etc.)
Conclusions: The Future of Tracking Is Server-Side
Server-side tracking has evolved from being an experimental technology to becoming essential infrastructure for any data-driven marketing strategy in 2026.
The benefits are clear:
- Recovery of 20-40% of lost data
- Durable first-party cookies
- Greater control over your information
- Better integration with Consent Mode v2
- Flexibility for multiple destinations
The costs, while real, are manageable and the ROI is usually positive within a few months for any company with significant digital marketing investment.
At Kiwop, we have been implementing server-side architectures since their early versions. If you need help evaluating whether this solution is right for your business or want an audit of your current tracking, our web analytics team is at your disposal.
Want to explore how server-side tracking can improve your data and, consequently, your CRO strategies? Contact us for a personalized assessment.
Frequently Asked Questions About Server-Side Tracking
Is Server-Side Tracking Legal with GDPR?
Yes, server-side tracking is fully compliant with GDPR as long as you correctly implement Consent Mode and obtain appropriate consent. In fact, by using first-party cookies and servers in Europe, you can improve your compliance position.
Do I Need to Maintain Client-Side Tracking Alongside Server-Side?
In most implementations, yes. Client-side is still necessary to capture browser events and send them to the server. What changes is the destination: instead of going directly to Google, they pass through your server first.
How Long Does It Take to Implement Server-Side Tracking?
A basic implementation can be completed in 1-2 weeks. Complex implementations with multiple destinations and custom logic may require 4-8 weeks.
Does Server-Side Tracking Eliminate the Need for Cookie Banners?
No. You still need to obtain consent for analytical and advertising tracking. What changes is the accuracy of the data you capture from users who do consent.
Can I Use Server-Side Tracking Only for Certain Events?
Yes, it is a common strategy. Many companies implement server-side only for critical conversion events (purchases, leads) while maintaining client-side for engagement events.
What Happens If My GTM Server Goes Down?
You should configure redundancy and monitoring. Stape and GCP offer high availability. It is also advisable to maintain a client-side fallback for critical events.
Does Server-Side Tracking Affect My Website's Speed?
Correctly implemented, it should not negatively affect it. In fact, it can improve performance by reducing the number of third-party scripts loaded in the browser.
How Does It Affect My Remarketing Audiences?
Remarketing audiences are maintained and even improved, as you are sending more complete and accurate data to advertising platforms through their conversion APIs.
Schema FAQ
{
"@context": "https://schema.org",
"@type": "FAQPage",
"mainEntity": [
{
"@type": "Question",
"name": "What is server-side tracking and how does it work with GA4?",
"acceptedAnswer": {
"@type": "Answer",
"text": "Server-side tracking is a data collection model where tracking requests are processed through an intermediary server before being sent to GA4. Instead of the browser sending data directly to Google, it sends it to your GTM server, which processes and distributes it to final destinations."
}
},
{
"@type": "Question",
"name": "How much data is lost with traditional client-side tracking?",
"acceptedAnswer": {
"@type": "Answer",
"text": "Client-side tracking can lose between 20% and 40% of data due to ad blockers (15-35% loss), Safari's ITP (5-15%), hit loss from unstable connections (3-8%), and cookie rejection (10-30%)."
}
},
{
"@type": "Question",
"name": "How much does it cost to implement server-side tracking?",
"acceptedAnswer": {
"@type": "Answer",
"text": "Costs vary depending on traffic volume and complexity. Hosting can cost from 20€/month with Stape to hundreds of euros on GCP for high traffic. Initial implementation by an agency ranges from 800€ for basic setups to 8,000€ for advanced implementations."
}
},
{
"@type": "Question",
"name": "Is server-side tracking compatible with Consent Mode v2?",
"acceptedAnswer": {
"@type": "Answer",
"text": "Yes, server-side tracking is fully compatible with Consent Mode v2. The server respects consent signals sent from the client and allows for more sophisticated consent management, including sending modeled data when users reject cookies."
}
},
{
"@type": "Question",
"name": "What hosting platform is best for GTM Server?",
"acceptedAnswer": {
"@type": "Answer",
"text": "For most companies, Stape offers the best balance between cost, ease of use, and features. Google Cloud Platform is suitable if you already have infrastructure in GCP. Self-hosting is only recommended for organizations with very specific compliance requirements and robust DevOps teams."
}
},
{
"@type": "Question",
"name": "Does server-side tracking improve web speed?",
"acceptedAnswer": {
"@type": "Answer",
"text": "Correctly implemented, server-side tracking can improve web performance by reducing the number of third-party scripts loaded in the browser. Pixels from Meta, TikTok, and other platforms run on the server instead of the user's browser."
}
},
{
"@type": "Question",
"name": "Can I use server-side tracking for Meta Ads and Google Ads?",
"acceptedAnswer": {
"@type": "Answer",
"text": "Yes, GTM Server natively supports integrations with Meta Conversions API, Google Ads Enhanced Conversions, TikTok Events API, and many other platforms. This allows sending more precise conversion data directly to advertising platforms."
}
},
{
"@type": "Question",
"name": "Do I need advanced technical knowledge to implement server-side tracking?",
"acceptedAnswer": {
"@type": "Answer",
"text": "A basic implementation requires intermediate knowledge of GTM and DNS concepts. Advanced implementations require knowledge of JavaScript, APIs, and server architecture. Many companies choose to work with specialized web analytics agencies for the initial implementation."
}
}
]
}Article updated in January 2026. Technical specifications and prices may vary according to platform updates.