Skip to main content
Glama
Google Search Console MCP

Google Search Console MCP

by dienhokhanh

Google Search Console MCP

A secure, community-maintained Model Context Protocol server for Google Search Console. It gives MCP clients structured access to Search Analytics, properties, sitemaps, and URL Inspection.

CI npm License: MIT Node.js

Features

  • Query clicks, impressions, CTR, and average position.

  • List and inspect Search Console properties.

  • List and inspect submitted sitemaps.

  • Inspect the indexed version of a URL.

  • Return both readable text and structured MCP output.

  • Restrict access to an explicit property allowlist.

  • Keep sitemap mutation tools disabled by default.

  • Authenticate with a service account or Google Application Default Credentials.

  • Install with npx; no global package installation is required.

Related MCP server: mcp-google-search-console-crunchtools

Requirements

  • Node.js 22.14 or newer.

  • A Google Cloud project with the Search Console API enabled.

  • A Google identity that has access to at least one Search Console property.

  • An MCP client such as Claude Code.

Quick start

1. Prepare Google credentials

For a service account:

  1. Enable the Google Search Console API in a Google Cloud project.

  2. Create a service account and download its JSON key.

  3. In Google Search Console, add the service account email under Settings → Users and permissions for each property it should access.

See Authentication for Application Default Credentials and detailed setup instructions.

2. Run the setup wizard

npx -y google-search-console-mcp setup

The wizard validates Google access, stores only the credential file path in the user configuration directory, and registers the MCP server with Claude Code at user scope.

Non-interactive setup is also supported:

npx -y google-search-console-mcp setup \
  --credentials /absolute/path/to/service-account.json \
  --allowed-sites sc-domain:example.com,https://www.example.com/ \
  --non-interactive

On Windows PowerShell, use one line or PowerShell backticks instead of backslashes.

3. Use it from Claude Code

Restart Claude Code after setup, then try:

List my Google Search Console properties.
Show clicks and impressions for the last 28 days, grouped by query.
Inspect https://www.example.com/article for indexing issues.
List the sitemaps submitted for sc-domain:example.com.

Run diagnostics at any time:

npx -y google-search-console-mcp doctor

Manual Claude Code registration

macOS and Linux:

claude mcp add google-search-console --scope user \
  --env GSC_CREDENTIALS_FILE=/absolute/path/to/service-account.json \
  -- npx -y google-search-console-mcp

Windows:

claude mcp add google-search-console --scope user --env GSC_CREDENTIALS_FILE=C:\path\to\service-account.json -- cmd /c npx -y google-search-console-mcp

See Client setup for project-level JSON configuration.

Tools

Tool

Default

Description

gsc_list_sites

Enabled

List accessible Search Console properties.

gsc_get_site

Enabled

Get permission information for one property.

gsc_query_search_analytics

Enabled

Query Search Analytics metrics and dimensions.

gsc_list_sitemaps

Enabled

List submitted sitemaps.

gsc_get_sitemap

Enabled

Get details about one sitemap.

gsc_inspect_url

Enabled

Inspect the version of a URL known to Google's index.

gsc_submit_sitemap

Opt-in

Submit a sitemap.

gsc_delete_sitemap

Opt-in

Remove a submitted sitemap.

URL Inspection does not run a live test and cannot request indexing. Google does not expose those actions through the Search Console API.

See the complete Tool reference.

Configuration

Variable

Default

Description

GSC_CREDENTIALS_FILE

ADC

Path to a service account JSON file.

GOOGLE_APPLICATION_CREDENTIALS

ADC

Standard Google credential file variable.

GSC_ALLOWED_SITES

All accessible

Comma-separated property allowlist.

GSC_ENABLE_WRITE_TOOLS

false

Register sitemap mutation tools.

GSC_REQUEST_TIMEOUT_MS

30000

Google API request timeout.

GSC_MAX_RETRIES

2

Retry count for transient failures.

GSC_MAX_ANALYTICS_ROWS

25000

Maximum rows returned by one analytics request.

GSC_LOG_LEVEL

info

silent, error, warn, info, or debug.

GSC_CONFIG_FILE

OS config directory

Override the setup-generated config path.

Environment variables take precedence over the stored user configuration. See Configuration.

Security defaults

  • Read-only Google scope unless write tools are enabled.

  • No credentials or API response data are written to logs.

  • Logs go to stderr so MCP stdio messages remain valid.

  • Write tools are absent from the tool list unless explicitly enabled.

  • Property access can be constrained with GSC_ALLOWED_SITES.

  • No telemetry.

Read Security model and Security policy before enabling write tools.

Development

git clone https://github.com/dienhokhanh/google-search-console-mcp.git
cd google-search-console-mcp
npm install
npm run check

Run the development server:

npm run dev

See Development and Contributing.

License

MIT

Available Tools

6 tools
gsc_get_siteGet a Search Console propertyB
Read-onlyIdempotent

Get permission information for one Google Search Console property.

Inputs: siteUrl (required).

gsc_get_sitemapGet a sitemapB
Read-onlyIdempotent

Get details about a submitted sitemap.

Inputs: siteUrl (required), sitemapUrl (required).

gsc_inspect_urlInspect a URLA
Read-onlyIdempotent

Inspect the version of a URL currently known to Google's index. This does not run a live test or request indexing.

Inputs: siteUrl (required), inspectionUrl (required), languageCode.

gsc_list_sitemapsList sitemapsC
Read-onlyIdempotent

List sitemaps submitted for a Google Search Console property.

Inputs: siteUrl (required), sitemapIndex.

gsc_list_sitesList Search Console propertiesA
Read-onlyIdempotent

List Google Search Console properties available to the configured identity.

Inputs: no named parameters.

gsc_query_search_analyticsQuery Search AnalyticsC
Read-onlyIdempotent

Query clicks, impressions, CTR, and average position from Google Search Console. Use startRow for pagination.

Inputs: endDate (required), siteUrl (required), startDate (required), type, +6 more.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.6/5.0

    Scored across 6 tools

    Disambiguation5/5

    Each tool targets a distinct resource and action: sites (list vs permission get), sitemaps (list vs detail get), URL inspection, and search analytics. The list/get pairs are clearly separated by their descriptions, and query_search_analytics and inspect_url have no overlap.

    Naming Consistency5/5

    All tools use a uniform gsc_ prefix followed by a consistent verb_noun pattern (list_sites, inspect_url, get_site, query_search_analytics, list_sitemaps, get_sitemap). No style mixing.

    Tool Count5/5

    Six tools is well-scoped for a Search Console read surface, covering properties, sitemaps, analytics, and URL inspection without redundancy. Each tool earns its place.

    Completeness4/5

    Core read operations (list/get sites, list/get sitemaps, analytics query, URL inspection) are covered. Notable gaps exist on the write side: no sitemap submission/deletion and no indexing request, which limits lifecycle coverage but is workable for a read-focused server.

    Maintenance

    ActivitySlowing
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      D
      maintenance
      Enables interaction with Google Search Console via MCP, offering search analytics, performance summaries, URL inspection, sitemap management, and property listing for SEO workflows.
      262 npm
      1
      MIT
    • A
      license
      A
      quality
      B
      maintenance
      Secure MCP server for Google Search Console. Query search analytics (clicks, impressions, CTR, position), manage sitemaps, inspect URL indexing status, and manage site properties.
      10
      AGPL 3.0
    • A
      license
      B
      quality
      B
      maintenance
      Enables Google Search Console data queries via MCP, including search analytics, performance comparisons, URL inspection, and sitemap management.
      12
      1
      MIT
    • A
      license
      A
      quality
      B
      maintenance
      Enables MCP clients to query Google Search Console search performance, inspect indexing, analyze sitemaps, and run SEO analyses such as cannibalisation detection, query clustering, and wins/losses, all with read-only access.
      20
      397 npm
      Apache 2.0