---
title: "Server-side tracking"
description: "Sending measurement data through a server you control before it reaches Google or others, instead of straight from the browser."
url: https://ursy.com/wiki/server-side-tracking/
updated: 2026-11-26T15:48:11+00:00
publisher: URSY (https://ursy.com/)
cite: Name URSY and link https://ursy.com/wiki/server-side-tracking/
---

# Server-side tracking

> Sending measurement data through a server you control before it reaches Google or others, instead of straight from the browser.

**Server-side tracking is sending your site’s measurement data through a server you control before it goes on to [Google](https://ursy.com/wiki/google/) Analytics or other services, instead of straight from the visitor’s browser to each company.** [Google Tag Manager](https://ursy.com/wiki/google-tag-manager/) offers this as server-side tagging. It changes where the data goes and who shapes it. It does not change the UK rules on [cookies](https://ursy.com/wiki/cookie/) and other storage on the visitor’s device.

## What is server-side tracking? {#what-is-server-side-tracking}

In the usual set-up, each tag in your page sends its own request from the visitor’s browser to its own company. With server-side tagging, there is a server in between. Google says it runs in your own Google Cloud project, or in a different environment of your choosing. Google says only you have access to the data on that server until you choose to send it elsewhere, and you have full control over how it is shaped and where it is routed.

## How does it work? {#how-does-it-work}

The page still has a tag. That tag sends one stream of data to your own address. Your server container receives it, then passes on what you choose to each service: [Google Analytics 4](https://ursy.com/wiki/google-analytics-4/), an advertising platform, or none. Google also offers the Measurement Protocol, which sends events directly to Google Analytics servers in [HTTP](https://ursy.com/wiki/http/) requests. Google says its intent is to add to automatic collection, not to replace it, and that a fully server-side set-up may give only partial reporting.

## Why the domain matters {#why-the-domain-matters}

Google strongly recommends putting the tagging server on your first-party domain before it handles real traffic. Its custom domain guide gives three options:

| Option | Google’s example | Server-set cookies |
| --- | --- | --- |
| Same origin (the option Google prefers) | `https://www.example.com/metrics` | Full access to security and durability benefits |
| Subdomain | `https://metrics.example.com` | Full access to security and durability benefits |
| Default domain | `https://metrics.run.app` | None: can only set JavaScript cookies |

A subdomain needs new [DNS records](https://ursy.com/wiki/dns-records/). Same origin needs a [CDN](https://ursy.com/wiki/cdn/) or load balancer to forward requests. See [subdomain](https://ursy.com/wiki/subdomain/) and [first-party cookies](https://ursy.com/wiki/first-party-cookies/).

## Does it get round consent? {#does-it-get-round-consent}

No. The ICO says the UK rules apply to any technology that stores information, or accesses information stored, on a user’s device. It lists cookies, tracking pixels, link decoration and navigational tracking, web storage, fingerprinting techniques, and scripts and tags. If the browser still runs a tag or sets a cookie, the rules still apply, wherever the data goes next. See [PECR](https://ursy.com/wiki/pecr/), [UK GDPR](https://ursy.com/wiki/uk-gdpr/) and [cookie banner](https://ursy.com/wiki/cookie-banner/).

## What about the analytics exception? {#what-about-the-analytics-exception}

The ICO’s statistical purposes exception covers aggregate statistics about how the service is used, with a view to making improvements. The information must be aggregate statistical information you cannot use to identify people. You must give clear and comprehensive information about the purpose, and a “simple and free” way to object. The ICO says this exception “does not allow you to monitor or track individual visitors”. See [Consent Mode v2 for UK websites](https://ursy.com/wiki/consent-mode-v2-for-uk-websites/).

## Why does it matter for search? {#why-does-it-matter-for-search}

Fewer third-party scripts in the page can mean less work for the browser, which helps [page speed](https://ursy.com/wiki/page-speed/). It also gives one clear place to see what leaves your site. But measurement still starts in the browser, so it still sees only browsers that run the tag. [Search crawlers](https://ursy.com/wiki/search-crawler/) such as [Googlebot](https://ursy.com/wiki/googlebot/) do not show up in it. For [crawling](https://ursy.com/wiki/crawling/) you need [server logs](https://ursy.com/wiki/server-logs/); see [Search Console vs analytics](https://ursy.com/wiki/search-console-vs-analytics/).

## Why does it matter for AI answers? {#why-does-it-matter-for-ai-answers}

We sort every visitor into five kinds: people, [search engines](https://ursy.com/wiki/search-engine/), AI crawlers, AI agents and other machines. A browser tag, sent server-side or not, mainly sees people. An [AI crawler](https://ursy.com/wiki/ai-crawler/) that does not run scripts never makes a page view. An [AI agent](https://ursy.com/wiki/ai-agent/) using your [MCP](https://ursy.com/wiki/mcp/) server never loads a page. And a person sent by an AI app is visible only when the [referrer](https://ursy.com/wiki/referrer/) shows it. See [ChatGPT traffic in Google Analytics](https://ursy.com/wiki/chatgpt-traffic-in-google-analytics/).

## Server-side tagging or server logs? {#server-side-tagging-or-server-logs}

The names sound alike, but they see different things.

| Method | Where the data starts | Sees [bots](https://ursy.com/wiki/bot-web-robot/)? |
| --- | --- | --- |
| Browser tag | The visitor’s browser | No, only browsers that run it |
| Server-side tagging | Still the browser, then your server container | No, for the same reason |
| Server or edge log | Every request the server or CDN answers | Yes, every request with its [user agent](https://ursy.com/wiki/user-agent/) |

A log counts requests, often called [hit analytics](https://ursy.com/wiki/hit-analytics/). Pages answered by an [edge cache](https://ursy.com/wiki/edge-cache/) never reach your server, so only the CDN’s own log sees them.

## A worked example {#a-worked-example}

A bakery’s website sends measurement data in the usual way. Each page view makes the visitor’s browser send separate requests to Google Analytics and to an advertising service, directly from the page.

With server-side tagging, the browser sends one stream of data to the bakery’s own address, such as `metrics.example.co.uk`. That is the bakery’s server container. The container then decides what to pass on: page views to Google Analytics, and only the purchase event, with no full address or email, to the advertising service.

The cookie banner does not change. If the bakery needed consent for advertising cookies before, it still needs it, because the browser still stores and reads information on the visitor’s device.

## When does it help? {#when-does-it-help}

It helps when you send data to several services and want one place to decide what each one gets. It helps when you want to strip details, such as a full address or email, before anything leaves your server. And it helps when you want a clear record of every outgoing stream. It does not help if the real question is who visits besides people. For that, read the logs.

## Common mistakes {#common-mistakes}

- Treating it as a way round consent. The UK rules apply to what happens on the device.
- Leaving the old browser tags running alongside the new set-up, so every visit is counted twice. See [conversion tracking](https://ursy.com/wiki/conversion-tracking/).
- Using the default cloud domain, which Google says can only set JavaScript cookies.
- Forgetting the server must be run, because it sits in your own cloud project or another environment you choose.
- Expecting it to show bots. It does not; see [bot traffic in analytics](https://ursy.com/wiki/bot-traffic-in-analytics/).
- Expecting it to fix low numbers. See [why analytics numbers are low](https://ursy.com/wiki/why-analytics-numbers-are-low/).

## How to check it {#how-to-check-it}

1. Open a page with your browser’s developer tools, Network tab, and see where measurement requests go: to Google directly, or to your own address. Our [Tracking Checker](https://ursy.com/tracking-checker/) lists every tracker and pixel a page loads.
2. Run the [Cookie Checker](https://ursy.com/cookie-checker/) to see what a page sets before consent, and compare it with your [cookie banner](https://ursy.com/wiki/cookie-banner/).
3. Use the [HTTP Header Checker](https://ursy.com/http-header-checker/) to see cookies set in the response headers, and the [Security Headers Checker](https://ursy.com/security-headers-checker/) for the rest of the headers.
4. Check what the site runs with the [tech stack checker](https://ursy.com/tech-stack-checker/): CMS, shop and analytics.
5. Check the tagging subdomain resolves with the [DNS lookup](https://ursy.com/webmaster-tools/dns-lookup/).
6. In Google Tag Manager, check whether you have a server container as well as a web container.
7. Tag your campaign links with the [UTM builder](https://ursy.com/webmaster-tools/utm-builder/), so sources survive the move; see [UTM parameters](https://ursy.com/wiki/utm-parameters/).
8. For bots, read logs instead: drop a server log into the [AI Crawler Log Analyser](https://ursy.com/ai-crawler-log-analyzer/). See [log file analysis](https://ursy.com/wiki/log-file-analysis/).
9. For agents, run the [AI Agent Readiness](https://ursy.com/agent-readiness-checker/) check: OpenAPI, .well-known files, MCP and agent instructions.
10. Selling in the UK? The [UK Shop Compliance Checker](https://ursy.com/uk-shop-compliance-checker/) includes the cookie banner.

In URSY Pro, opening in stages: [cookie-free analytics](https://ursy.com/pro/cookie-free-analytics/), [measurement integrity](https://ursy.com/pro/measurement-integrity/), [cached-page visitors](https://ursy.com/pro/cached-page-visitors/) and [MCP and agent call analytics](https://ursy.com/pro/mcp-and-agent-call-analytics/).

## What URSY.com counts {#what-ursy-counts}

URSY.com counts with three recorders. The **Tag** is a small cookie-free counter in the page: it sees people whose browser runs scripts, and follows the site’s consent rules. The **Edge** is the content delivery network’s own log: every request at the cache, cached or not, bots included. The **API/MCP log** records every call to an API or MCP server we run. A request seen in both the edge log and the website’s own log has the same request ID, so it is counted once, and nothing is joined by who a person is. See our [methodology](https://ursy.com/methodology/).

## Questions {#questions}

### Is server-side tracking cookieless? {#is-server-side-tracking-cookieless}

Not by itself. Google’s own guide is about server-set cookies on your domain. Cookieless measurement is a separate choice; see [cookieless analytics](https://ursy.com/wiki/cookieless-analytics/).

### Do I still need a cookie banner? {#do-i-still-need-a-cookie-banner}

If you store or read information on the device for anything outside the exceptions, yes. The ICO’s rules cover any technology that does that.

### Will it show AI crawlers? {#will-it-show-ai-crawlers}

No. It starts in the browser, so bots that do not run scripts never appear. Edge or server logs show them.

### Is server-side tracking legal in the UK? {#is-server-side-tracking-legal-in-the-uk}

The method is not the question. The ICO’s rules look at what is stored on or read from the device, and why. Get consent where the rules need it, and tell people what you collect.

### Does it make my numbers higher? {#does-it-make-my-numbers-higher}

It can change them, for example if old and new tags both fire. Check for double counting before you compare months.

## Related words {#related-words}

- [First-party cookies](https://ursy.com/wiki/first-party-cookies/)
- [Consent Mode v2](https://ursy.com/wiki/consent-mode-v2/)
- [PECR](https://ursy.com/wiki/pecr/)
- [Cookieless analytics](https://ursy.com/wiki/cookieless-analytics/)
- [Google Analytics 4](https://ursy.com/wiki/google-analytics-4/)
- [Server logs](https://ursy.com/wiki/server-logs/)
- [Cookie banner](https://ursy.com/wiki/cookie-banner/)
- [Observed vs inferred data](https://ursy.com/wiki/observed-vs-inferred-data/)

## Sources {#sources}

- [Google Tag Manager: An introduction to server-side tagging](https://developers.google.com/tag-platform/tag-manager/server-side/intro), checked 24 November 2026
- [Google Tag Manager: Map server-side tagging to a custom domain](https://developers.google.com/tag-platform/tag-manager/server-side/custom-domain), checked 24 November 2026
- [Google Analytics: Measurement Protocol](https://developers.google.com/analytics/devguides/collection/protocol/ga4), checked 24 November 2026
- [ICO: What are storage and access technologies?](https://ico.org.uk/for-organisations/direct-marketing-and-privacy-and-electronic-communications/guidance-on-the-use-of-storage-and-access-technologies/what-are-storage-and-access-technologies/), checked 24 November 2026
- [ICO: Storage and access technologies, what are the exceptions?](https://ico.org.uk/for-organisations/direct-marketing-and-privacy-and-electronic-communications/guidance-on-the-use-of-storage-and-access-technologies/what-are-the-exceptions/), checked 24 November 2026

*Updated 24 November 2026 by URSY.com.*
