What you can read and change in Google Tag Manager
| Area | Read | Change |
|---|---|---|
| Accounts and users | Accounts, user permissions | Update accounts, add, change or remove user permissions |
| Containers | Containers, install snippet, lookup by GTM-XXXX tag ID, destinations | Create, update, combine or delete containers, move a tag ID, link a destination |
| Workspaces | Workspaces, workspace status (changed entities and merge conflicts) | Create, sync, bulk update, resolve conflicts, quick preview |
| Tags, triggers, variables | Every entity, built-in variables, Google tag configs | Create, update, delete or revert; enable or disable built-in variables |
| Templates and folders | Custom templates, folders and their contents | Create or import gallery templates, create folders, move entities into folders |
| Versions | Live version, latest version header, version history | Create a version from a workspace, publish, set latest, delete or undelete |
| Environments | Environments | Create, update, delete or reauthorize |
| Server containers | Clients, transformations, zones | Create, update, delete or revert |
How a GTM change runs
Google Tag Manager already separates drafts from production. Tags, triggers and variables are edited in a workspace, and nothing reaches your site until a container version is published. The MCP follows that model, so a typical change is: read the container, write the new entities into a workspace, read the workspace status, test in Preview, then create a version and publish it.
- Writes are queued as jobs by default and return a job id. gtm_action_job_status reads the result, or pass wait_for_completion to wait.
- Every write carries an idempotency key, so a retried call does not create a second tag or trigger.
- Updates and publishes accept GTM's fingerprint, so a change fails instead of overwriting someone else's newer edit.
- When Google's Tag Manager API quota is hit, Whathead returns a retry-after time instead of hammering the API.
There is no dry run for GTM writes
Most Whathead platform writes start as dry-run previews. GTM writes do not: each create, update, delete or publish call is a real Tag Manager API request. The protection comes from GTM's own workspace and from these limits:
- gtm_audit_ops reads a container without writing and reports duplicate names, tags with no firing trigger, references to missing triggers or variables, paused tags and merge conflicts.
- Connect https://www.whathead.com/mcp/read for a connector that can only read. Its gtm_native_read tool refuses writes before anything reaches Google.
- GTM writes need the write:gtm scope on the connector, and only the Whathead workspace owner can run them.
- Claude and ChatGPT ask before running a write tool unless you have set it to always allow. Do not set GTM writes to always allow.
What still needs a person
The assistant removes the form-filling. It does not remove the judgment.
- Testing in Preview mode (Tag Assistant) on the real site before you publish. The API cannot click through your checkout.
- Consent settings on each tag and the consent banner itself. Which tags may fire before consent is a legal and business decision.
- Naming conventions, so the next person can read the container.
- The decision to publish. Ask for the workspace status and read it before you approve the publish call.
Other Google Tag Manager MCP servers
| Stape google-tag-manager-mcp-server | Whathead | |
|---|---|---|
| Hosting | Hosted at gtm-mcp.stape.io/mcp, or a local CLI with your own credentials | Hosted at www.whathead.com/mcp |
| Code | Open source, Apache-2.0 | Hosted service, source not public |
| GTM coverage | 20 GTM tools, per its README | 106 Tag Manager API v2 actions plus a read-only audit |
| Other platforms | GTM only | GA4, Search Console and 12 ad platforms in the same chat |
Set up the Google Tag Manager MCP
Connect GTM in Whathead
In Integrations, connect Google Tag Manager with the Google account that can edit your containers.
Add Whathead to your assistant
Claude: Settings, Connectors, add a custom connector with https://www.whathead.com/mcp. ChatGPT: a developer-mode connector with the same URL. Cursor: the URL plus a bearer token minted in Whathead.
Start with a read
Ask the assistant to look up your container by its GTM-XXXX ID and list its tags, triggers and variables, or run the container audit.
Make changes in a workspace
Ask for the new tag, trigger and variable, read the workspace status, test in Preview, and only then ask for a version and publish.
Google Tag Manager prompts to try
Look up container GTM-XXXXXXX and list every tag with its type, firing trigger and consent setting.
Audit the Default Workspace of GTM-XXXXXXX and explain each finding in plain language.
Which tags fire on All Pages, and are any two of them loading the same pixel?
Create a Data Layer Variable for ecommerce.transaction_id, a Custom Event trigger for purchase, and a GA4 event tag that uses both. Do not publish.
Show me the workspace status: every entity that changed since the live version.
Compare the live version with the latest version and list what changed.
Move every tag whose name starts with "Meta" into a folder called Meta.
Create a version named "GA4 purchase event" from this workspace and publish it after I confirm.
Plan limits
GTM calls share the monthly MCP allowance with your ad platforms: MCP Actions ($39) with 1,500 reads and 100 writes, Operator Bundle ($65) with 4,000 and 250, Agency ($249) with 15,000 and 750. Creating a tag, a trigger and a variable, then a version and a publish, uses 5 writes. All plans start with a 14-day trial.
Frequently asked questions
Is there an official Google Tag Manager MCP?
We found none from Google as of 18 November 2026. Google publishes an official MCP server for Google Analytics, and Stape maintains an open-source GTM MCP server.
Can the assistant publish my container?
Yes, if your Google account can publish and the connector has write access. Publishing is a separate call after a version is created, so ask for the workspace status first and confirm the publish yourself.
Does it work with server-side GTM?
Yes. Server containers use the same API, and the MCP covers their clients, transformations, tags, triggers and variables. Hosting the tagging server itself is outside Whathead.
Can it set up consent mode?
It can read and set the consent settings on each tag. Choosing a consent banner and deciding which tags wait for consent stays with you.
Can I connect it without write access?
Yes. Add https://www.whathead.com/mcp/read instead of /mcp. That connector lists only read tools and refuses GTM writes.
Run it from one workspace
Every plan starts with a 14-day free trial. Only successful live work is metered.
Sources
- Google: Tag Manager API v2 reference (developers.google.com)
- Google: Tag Manager API limits and quotas (developers.google.com)
- Google: Consent mode in Tag Manager (support.google.com)
- Stape: google-tag-manager-mcp-server on GitHub (github.com)