gsc-mcp
Searchlight is an autonomous technical SEO and analytics agent that detects, diagnoses, fixes, deploys, and verifies website issues using Google Search Console and Analytics data.
Authentication & Site Management
Authenticate with Google via browser OAuth; check auth status
List accessible Search Console properties (with permissions/aliases), switch active site, set a default site across sessions
Get an account-wide overview of clicks and impressions across all properties
Search Performance Analytics
Query clicks, impressions, CTR, and average position with flexible dimensions (query, page, country, device, date)
Quickly surface top queries and top pages
Find SEO opportunities: "striking distance" keywords (positions 5–20) and high-impression/low-CTR pages
Compare performance between periods to find biggest gainers and losers
URL Inspection & Indexing
Inspect individual URLs for index status, crawl date, canonical, mobile usability, and rich results
Generate a comprehensive page indexing coverage report across sitemaps and analytics URLs
Get deep links to GSC UI reports not exposed by the API (removals, manual actions, security issues, page indexing)
Sitemap Management
List submitted sitemaps with processing status and error counts
View detailed status for a specific sitemap
Submit or delete sitemaps (with write access)
Automated SEO Fixes & Progress Tracking
Automatically detect technical SEO issues, explain them in plain language, and fix them directly in your repository (canonicals, redirects, sitemaps, metadata, analytics tags)
Deploy changes and verify fixes are live
Snapshot site health over time and generate progress reports showing improvements, regressions, and traffic changes
Google Analytics Integration
List GA properties, retrieve measurement IDs, access traffic and top pages data, and provision GA4
Query search analytics, inspect URLs, manage sitemaps, switch between properties, and surface SEO opportunities from Google Search Console.
Planned integration to analyze page speed and performance data via the PageSpeed Insights API.
Click on "Deploy 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 show top queries for the last 7 days"
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.
Searchlight
Technical SEO that fixes itself.
An autonomous technical-SEO and analytics agent, delivered as a Model Context Protocol (MCP) server. Point it at your site: it finds what's broken, explains it in plain language, fixes it in your repository, deploys, and verifies the fix is live.
Website ·
The /searchlight skill ·
Quickstart ·
Tools
The loop
Most SEO tools stop at the diagnosis. Searchlight runs the whole loop and proves the last step.
Step | What it does |
Detect | Reads your Search Console and Analytics data, crawls key pages, finds indexing, canonical, redirect, sitemap, speed and on-page issues. |
Explain | Triages every finding in plain language with a worry-level: fix now, worth improving, or normal and safe to ignore. |
Fix | Edits your repository, framework-aware: canonical and host conflicts, redirect loops, sitemaps, metadata, structured data, the analytics tag. |
Deploy | Commits and ships through your existing pipeline. Edits only count once they are live. |
Verify | Re-audits the live site and confirms the fix in a real browser: the redirect resolves, the tag fires, the canonical agrees. |
Proof
A live run on zawaaj.in (a custom Next.js site with a host and canonical conflict and
missing analytics) went from audit 90 → 98 — canonical set, host redirect aligned
(www → apex), meta trimmed, GA4 installed and verified firing, sitemap submitted — in about
50 minutes (≈25 minutes active; the rest idle waiting on a redeploy), versus a 4–6 hour
manual baseline for a skilled developer. The full annotated run is on the
website.
Searchlight automates the diagnosis and the fix. It does not design your ecommerce event-tracking plan — that part is still a human's job.
Related MCP server: Google Search Console MCP Server
Quickstart
1. Add it to your MCP client (Claude Code shown; works in any MCP client):
claude mcp add searchlight -- npx -y @ajmalaksar/searchlight serve --setupOr, in a generic client config:
{
"mcpServers": {
"searchlight": { "command": "npx", "args": ["-y", "@ajmalaksar/searchlight", "serve"] }
}
}2. Sign in with Google (one local OAuth sign-in for Search Console and Analytics; the token is stored only on your machine):
npx -y @ajmalaksar/searchlight login --setup3. Install the /searchlight skill so your agent runs the whole loop with one command:
npx -y @ajmalaksar/searchlight skill install4. Ask:
/searchlight audit zawaaj.inFirst time on Google Cloud? The bundled client lets most users skip setup. To bring your own (Tier 0), create a Desktop app OAuth client (enable the Google Search Console API and PageSpeed Insights API, add yourself as a test user) and pass
SEARCHLIGHT_OAUTH_CLIENT_ID/SEARCHLIGHT_OAUTH_CLIENT_SECRETtologin.Renamed from
gsc-mcp: the legacy~/.gsc-mcpdirectory andGSC_*environment variables still resolve, so an existing install keeps working without re-authenticating.
The /searchlight skill
skill install drops a skill into your AI client so the agent orchestrates the full loop
instead of you calling raw tools. It routes on the first word:
Command | Does |
| Read-only diagnosis: detect + explain, triaged. No changes. |
| The full guided loop: interview → detect → confirm → provision → fix → deploy → verify. |
| Already audited? Go straight to plan → confirm → fix → deploy → verify. |
It always confirms before any provisioning, code edit, sitemap submit, or deploy.
Tools
auth_status, auth_login, list_sites, use_site, get_active_site, set_default_site,
account_overview, gsc_deep_link, query_search_analytics (presets: top_queries/top_pages),
find_opportunities, compare_periods, inspect_url, coverage_report, refresh_coverage,
crawl_site, site_audit, export_report, diagnose_site, audit_page, page_speed,
snapshot_baseline, list_snapshots, progress_report, ga_list_properties,
ga_measurement_id, ga_report (presets: traffic/top_pages), list_sitemaps.
With --write / --setup: submit_sitemap, delete_sitemap, and the GA4 / verification
provisioning tools.
crawl_site → site_audit → export_report crawl your live site directly (no Google
scope, no quota), then produce a triaged, site-wide technical-SEO report (status/redirects/
canonicals/orphans/link-graph/schema/hreflang) you can share as Markdown.
Coverage report reconstructs the "Page indexing" report the GSC API won't export in bulk:
it gathers candidate URLs from sitemaps and analytics, inspects them within the 2,000/day
per-property quota (resumable), caches the results under ~/.searchlight/sites/, and buckets
them by index status.
Baseline & progress (snapshot_baseline → … fix … → snapshot_baseline → progress_report)
freeze a site's health on a given day, then diff two days into a plain-English before→after of
what improved — which issues resolved, which are new, and how score and traffic moved.
Local-first & private
Searchlight runs as a local server. You sign in with your own Google account; the token is stored only on your device. There is no hosted backend and no data warehouse — each person runs their own. Read-only by default; write and provisioning scopes are opt-in, requested only when you start a setup action. Open source and MIT licensed. See the Privacy Policy.
CLI
searchlight login Sign in with Google (opens a browser)
searchlight logout Remove the stored token
searchlight status Authentication + onboarding status
searchlight setup Guided first-run
searchlight sites … Manage the property registry (list / add / remove / default)
searchlight skill install Install the /searchlight skill into your AI client (--here for this project)
searchlight serve Start the MCP server over stdio (default)Develop
npm install
npm run build
npm testThe server is a tool registry. To add a capability, create src/tools/<group>.ts exporting
register: ToolModule, then add it to MODULES in src/tools/index.ts. See SPEC.md
for the architecture.
License
MIT © Ajmal Aksar
Available Tools
16 toolsaccount_overviewAccount overview (all sites)B
Portfolio view across every accessible property: last-28-day clicks and impressions per site, ranked. (Per-site SEO/coverage scores are added in a later phase.)
Inputs: days.
auth_loginLog in to Google Search ConsoleA
Sign in to Google in the browser, right from here — no terminal needed. Opens the consent screen, captures the token on a localhost callback, and stores it. Use when auth_status says needs_login.
Inputs: no named parameters.
auth_statusAuth statusA
Check whether the server is authenticated to Google Search Console, which scope is active, and where you are in onboarding (setupState). Call this first if other tools report an auth error.
Inputs: no named parameters.
compare_periodsCompare periodsA
Compare the most recent N days against the preceding N days. Returns total clicks/impressions deltas plus the biggest gainers and losers for the chosen dimension.
Inputs: days, limit, siteUrl, dimension.
find_opportunitiesFind SEO opportunitiesA
Surface actionable wins: 'striking distance' rows ranked between positions 5-20 (small gains can push them to page one) and high-impression / low-CTR rows (the listing shows but few click). Returns a ranked, deduped list with a reason for each.
Inputs: days, limit, siteUrl, dimension, +1 more.
get_active_siteGet active siteA
Report which property tool calls currently target, and whether it came from the session, the default, or none.
Inputs: no named parameters.
get_sitemapGet sitemapA
Get detailed status for a single sitemap by its full feed URL.
Inputs: feedpath (required), siteUrl.
gsc_deep_linkDeep link to Search Console UIA
Return the exact Search Console UI URL for a report the API does not expose (removals, manual actions, security issues, page-indexing). Hand this to the user to act on.
Inputs: report (required), siteUrl.
inspect_urlInspect URLA
Run the URL Inspection tool on a single URL: index status, coverage, last crawl, canonical, mobile usability and rich-results state. Use this to diagnose why a page is or is not indexed. Subject to a 2,000/day per-property quota.
Inputs: inspectionUrl (required), siteUrl, languageCode.
list_sitemapsList sitemapsA
List all sitemaps submitted for a property, with processing status and error/warning counts.
Inputs: siteUrl.
list_sitesList sitesA
List every Search Console property the signed-in user can access, with permission level, any registered alias, and which property is currently active / default.
Inputs: no named parameters.
query_search_analyticsQuery search analyticsA
The core Search Console performance query. Returns clicks, impressions, CTR and average position, broken down by the dimensions you request, over a date range. Use top_queries / top_pages for quick cases.
Inputs: type, endDate, siteUrl, rowLimit, +6 more.
set_default_siteSet default siteA
Persist the default property to config.json (survives restarts). Used when a call omits siteUrl and no session site is set. Accepts a property URL or alias.
Inputs: site (required).
top_pagesTop pagesB
Quick view of the top landing pages for a site over the last N days, ranked by clicks.
Inputs: days, limit, siteUrl.
top_queriesTop queriesC
Quick view of the top search queries for a site over the last N days, ranked by clicks.
Inputs: days, limit, siteUrl.
use_siteSwitch active siteA
Set the active property for this session, so later tool calls can omit siteUrl. Accepts a property URL or a registered alias (e.g. "blog"). The primary way to switch context.
Inputs: site (required).
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 16 tools
Each tool targets a distinct GSC operation: authentication, site selection, analytics queries, sitemaps, URL inspection, and comparative analysis. Even similar analytics tools like top_queries, compare_periods, and find_opportunities have clear differentiating descriptions (quick view vs. comparative vs. actionable wins). No two tools overlap in purpose.
Tools follow a consistent 'verb_noun' or 'category_action' pattern in lowercase with underscores (e.g., auth_login, list_sitemaps, top_queries). Minor deviations include 'gsc_deep_link' (prefix with noun) and 'account_overview' (noun_verb), but overall the pattern is predictable and readable.
With 16 tools, the server covers the full spectrum of Google Search Console operations—authentication, site management, analytics, sitemaps, URL inspection, and deep links—without being bloated. Each tool serves a clear purpose, and the count is well-scoped for a specialized API wrapper.
The tool set covers core GSC workflows: authentication, site selection, search analytics (queries, pages, comparisons, opportunities), sitemap status, and URL inspection. Minor gaps include the lack of property addition/removal and live URL testing, but these are secondary. The planned addition of per-site SEO/coverage scores suggests recognized missing functionality.
Maintenance
Related MCP Connectors
Turn Search Console data into SEO actions, content, publishing, indexing, and AI insights.
Query your SEO data in plain language: rankings, audits, backlinks, competitors and AI visibility.
AI SEO agent on your Google Search Console data: audits, quick wins, content, WordPress publishing.
SEO, GEO & AI Visibility Intelligence directly inside AI assistants. Chat with SEO in plain language: research keywords, analyze SERPs, track competitors, and monitor AI visibility. SeoPerseo's integrated intelligence reveals site issues and how to fix them, create client reports and generate content for your website. Fully integrated with Google Search Console and Google Analytics.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables querying Google Search Console and Google Analytics 4 through natural language, with tools for SEO analysis like anomaly detection, cannibalization detection, and opportunity scoring.16 npm1MIT
- AlicenseNot gradedqualityDmaintenanceEnables querying Google Search Console data, including search analytics with advanced filtering, quick wins detection, and rich dimensions, through natural language.9,024 npmMIT
- AlicenseNot gradedqualityDmaintenanceConnects Google Search Console to AI assistants, enabling SEO data analysis via natural language conversations.MIT
- AlicenseAqualityDmaintenanceConnects Google Search Console to AI assistants, enabling natural language queries for SEO data, indexing audits, sitemap management, and full site audits.20MIT