Google Tag Manager MCP Server

Google Tag Manager is a tag management system that lets you configure and deploy marketing tags, analytics pixels, and conversion tracking on your website without editing code. Manage tags, triggers, variables, and publish container versions via the GTM API.

23 tools
SKILL.md

Start chatting with Google Tag Manager tools

Open Studio to chat with 23 Google Tag Manager tools right now — the skill is included automatically.

AI Skill
SKILL.md

Domain knowledge for Google Tag Manager — workflow patterns, data models, and gotchas for your AI agent.

Google Tag Manager

Manage marketing and analytics tags without editing site code: create, read, update, and delete tags, triggers, and variables; review version history and roll back; stage work in workspaces; publish container versions.

Hierarchy

Account → Container → Workspace → Tags / Triggers / Variables. Discover accounts, then containers, then the default workspace.

Read-oriented workflows

  • Audit existing setup: Enumerate accounts → enumerate containers → enumerate tags, triggers, and variables.
  • Inspect a tag: Open full tag details including parameters, conversion IDs, custom HTML content.
  • Inspect a trigger: Open full trigger details including event filters and conditions.
  • Version history: Enumerate published versions to see what changed when. Open a specific version for a full snapshot.
  • Check live config: Request version id 0 for the exact currently published definition.

Write-oriented workflows

  • Add conversion tracking: Create a custom event trigger (e.g., signup) → create a Google Ads Conversion tag linked to that trigger → publish.
  • Update existing tags: Change parameters, link new triggers, pause/unpause tags.
  • Create variables: Add dataLayer variables, constants, or JavaScript variables for tags to reference.
  • Enable built-in variables: Enable Click URL, Page Path, Form ID, etc. for use in triggers.
  • Create workspace: Isolate changes in a new workspace (like a branch) before publishing.

Publish and rollback

  • Publish: Create a version from workspace and push live.
  • Rollback: Re-publish a previous version to undo bad changes.

Revert workspace drafts

  • Revert tag/trigger: Undo workspace changes before publishing — restore to last published state.

Key Concepts

  • Workspaces: Draft environments. Default workspace ID varies (enumerate workspaces to find it). Changes are staged here.
  • Tag types: awct (Google Ads Conversion), ua (Universal Analytics), gaawc (GA4 Config), gaawe (GA4 Event), html (Custom HTML), img (Custom Image).
  • Trigger types: customEvent, pageview, domReady, click, linkClick, formSubmission, historyChange, timer, scrollDepth, elementVisibility.
  • Parameter format: GTM API uses a specific Parameter object format: {"type": "template", "key": "keyName", "value": "theValue"}.
  • Consent settings: Tags can require specific consent types before firing (GDPR compliance).
  • Version IDs: Version id 0 refers to the live published container.

Tools in this Server (23)

Gtm Create Tag

Create a tag in a GTM workspace. Tags fire when their linked triggers evaluate to true. Common use: create a Google Ads Conversion tag (type='awct') l...

Gtm Create Trigger

Create a trigger in a GTM workspace. Triggers define when tags fire. For conversion tracking, create a 'customEvent' trigger matching a specific dataL...

Gtm Create Variable

Create a user-defined variable in a GTM workspace. Variables hold data that tags and triggers reference. Most common: Data Layer Variable (type='v') w...

Gtm Create Workspace

Create a new workspace for isolating changes (like a branch). Work in the new workspace, then publish when ready. Free GTM accounts are limited to 3 w...

Gtm Delete Tag

Delete a tag from a GTM workspace. This is a workspace change — publish to make it live. Cannot be undone after publishing.

Gtm Delete Trigger

Delete a trigger from a GTM workspace. Will fail if any tags still reference this trigger. Remove tag links first.

Gtm Enable Built In Vars

Enable built-in variables like Page URL, Click URL, Form ID, etc. These are pre-defined by GTM and just need to be enabled to use in triggers and tags...

Gtm Get Tag

Get full details of a GTM tag including all parameters, firing triggers, consent settings, and schedule. Use this to inspect what a tag actually does ...

Gtm Get Trigger

Get full details of a GTM trigger including event filters, conditions, and type-specific settings.

Gtm Get Version

Get full details of a container version — all tags, triggers, and variables at that point in time. Use version_id='0' for the latest published version...

Gtm List Accounts

List all Google Tag Manager accounts. Returns account IDs and names needed for all other GTM operations.

Gtm List Containers

List all containers in a GTM account. Returns container IDs, names, public IDs (GTM-XXXXXX), and domain names.

Gtm List Tags

List all tags in a GTM workspace. Returns tag names, types, firing triggers, and paused status. Common types: awct (Google Ads Conversion), gaawe (GA4...

Gtm List Triggers

List all triggers in a GTM workspace. Returns trigger names, types, and IDs. Common types: customEvent, pageview, domReady, click, formSubmission, his...

Gtm List Variables

List all user-defined variables in a GTM workspace. Variables hold data that tags and triggers reference (e.g., dataLayer variables, JavaScript variab...

Gtm List Versions

List all container version headers. Shows version IDs, names, descriptions, and who published them. Use to audit history or find a version ID for roll...

Gtm List Workspaces

List workspaces in a GTM container. Workspaces are draft environments where changes are staged before publishing. The default workspace is usually ID ...

Gtm Publish

Create a new container version from the workspace's current state and publish it live. This makes all staged changes (tags, triggers, variables) activ...

Gtm Revert Tag

Revert all uncommitted changes to a tag in a workspace back to the last published state.

Gtm Revert Trigger

Revert all uncommitted changes to a trigger in a workspace back to the last published state.

Gtm Set Latest Version

Rollback: re-publish a previous container version, making it the live version. Use gtm_list_versions to find the version ID to roll back to.

Gtm Update Tag

Update a GTM tag — rename, change parameters, link/unlink triggers, or pause/unpause. First use gtm_get_tag to see current state. Only provided fields...

Gtm Update Trigger

Update a GTM trigger — rename, change event name, or modify filters. Changes are staged — use gtm_publish to push live.

Frequently Asked Questions

What is the Google Tag Manager MCP server?

Google Tag Manager is a tag management system that lets you configure and deploy marketing tags, analytics pixels, and conversion tracking on your website without editing code. Manage tags, triggers, variables, and publish container versions via the GTM API. It provides 23 tools that AI agents can use through the Model Context Protocol (MCP).

How do I connect Google Tag Manager to my AI agent?

Add the MCPBundles server URL to your MCP client configuration (Claude Desktop, Cursor, VS Code, etc.). The URL format is: https://mcp.mcpbundles.com/bundle/google-tag-manager. Authentication is handled automatically.

How many tools does Google Tag Manager provide?

Google Tag Manager provides 23 tools that can be called by AI agents, along with a SKILL.md that gives your AI agent domain knowledge about when and how to use them.

What authentication does Google Tag Manager require?

Google Tag Manager uses One-click sign in. Google Tag Manager requires credentials. Connect via MCPBundles and authentication is handled automatically.

Setup Instructions

Connect Google Tag Manager to any MCP client in minutes

https://mcp.mcpbundles.com/bundle/google-tag-manager

What is MCP?

Model Context Protocol lets AI tools call external capabilities securely through a single URL. This bundle groups tools behind an MCP endpoint that many clients can use.

Use this bundle in 3 steps

  1. Copy the MCP URL above
  2. Open your AI tool and add a new MCP/connector
  3. Paste the URL and follow any auth prompts

Claude Desktop Users

Skip the manual setup! Use the .mcpb file format for one-click installation. Check the Claude Desktop tab for setup instructions.

Pick your tool tab for exact steps

Select ChatGPT, Cursor, Claude Code, or another tab for copy-paste config.

Ready to use Google Tag Manager?

Open Studio and start using 23 tools right now — no setup required

Google Tag Manager MCP Server & Skill — 23 Tools