Server-Side GTM Setup Guide & Documentation
Use this guide to deploy BonicBD, configure tags, and validate cleaner attribution flows. If you need pricing or migration context first, compare the plans or contact the team.
What Is Server-Side GTM?
Server-side Google Tag Manager (sGTM) moves your tracking from the visitor's browser to a server you control. Instead of the browser sending events directly to Meta, Google, or TikTok, it sends them to your own subdomain — and your server forwards them to the destination platforms.
In practice this can improve three things: common browser-side blockers are less likely to intercept a first-party endpoint, cookies can often persist longer when they are managed server-side, and events can be enriched before they are forwarded onward.
Requirements
- A domain you control (e.g.,
yourbrand.com) - Ability to create a DNS CNAME record on a subdomain
- A Google Tag Manager account (free) — both Web and Server containers
1. Sign Up & Pick a Plan
Create an account at https://panel.bonicbd.com/user/signup. Pick a plan based on your monthly request volume — see pricing. The free trial is enough to validate the setup before you commit.
2. DNS Configuration (CNAME)
Pick a tracking subdomain like tracking.yourbrand.com, server.yourbrand.com, or gtm.yourbrand.com. Then add this single CNAME record at your DNS provider:
Type: CNAME
Name: tracking (or server / gtm — your choice)
Value: connect.bonicbd.com
TTL: 300 (or default — Auto on Cloudflare)
connect.bonicbd.com — that way, infrastructure changes on our side never break your tracking. If you're on Cloudflare, set proxy status to DNS only (grey cloud) so SSL provisioning works.track. or analytics. — some ad-blocker lists target them. tracking., server., gtm., ss. all work well.3. Install the Snippets (auto-generated)
Once your CNAME is verified, the dashboard generates three ready-to-paste snippets for your container. You don't write them by hand — copy from Dashboard → Setup Guide and paste:
- Head code (Google Tag Manager loader) — paste at the very top of
<head>on every page. - Body noscript — paste right after the opening
<body>tag. - Integrated Tracker script — a separate first-party script that handles cookie keeping, click ID restoration, UTM capture, and event de-duplication.
The Head and Tracker scripts both load from your own tracking subdomain, which can improve resilience against common browser-side blocking patterns. The exact snippet URLs are auto-generated per container.
4. Web GTM & Server GTM Setup
Inside your Web GTM container add a Cookie Extender (Custom HTML on All Pages) and a 1st-Party Cookie variable for bbd_uid — both are pre-written in the dashboard. In your Server GTM container set the Server Container URL to your tracking subdomain and add the Event Data variable for external_id mapping. The Setup Guide gives you exact field values per container.
Cookie Keeper
Cookie Keeper can refresh server-set _fbp, _fbc, _ga, and click-ID cookies for longer retention windows. Exact duration still depends on browser rules, consent settings, and your final implementation.
Click ID Restorer
Captures fbclid, gclid, ttclid, msclkid, twclid, li_fat_id, epik, scid, _kx, and obclid on first hit. Stores them in cookies, localStorage, and IndexedDB so later conversion events can use those identifiers again when the setup is configured to do so.
Consent Mode V2
Configure default consent state per region. EU traffic gets denied defaults until consent; non-EU traffic stays granted. Conversion modeling kicks in for denied-consent EU traffic. Toggle via the dashboard.
Bot Detection
We score every request and silently drop traffic from known bot user agents and headless browser fingerprints before it reaches your analytics pipeline. Reduces noise and protects your event quality.
Real-Time Dashboard
Every request that reaches your container is logged and aggregated in real time. Filter by event name, platform, country, or path. Watch your conversion ledger fill up as orders come in.
Preview Mode
Each plan includes a dedicated preview container. Connect it from GTM's Preview & Debug — you'll see every tag fire just like the production container, but isolated from your real traffic.
Troubleshooting
If events aren't reaching your destination platforms:
- Open your tracking subdomain in a browser — you should see the BonicBD landing page
- Check the dashboard's real-time view to confirm events are reaching the server
- Open GTM Preview & Debug to confirm tags are firing
- Check the platform's Event Manager (Meta) or DebugView (GA4) for incoming events
- If still stuck, message us on WhatsApp — we'll debug with you
Documentation FAQ
No. BonicBD is a managed setup, so you do not need to provision Google Cloud infrastructure yourself just to run server-side GTM with the platform.
Teams commonly use tracking., server., gtm., or ss. subdomains. Choose a subdomain you control and can point by CNAME to the BonicBD target.
A standard deployment is often completed within the same day once DNS is in place and the required snippets can be added to the site. More complex GTM tagging setups may take longer.
Yes. Start with the realtime dashboard and this guide, then contact support if events are still missing. DNS, route configuration, and tag logic are the most common places to check.