| [ Web Proxy ] |
| Viewing: https://developers.cloudflare.com/google-tag-gateway/ | [Back] [Original] |
Google tag gateway for advertisers allows website owners using Cloudflare as a CDN to get the most out of ad measurement tools with just a few clicks. It allows you to deploy Google scripts using your own domain, enhancing data privacy and improving signal measurement recovery. Unlike standard setups where tags are requested from a Google domain, Google tag gateway for advertisers loads the tag from your domain and sends measurement events to your domain, where they are forwarded to Google.
Learn more about why we built it and how it works in our blog post .
Google tag gateway for advertisers is free to use. Requests routed through the gateway do not count toward usage or billing for other Cloudflare products such as CDN, WAF, or Bot Management.
Site owners can enable this feature in one of two ways: through the Google tag console, or through the Cloudflare dashboard .
The fastest way to set up Google tag gateway for advertisers is in Google Tag Manager. Follow the steps in Google's Help Center .
Note
Your Cloudflare dashboard user must have one of the following Account Roles: Super Administrator, Administrator or Zaraz Admin. If you are using Domain Scoped Roles, your Domain Role must be Domain Administrator.
In the Cloudflare dashboard, go to the Google Tag Gateway page.
Go to Google Tag Gateway ↗Select your domain.
Enable the toggle for Turn on and configure Google tag gateway.
[Google tag gateway for advertisers configuration]
[Add to ID and path]
Now that you have authenticated into your Cloudflare account and configured GTM in first-party mode, your Google Tags will be loaded using https://your-domain/measurement-path/...and subsequent measurement requests will be served by Cloudflare.
Google tag gateway for advertisers is configured at the zone level. When you enable it for a zone (for example, example.com), it applies to all hostnames and subdomains within that zone, including custom hostnames. Currently, it is not possible to enable or disable the feature for individual subdomains independently. Configuration Rules cannot be used to control or disable the tag injection on specific subdomains.
If you need different tag behavior for specific subdomains (for example, only firing certain tags on shop.example.com), you can use Google Tag Manager triggers to control when tags fire. For example, you can create a trigger condition like Page Hostname equals shop.example.com to restrict a tag to a specific subdomain.
This approach lets you maintain a single zone-wide Google tag gateway configuration while still customizing tag behavior per subdomain.
| Web Proxy Viewer | New URL | Original Page |