cohnen_mcp_google_ads

cohnen_mcp_google_ads

by cohnen
An MCP server that connects Google Ads with Claude AI for natural language analysis of advertising data.

Google Ads AI Integration with Claude

Overview

An MCP tool that connects Google Ads with Claude AI, Cursor, and others, enabling natural language analysis of advertising data. This integration provides access to campaign information, performance metrics, keyword analytics, and ad management through simple chat interactions.

Google Ads MCP

Key Features

Account Management

  • View all Google Ads accounts in one place.
  • Access account details and basic campaign information.

Campaign Analytics & Reporting

  • Identify top-performing campaigns.
  • Track impressions, clicks, conversions, and cost metrics.
  • Analyze performance trends over time.
  • Visualize data with charts and graphs created by Claude.

Keyword & Ad Performance

  • Identify top and underperforming keywords.
  • Analyze ad copy effectiveness.
  • Check quality scores and competitive metrics.
  • Get actionable insights for campaign improvement.

Budget & Bid Management

  • Monitor campaign budgets and spending.
  • Analyze bid strategies and performance.
  • Identify optimization opportunities.
  • Receive budget allocation recommendations.

Architecture Flow

flowchart TB
    User(User) -->|Interacts with| Claude
    Claude(Claude AI Assistant) -->|Makes requests to| MCP[Google Ads MCP Server]
    User -->|Can also use| Cursor[Cursor AI Code Editor]
    Cursor -->|Makes requests to| MCP

    subgraph "MCP Server"
        FastMCP[FastMCP Server] 
        Tools[Available Tools]
        Auth[Authentication]

        FastMCP -->|Exposes| Tools
        FastMCP -->|Uses| Auth
    end

    subgraph "Google Ads Tools"
        ListAccounts[list_accounts]
        ExecuteGAQL[execute_gaql_query]
        CampaignPerf[get_campaign_performance]
        AdPerf[get_ad_performance]
        RunGAQL[run_gaql]
    end

    Tools -->|Includes| ListAccounts
    Tools -->|Includes| ExecuteGAQL
    Tools -->|Includes| CampaignPerf
    Tools -->|Includes| AdPerf
    Tools -->|Includes| RunGAQL

    subgraph "Authentication"
        OAuth[OAuth 2.0 Client ID]
        ServiceAccount[Service Account]
        Credentials[Google Ads API Credentials]

        OAuth -->|Provides| Credentials
        ServiceAccount -->|Provides| Credentials
    end

    MCP -->|Communicates with| GoogleAdsAPI[Google Ads API]
    GoogleAdsAPI -->|Returns| AdData[Advertising Data]
    AdData -->|Analyzed by| Claude
    AdData -->|Visualized by| Claude
    AdData -->|Can be used by| Cursor

    Credentials -->|Authorizes| GoogleAdsAPI

    subgraph "Configuration"
        EnvVars[Environment Variables]
        ConfigFiles[Configuration Files]

        EnvVars -->|Configures| MCP
        ConfigFiles -->|Configures| Claude
        ConfigFiles -->|Configures| Cursor
    end

Available Tools

Tool Description Requirements
list_accounts Lists all Google Ads accounts None
execute_gaql_query Runs a Google Ads Query Language query Account ID and GAQL query
get_campaign_performance Retrieves campaign metrics Account ID and time period
get_ad_performance Analyzes ad creative performance Account ID and time period
run_gaql Runs custom GAQL queries Account ID, query, and format

Example GAQL Queries

-- Basic campaign metrics
SELECT campaign.name, metrics.clicks, metrics.impressions 
FROM campaign 
WHERE segments.date DURING LAST_7DAYS

-- Ad group performance
SELECT ad_group.name, metrics.conversions, metrics.cost_micros 
FROM ad_group 
WHERE metrics.clicks > 100

-- Keyword analysis
SELECT keyword.text, metrics.average_position, metrics.ctr 
FROM keyword_view 
ORDER BY metrics.impressions DESC

Getting Started

1. Set Up Google Ads API Access

  • OAuth 2.0 Client ID: Best for individual users or desktop applications.
  • Service Account: Ideal for automated systems or managing multiple accounts.

2. Install Required Software

  • Python (version 3.11 or newer)
  • Node.js
  • Claude Desktop

3. Download the Google Ads MCP

git clone https://github.com/ixigo/mcp-google-ads.git

4. Install Required Components

# Create a virtual environment
uv venv .venv

# Activate the virtual environment
source .venv/bin/activate

# Install dependencies
uv pip install -r requirements.txt

5. Connect Claude to Google Ads

Configure claude_desktop_config.json with your Google Ads API credentials.

6. Start Analyzing Your Advertising Data

Ask Claude questions about your Google Ads data and receive actionable insights.

Data Visualization Capabilities

Claude can generate:
- Trend Charts
- Comparison Graphs
- Performance Distributions
- Correlation Analysis
- Heatmaps

Troubleshooting

Python Command Not Found

sudo ln -s $(which python3) /usr/local/bin/python

Claude Configuration Issues

  • Verify file paths and credentials.
  • Restart Claude Desktop after changes.

Google Ads API Limitations

  • Check API quotas and permissions.

Testing Your Setup

Run test_google_ads_mcp.py to verify your connection.

Contributing

Found a bug or have an idea? Open an issue or submit a pull request on GitHub.

License

This project is licensed under the MIT License.

About ixigo

ixigo is India's leading travel app. For more information, visit ixigo.com.

ixigo logo

Features & Capabilities

Categories
mcp_server model_context_protocol python claude google_ads api_integration search data_analysis

Implementation Details

Stats

0 Views
13 GitHub Stars

Repository Info

cohnen Organization

Similar MCP Servers

continuedev_continue by continuedev
25049
21423
9300
SunMonTueWedThuFriSat
303112345678910111213141516171819202122232425262728293012345678910
:
PM
SunMonTueWedThuFriSat
303112345678910111213141516171819202122232425262728293012345678910
:
PM