DEV Community

Cover image for How Server-Side Tagging With sGTM Actually Works — Architecture, Consent, and Platform Integration Explained
Mehwish Malik
Mehwish Malik

Posted on

How Server-Side Tagging With sGTM Actually Works — Architecture, Consent, and Platform Integration Explained

If you have been tasked with implementing server-side tracking and the documentation feels scattered, this post aims to fill the gap with a clear architectural overview.

The problem with client-side tracking

Traditional client-side tags (Google Tag Manager browser container, Meta Pixel, etc.) fire from window.onload or event listeners in the user's browser. Every request goes from the browser to a third-party endpoint. This creates three problems: browser privacy controls block them, third-party cookies get restricted, and too many tags hurt Core Web Vitals.

The server-side architecture

Server-side tagging (sGTM) adds a server container in the middle of this data flow:

Browser → Server Container → Ad Platform APIs

The browser sends a single event to your server container. The container then forwards the data to Google Ads, Meta CAPI, TikTok Events API, LinkedIn CAPI, etc. All outbound calls are server-to-server — browsers cannot block them.

Cookie behaviour change

When the server sets a first-party cookie (using the HttpOnly flag), it bypasses ITP/ETP restrictions. Cookies that would expire in 7 days under Safari's ITP can now persist up to 400 days, significantly improving attribution windows.

Consent integration

This is where most DIY implementations break. Server-side firing must respect user consent. You need to pass consent state from the browser to the server container and conditionally block tags based on that state.

Seers AI's Server-Side Tagging handles this out of the box — real-time consent synchronisation, GDPR-compliant, with the container hosted in Frankfurt (EU data residency).

Full Implementation Walkthrough

Instead of guessing the setup, follow this step-by-step video guide:

Getting started

Platform integrations are documented here:
— Google Ads: support docs in Seers Help Centre
— Meta CAPI: available with deduplication support
— TikTok Events API, LinkedIn, Bing Ads, Reddit, Awin, Snapchat, Google Floodlight — all covered

The platform offers a managed setup, so you skip the Cloud Run / Stape.io configuration overhead.

Free tier available for testing. Full pricing at Seers Ai

Top comments (0)