GSC MCP Server
Provides tools to query search analytics, inspect URLs, manage sitemaps, and compare performance across time periods using the Google Search Console API.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@GSC MCP ServerWhat are the top queries for my site this month?"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
GSC MCP Server
A Model Context Protocol (MCP) server that connects Claude Desktop (and other MCP clients) to the Google Search Console API — query search analytics, inspect URLs, manage sitemaps, and compare performance across time periods.
Based on MCP-GSC by Amin Foroutan, with enhancements for lazy imports, data state control, multi-filter support, and additional tools.
Features
20 Search Console Tools
Search Analytics:
Tool | Description |
| List all GSC properties accessible by the authenticated account |
| Search analytics with dimensions (query, page, device, country, date) |
| Advanced analytics with sorting, filtering, pagination (up to 25K rows) |
| Performance summary with daily trend data |
| Queries driving traffic to a specific page |
| Compare two time periods side-by-side with percentage changes |
URL Inspection:
Tool | Description |
| Full URL inspection — indexing status, rich results, canonical info |
| Inspect up to 10 URLs in one call |
| Categorized indexing issue report across multiple URLs |
Sitemap Management:
Tool | Description |
| List sitemaps with status and URL counts |
| Detailed sitemap listing with submission dates and warnings |
| Full details for a specific sitemap |
| Submit or resubmit a sitemap |
| Remove a sitemap from GSC |
| All-in-one sitemap management (list, details, submit, delete) |
Property Management:
Tool | Description |
| Add a site to Search Console |
| Remove a site from Search Console |
| Property details including verification and ownership info |
| Switch Google accounts via OAuth re-login |
Built-in Reliability
Dual auth — OAuth (interactive) and service account (headless) with automatic fallback
Lazy imports — defers heavy Google client libraries for fast MCP handshake
Data state control — choose between fresh data (
all, matches GSC dashboard) or confirmed data (final)Multi-filter support — AND logic across dimensions via JSON filter arrays
Related MCP server: GSC MCP Server
Quick Start
Prerequisites
Python 3.10+
A Google Cloud project with the Search Console API enabled
Claude Desktop (or any MCP-compatible client)
Authentication Options
Option A: Service Account (Headless — recommended for servers)
Create a Google Cloud service account
Enable the Search Console API in your project
Download the service account JSON key file
In GSC: go to Settings > Users and permissions and add the service account email as a user
Option B: OAuth (Interactive — recommended for local use)
Create OAuth credentials in Google Cloud Console
Download the client secrets JSON as
client_secrets.jsonPlace it in the
gsc-mcp/directoryOn first run, a browser window opens for Google login
Installation
git clone https://github.com/luminarylane/gsc-mcp.git
cd gsc-mcp
pip install -r requirements.txtConfiguration
Claude Desktop (claude_desktop_config.json):
{
"mcpServers": {
"gsc": {
"command": "python",
"args": ["/path/to/gsc-mcp/gsc_server.py"],
"env": {
"GSC_CREDENTIALS_PATH": "/path/to/service_account_credentials.json"
}
}
}
}Environment variables:
Variable | Required | Description |
| No* | Path to service account JSON key file |
| No* | Path to OAuth client secrets JSON |
| No | Set to |
| No |
|
*At least one authentication method must be configured.
Alternatively, place service_account_credentials.json or client_secrets.json in the gsc-mcp/ directory.
Usage Examples
Once configured, ask Claude to:
"List my Search Console properties"
"What are the top queries for my site this month?"
"Show me the top pages by clicks for the last 90 days"
"Is this URL indexed? Check https://example.com/my-page"
"Compare search performance: last 28 days vs the 28 days before"
"Check indexing issues for these URLs" (paste a list)
"Submit my sitemap at https://example.com/sitemap.xml"
"Show traffic sources by country and device"
Data Freshness
By default, the server uses dataState: "all" which includes fresh/unconfirmed data and matches the GSC dashboard. Set GSC_DATA_STATE=final for confirmed-only data (lags 2-3 days). You can also override per-call via the data_state parameter in get_advanced_search_analytics.
Troubleshooting
Property not found (404)
The site_url must exactly match what GSC shows. Run list_properties first. Domain properties use the format sc-domain:example.com, not a full URL.
Permission denied (403)
The authenticated account needs access to the property. For service accounts, add the email in GSC Settings > Users and permissions.
Authentication failed
Service account: Check
GSC_CREDENTIALS_PATHpoints to a valid JSON key fileOAuth: Delete
token.jsonand re-run to trigger a fresh login, or use thereauthenticatetool
Contributing
Fork the repo
Create a feature branch (
git checkout -b feat/my-feature)Make changes and test locally
Submit a pull request
License
MIT License — see LICENSE for details.
Acknowledgments
Amin Foroutan for the original MCP-GSC tool
Anthropic for the MCP specification
Google Search Console API for the underlying API
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Latest Blog Posts
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/luminarylane/gsc-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server