- Home
- Learn
- Server-side tracking setup
Three ways to do it, what each one really costs in time and upkeep, and a five-step setup you can finish this afternoon. Written for marketers, with a shortcut for anyone who already uses Claude, ChatGPT or Cursor.
This guide is built from the questions real PixelFlow customers ask on setup calls, grounded in how Meta’s Pixel and Conversions API actually behave.
What server-side tracking is, in plain terms
Server-side tracking means your conversion events travel from a server to the ad platform, instead of from the visitor’s browser. The browser still records what happened, but a server you control (or a service that runs one for you) does the sending. Meta calls its version the Conversions API, Google has Enhanced Conversions, TikTok has the Events API, and they all solve the same problem.
The problem is that the browser is no longer a reliable messenger. Ad blockers, Safari’s tracking prevention, iOS consent prompts and short-lived cookies mean a meaningful share of purchases and leads never reach the platform at all. The ads still ran. The sales still happened. The platform just never heard about them, so it cannot learn from them or credit the ad that caused them.
This guide walks through the setup from a blank site to verified events, and it is honest about the fork in the road: you can build the infrastructure yourself, run a server-side Google Tag Manager container, or use a managed platform like PixelFlow that already runs the server. If you want the why before the how, start with The Meta Conversions API explained.
What you need before you start
Every approach needs the same handful of things. Gather them first and the setup itself is quick.
A published website on its own domain. Tracking is verified against the live domain, not a preview or staging address.
Admin access to your ad accounts. For Meta that means Business Manager with a Pixel (now called a dataset) you can edit. The same applies to Google Ads, TikTok and any other platform you send to.
A short list of the conversions that matter. A purchase, a lead form, a booking or a signup. Three to five events is normal; thirty is a sign something has gone wrong.
A decision on consent. Know which events may fire before someone accepts cookies and which must wait. Server-side tracking does not remove that obligation.
The right amount of time. With a managed platform, about fifteen minutes. With server-side GTM, plan for a working day the first time, plus hosting that keeps running after you leave.
If your site is on Webflow, Framer, Squarespace, WordPress or a similar builder, you will not have a server of your own. That is fine. It only rules out the do-it-yourself route.
Three ways to set it up
There are three honest routes to the same outcome. The difference is who runs the server.
1. Build it yourself. A developer writes code that receives events from your site and forwards them to each platform’s API. Maximum control, maximum cost, and every platform change lands in your backlog. Only sensible when you already have an engineering team and unusual requirements.
2. Server-side Google Tag Manager. You create a server container, pay for hosting (typically a cloud instance), map a custom domain, then rebuild your tags, triggers and consent logic on the server side. It is flexible and well documented, but it is a second tag manager to maintain, and the hosting bill never stops.
3. A managed platform. A service like PixelFlow runs the server. You add one script to your site, choose which actions count as conversions, connect your ad accounts, and the platform handles delivery, deduplication and hashing. Setup is minutes rather than days, and there is nothing to host.
The rest of this guide follows the managed route, because it is the one most marketing teams end up choosing, and it is the only one you can hand to an AI assistant. If you already use Claude, ChatGPT, Cursor or Codex, PixelFlow exposes the whole setup through an MCP connection, so the chat does the clicking and you approve the result. Where the server-side GTM route differs, the steps say so.
Step 1: Put the tracking script on your site
Server-side tracking still starts in the browser, because that is where visits happen. One lightweight script captures page views, clicks and form submissions, attaches the identifiers the ad platforms need (hashed, never raw), and hands everything to the server.
With PixelFlow: create a site in the dashboard, enter the domain and currency, and copy the snippet it gives you into your site’s head. Webflow, Framer and Squarespace have a custom code field for this; WordPress and Shopify have a plugin or theme setting. Publish, then run the built-in site check, which confirms the script is live on the real domain.
With server-side GTM: install the web container as usual, then point your GA4 or custom tags at your server container’s URL so events are routed through it instead of straight to the platforms.
With an AI assistant: once PixelFlow is connected to your chat, type / and pick setup_tracking. The assistant creates or updates the site, gives you the install steps with your snippet already filled in, and runs the live check for you. A chat that already has your project open, such as Cursor, can place the snippet itself.
Step 2: Decide which events to send, and how they fire
An event is one reported action: a purchase, a lead, a booking, a signup. Each needs a trigger, which is the rule that says when it happened. Most conversions fit one of four patterns:
A page loads. The thank-you or order-confirmation page is the classic signal. Add the value and currency if the page knows them.
A form is submitted. Native forms, embedded forms and most form builders can be caught on submit without any code.
Something is clicked. A ‘Book a call’ button or an outbound checkout link. A visual tagger lets you pick the element on the live page instead of writing a selector by hand.
A payment or booking happens elsewhere. Stripe and Calendly can send the event directly, so a purchase that completes off-site still counts.
Keep the list short and name events the way the platform expects (Purchase, Lead, CompleteRegistration), because that is what the optimisation models are trained on. For which events matter most, see The Meta Conversions API explained.
This is the step where an assistant earns its keep. After the site check passes, the PixelFlow MCP can inspect the published site and propose the events that are still missing. It shows one list, you approve it or strike the lines you do not want, and only the approved triggers are saved.
Step 3: Connect Meta and your other ad platforms
Now the server needs somewhere to send the events. For Meta, connect the Pixel (dataset) that your ads already optimise against; the connection grants the server permission to post events on its behalf. Add Google Ads, TikTok or any other platform the same way, one connection each.
Two details matter here. First, send the identifiers the platform can match on: email, phone, name, and the click ID from the ad (fbclid for Meta). All of them are hashed before they leave, and better matching shows up as a higher Event Match Quality score, which the platform rewards with cheaper, better-targeted delivery. Second, set a test event code while you work so your own test purchases are labelled as tests rather than counted as real.
With server-side GTM you add a client and a tag per destination, then map every parameter by hand. With PixelFlow the connection is a one-time link that opens the platform’s own sign-in. The MCP hands you that link in the chat; it works once and lasts thirty minutes.
Why this step changes results is covered in Event Match Quality explained.
Step 4: Deduplicate, then verify every event
If the browser pixel and the server both report the same purchase, the platform sees two sales unless you tell it they are one. The fix is an event ID: the same unique value attached to both copies, so the platform keeps one and discards the duplicate. A managed platform generates this for you; in server-side GTM you create and pass it yourself.
Refreshes are the other common double count. A blocking rule stops a second Purchase firing when someone reloads the thank-you page, and it is worth adding before you go live rather than after the reporting looks strange.
Then verify. Open the platform’s test tool (Events Manager for Meta), trigger each event in a private window, and watch for it to arrive with a server source and the test code you set. Check the event log on your tracking side too: it should show the event, whether the platform accepted it, and the reason if it did not. If a trigger fires nothing, the usual cause is a selector that changed when the page was redesigned.
With the PixelFlow MCP you can ask the chat directly: ‘Did every Purchase reach Meta yesterday?’ or ‘Show me the last ten events and whether Meta accepted them.’ The answers come from the same event log, so you never leave the conversation to check. The mechanics of event IDs are in Deduplication, explained.
Step 5: Go live and keep it healthy
Once every event verifies, remove the test code and let real traffic flow. Expect two things in the first week. The platform’s numbers will not match your backend exactly, because it only credits conversions inside its attribution window and loses some to privacy settings; that is normal. And campaigns that were learning from thin data will wobble for a few days as the fuller signal arrives, then settle.
After that, the job is maintenance. Check blocked events weekly (a spike usually means a consent or bot issue), re-test triggers after any site redesign, and compare attributed revenue week over week. The weekly_report prompt in the PixelFlow MCP does exactly that comparison, and audit_tracking names a missed purchase before a selector that stopped matching.
Troubleshooting common issues
Events arrive in the browser but not server-side. The script is on a preview or staging domain, or the platform connection was never completed. Re-run the site check on the live domain.
Everything is counted twice. The event ID is missing on one side, or there is no refresh rule on the thank-you page.
Low match quality. Identifiers are not being sent, usually because a form field is not mapped or the click ID is lost on a redirect.
A trigger stopped firing. The page was redesigned and the element’s selector changed. Re-tag it, or ask the chat to check the selector on the live page.
Consent is blocking everything. Decide which events are allowed before consent and configure the banner accordingly. Server-side delivery does not bypass consent, and should not.
How long it takes, and what it costs
Building your own infrastructure is a project measured in weeks and an ongoing developer cost. Server-side GTM is usually a day or two of setup plus monthly hosting, and it needs someone who is comfortable in the container when a platform changes something. A managed platform is a flat subscription and a setup that takes less time than reading this guide. With the MCP route it can be a single conversation.
Set it up from your AI chat instead
If you already work in Claude, ChatGPT, Cursor, Codex or Claude Code, you can skip most of the clicking. PixelFlow runs an MCP server, an open standard that lets an assistant call tools on an outside service. Connect it once with your normal PixelFlow login, and the chat can do everything in the five steps above.
Connect. Add PixelFlow as a connector in your chat tool and sign in. No tokens, keys or passwords are ever pasted.
Start. Type / and pick setup_tracking, or paste the setup prompt. The assistant creates the site, gives you the install steps, and runs the live check.
Approve. It proposes the missing events as one list. You approve it, or strike what you do not want, and only that is saved.
Ask. From then on, ask it anything the dashboard knows: attributed revenue over the last seven days, which events were blocked and why, or what a buyer clicked before converting.
Every change is shown before it is saved, the chat can only reach sites your login already has, and it can never delete a site or a pixel. See how the PixelFlow MCP works for the per-tool steps.
Remember this if nothing else
Server-side tracking is not a different kind of tracking. It is the same events, delivered by a messenger that does not get blocked.
The browser still records the action; a server does the sending.
Gather domain access, ad-account access and a short event list before you start.
Pick the route by who runs the server: you, a GTM container, or a managed platform.
One script, a handful of triggers, one connection per platform.
Event IDs stop double counting; a refresh rule stops the other kind.
Verify with a test code before real traffic, and re-test after redesigns.
The platform’s numbers will never match your backend exactly, and that is fine.
An assistant connected through MCP can run the whole setup, with you approving each change.
Where PixelFlow fits
Everything above assumes you have a server to send from. On Webflow, Framer, Squarespace, WordPress and most other builders you do not, and hiring a developer to run one is the step where most teams stall.
PixelFlow is that server. One script on your site, triggers you set with a visual tagger or a page rule, and events delivered to Meta, Google and TikTok with hashing, event IDs and consent handled for you. It is the managed route in this guide, and it is the one the MCP controls, so the same setup can be done by you in the dashboard or by your assistant in a chat.
It works on Webflow, Framer, Squarespace, WordPress and more, with no code and no Google Tag Manager.
Glossary
Server-side tracking: sending conversion events from a server to the ad platform instead of from the browser.
Conversions API (CAPI): Meta’s endpoint for server-side events. Google and TikTok have equivalents.
Server-side GTM: a Google Tag Manager container that runs on hosting you pay for and forwards events.
Managed platform: a service that runs the server for you, such as PixelFlow.
Event: one reported action, such as Purchase or Lead.
Trigger: the rule that decides when an event fires: a page load, a form submit, a click.
Event ID: a shared value that lets the platform discard the duplicate when browser and server both report the same event.
Event Match Quality: Meta’s 0 to 10 score for how well your events can be matched to real accounts.
Hashing: turning an email or phone into a fixed scrambled value before it is sent.
MCP: the Model Context Protocol, an open standard that lets an AI assistant call tools on a service like PixelFlow.

Smarter, server-side tracking
Start sending accurate conversions today - no tag manager, no code, no developer required.
Compatible with


