Odel
Google Ads

Google Ads

Local
@getmcpads-comTypeScriptApache-2.0Updated 5 days ago

Google Ads: 31 read tools with full Keyword Planner, 7 write tools that preview first.

google-ads-mcp-server

CI License: Apache 2.0 Node

An open-source Model Context Protocol server for the Google Ads API. It lets Claude, ChatGPT, Cursor or any MCP client read and analyse your Google Ads data, plan keywords, and change campaigns if you choose to.

You run it. Your credentials stay on your machine. Nothing is proxied through a third party.

npx -y @getmcpads/google-ads-mcp-server

Also listed in the MCP Registry as com.getmcpads/google-ads, so clients that read the registry can install it by name.

Prefer not to run it yourself? getmcpads.com is the hosted version of this server, with Google Ads alongside Meta Ads, TikTok Ads, Pinterest Ads, GA4 and Search Console behind a single endpoint, hosted OAuth, and cross-platform reporting. Same tools, same safety model, no setup.


What you get

31 read toolsCampaigns, ad groups, budgets, bidding strategies, search terms, landing pages, Performance Max assets and placements, Shopping, recommendations, change history
7 write toolsOff by default. Status, budgets, bids, schedules, renames, campaign creation. Each one previews before it applies
Full Keyword PlannerKeyword ideas, historical metrics, forecasts, ad group themes, geo target suggestions
130 metrics, 84 dimensionsWith a compatibility matrix that catches invalid combinations before they hit the API
5 resourcesLive catalogues the model can read: metrics, dimensions, compatibility rules, 11 workflow recipes
GAQL and beyondgoogle_ads_run_gaql for raw queries, and google_ads_run_readonly_rpc for the services GAQL cannot reach

You do not need to know GAQL

The Google Ads API is queried with GAQL, its own query language, and most of its surface is only reachable that way. This server carries the metric and dimension catalogues, so the model asks for cost and conversions by name and the server writes the query.

google_ads_validate_query lets it check a combination before spending a call on it, and google_ads_run_gaql is still there when you want to write GAQL yourself.

Keyword Planner is not in GAQL

Keyword ideas, historical volumes and forecasts live in a separate RPC service that GAQL cannot reach at all. Same for Reach Planner, audience insights and benchmarks. This server covers them through google_ads_run_readonly_rpc and dedicated tools.


How this compares to Google's own MCP server

Google shipped an official Google Ads MCP server in April 2026. It takes the opposite design approach, and the comparison is more nuanced than for other platforms.

This serverGoogle's official servergetmcpads.com
Tools38 (31 read + 7 write)3: list accounts, GAQL search, resource metadata38, plus 5 other platforms
HostingSelf-hosted. stdio, local processSelf-hosted (pipx) or Cloud RunHosted for you
Requires knowing GAQLNo, catalogues drive the queryYes, for anything beyond listing accountsNo
Keyword PlannerYes. Ideas, history, forecasts, ad group themesNot availableYes
Reach Planner, audience insightsYes, through the read-only RPCNot availableYes
Performance Max diagnosticsYes, dedicated toolsThrough hand-written GAQLYes
WritesYes, preview first. Applied only on confirm: trueNone, read-only by designYes, preview first
Metric compatibilityQuery planner splits incompatible requestsNoneSame planner
AuditableYes. Apache-2.0Yes, it is open tooThis server, audited

Be fair about it. Google's server is self-hostable too, so "your data stays on your machine" is not a difference here. Its 3 tools are a deliberate minimalist design: one GAQL tool can express most of the reporting surface, and a model fluent in GAQL will do a lot with very little.

The difference is where the knowledge lives. There, it lives in the model, which has to write correct GAQL against a schema of thousands of fields. Here, it lives in the server, in catalogues and a compatibility matrix. Add to that the planning services GAQL cannot reach at all, and writes that cannot fire on the first call.

Choose Google's if your model writes good GAQL and you only need reporting. Choose this one if you want named metrics instead of query language, Keyword Planner and Reach Planner access, or guarded writes. Choose getmcpads.com if you want this server's capabilities without running it, or you need more than one ad platform in the same conversation.


Getting credentials

This is the heaviest setup of any advertising platform. Four values are needed, and one of them requires a review by Google. Budget an hour the first time.

1. Developer token

From a manager (MCC) account, open Tools → API Center and apply for a token. It starts at Test Account level, which only reaches test accounts. Apply for Basic Access to reach live accounts. Google reviews the application, which can take a few days.

šŸ“– Developer token documentation

2. OAuth client

In a Google Cloud project, enable the Google Ads API, then create an OAuth client under APIs & Services → Credentials. Choose Desktop app for local use. Note the client ID and client secret.

3. Refresh token

Run the OAuth consent flow once, signed in as the Google account that can see your ad accounts, and keep the refresh token it returns. Google's own helper script does this in one command.

šŸ“– OAuth desktop flow

The refresh token does not expire. It is the sensitive value here: anyone holding it can mint access tokens indefinitely. Treat it like a password, and use an OAuth client dedicated to this server so you can revoke it on its own.

4. Login customer ID, if you use a manager account

If the accounts you query sit under an MCC, set GOOGLE_ADS_LOGIN_CUSTOMER_ID to the manager account ID. Dashes are accepted and stripped. Skip it for a standalone account.

You can also leave it unset. Google refuses any request against a managed account unless the call names its manager, with a USER_PERMISSION_DENIED that mentions neither the account nor the manager, so it reads as missing access rather than as a missing header. When the variable is unset and the account you query is not directly accessible, the server asks the managers it can reach which accounts they hold, and announces the one that holds yours. The answer is resolved once and kept for the life of the process.

Setting the variable is still faster: it skips that discovery entirely, and it is the right choice when every account you query sits under the same MCC.

Run google_ads_health_check as your first call. It verifies all four credentials, lists the accounts you can actually reach, and reports what is missing, without printing any secret.


Setup

Claude Desktop

~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows):

{
  "mcpServers": {
    "google-ads": {
      "command": "npx",
      "args": ["-y", "@getmcpads/google-ads-mcp-server"],
      "env": {
        "GOOGLE_ADS_DEVELOPER_TOKEN": "your-developer-token",
        "GOOGLE_ADS_CLIENT_ID": "your-client-id",
        "GOOGLE_ADS_CLIENT_SECRET": "your-client-secret",
        "GOOGLE_ADS_REFRESH_TOKEN": "your-refresh-token"
      }
    }
  }
}

Restart Claude Desktop. Ask it: "list my Google Ads accounts".

Claude Code

claude mcp add google-ads --env GOOGLE_ADS_DEVELOPER_TOKEN=... --env GOOGLE_ADS_CLIENT_ID=... --env GOOGLE_ADS_CLIENT_SECRET=... --env GOOGLE_ADS_REFRESH_TOKEN=... -- npx -y @getmcpads/google-ads-mcp-server

Cursor

.cursor/mcp.json in your project, same shape as the Claude Desktop config above.

From source

git clone https://github.com/getmcpads-com/google-ads-mcp-server.git
cd google-ads-mcp-server
npm install && npm run build
cp .env.example .env   # then fill in your credentials
npm start

Configuration

VariableDefaultMeaning
GOOGLE_ADS_DEVELOPER_TOKENnoneRequired. From the API Center, Basic Access or above
GOOGLE_ADS_CLIENT_IDnoneRequired. OAuth client ID
GOOGLE_ADS_CLIENT_SECRETnoneRequired. OAuth client secret
GOOGLE_ADS_REFRESH_TOKENnoneRequired. From the consent flow
GOOGLE_ADS_LOGIN_CUSTOMER_IDnoneOptional. Manager (MCC) account ID. Resolved automatically when unset
GOOGLE_ADS_ENABLE_WRITESunsetSet to 1 to register the 7 write tools
LOG_LEVELinfodebug, info, warn, error

Check your setup at any time:

npm run doctor

Writes, and why they preview first

Write tools are disabled by default. Enable them with GOOGLE_ADS_ENABLE_WRITES=1. Google's own server has none at all, so this is the part to read carefully.

When enabled, every write tool returns a preview and changes nothing:

// google_ads_update_campaign_budget { customerId: "123-456-7890", budgetId: "555", dailyAmount: 50 }
{
  "applied": false,
  "action": "google_ads_update_campaign_budget",
  "change": { "customer": "1234567890", "budget": "555",
              "newDailyBudget": 50, "inMicros": 50000000 },
  "message": "Preview only, nothing was changed. Repeat the same call with confirm: true to apply this change to the live account."
}

Only a second call carrying confirm: true touches the live account.

This is deliberate. An assistant composes these calls, and it can pick the wrong customer, the wrong campaign, or the wrong order of magnitude on a budget. A mandatory preview makes the mistake visible before it costs money, and gives a human the stopping point the protocol does not guarantee on its own.

Two further guardrails:

  • google_ads_create_campaign always creates the campaign PAUSED. There is no option to create it active. Someone has to look at it before it spends.
  • Amounts are converted to micros for you. Google holds money in millionths, so 12.50 in the account currency is 12500000. The preview shows both, so a factor-of-a-thousand mistake is visible before it applies.
ToolWhat it changes
google_ads_update_campaign_status / google_ads_update_adgroup_statusPause, re-enable or remove
google_ads_update_campaign_budgetDaily budget
google_ads_update_adgroup_bidDefault CPC bid
google_ads_update_campaign_scheduleStart and end dates
google_ads_rename_campaignName only
google_ads_create_campaignCreates a budget, then a campaign, always PAUSED

Tools

31 read tools

Discovery and health

ToolPurpose
google_ads_health_checkValidates all four credentials and lists reachable accounts
google_ads_list_accountsEvery account the credentials can reach
google_ads_get_account_detailsCurrency, timezone, status, account settings
google_ads_get_account_hierarchyThe MCC tree above and below an account

Structure and settings

ToolPurpose
google_ads_get_campaigns / google_ads_get_adgroupsList entities and their settings
google_ads_get_budgets / google_ads_get_bidding_strategiesBudgets and bidding configuration
google_ads_get_conversion_actionsConversion actions and their settings
google_ads_get_change_eventsChange history: who changed what, and when

Performance

ToolPurpose
google_ads_get_insightsThe main reporting tool. Named metrics, no GAQL required
google_ads_validate_queryCheck a metric and dimension combination before running it
google_ads_get_keyword_performance / google_ads_get_search_termsKeyword and query performance
google_ads_get_landing_pagesLanding page performance
google_ads_get_paid_organic_search_termsPaid and organic side by side
google_ads_get_simulationsBid and budget simulations
google_ads_get_recommendationsGoogle's own recommendations for the account

Performance Max and Shopping

ToolPurpose
google_ads_get_pmax_assets / google_ads_get_pmax_asset_diagnosticsAsset groups, assets and their issues
google_ads_get_pmax_placementsWhere Performance Max actually served
google_ads_get_shopping_performance / google_ads_get_shopping_productsShopping performance and product data

Keyword Planner

ToolPurpose
google_ads_generate_keyword_ideasKeyword ideas from seeds or a URL
google_ads_generate_keyword_historical_metricsVolumes, competition, trends
google_ads_generate_keyword_forecast_metricsForecast clicks, cost and conversions
google_ads_generate_ad_group_themesSuggested ad group groupings
google_ads_suggest_geo_targetsResolve place names to geo target constants

Escape hatches

ToolPurpose
google_ads_run_gaqlRun a raw read-only GAQL SELECT
google_ads_run_readonly_rpcCall an allowlisted non-GAQL read service: Reach Planner, audience insights, benchmarks
google_ads_search_fieldsSearch the API field schema

These exist so a new field or service doesn't require a new release. Only read-only statements and an allowlist of services are accepted.

5 resources
URIContents
google-ads://manifestWhat this server exposes, and which tool to run first
google-ads://metricsAll 130 metrics with categories and formats
google-ads://dimensionsAll 84 dimensions and where they are valid
google-ads://compatibilityThe compatibility matrix
google-ads://recipes11 step-by-step workflows

Security

This server holds a refresh token that never expires, a client secret and a developer token. Concretely:

  • None of the four credentials is ever logged, at any log level, or written to disk.
  • The access token is cached in memory until a minute before expiry, rather than re-requested on every call.
  • Two hosts are contacted, and only two: googleads.googleapis.com and oauth2.googleapis.com. A test fails the build if a third host appears in the source.
  • No fetch follows a redirect. Every outbound call sets redirect: "error", so a redirect cannot forward a bearer token or client secret to another host. A test fails the build if any fetch omits this.
  • No telemetry. The server makes no network call other than to Google.

Full policy and reporting instructions: SECURITY.md.


Looking for a managed, multi-platform version?

This server does one platform, on your machine, with your credentials. That is on purpose.

If you'd rather not run it yourself, or you need Google Ads alongside Meta Ads, TikTok Ads, Pinterest Ads, GA4 and Search Console behind one endpoint, with hosted OAuth and cross-platform reporting, that's what we build at getmcpads.com.

Same philosophy, less plumbing. This project stays open source and independently useful either way.


Contributing

Issues and pull requests are welcome. See CONTRIBUTING.md. Please read SECURITY.md before reporting anything security-related.

Licence

Apache License 2.0. See also NOTICE.

Google, Google Ads and the Google Ads API are trademarks of Google LLC. This project is not affiliated with, endorsed by, or sponsored by Google LLC. It is an independent client of a public API.