ScrapeGraph MCP Server
⭐ Star us on GitHub
If this server is helpful, a star goes a long way. Thanks!
Key Features
- Full v2 API coverage: scrape, extract, search, crawl (+ stop/resume), monitor lifecycle (+ activity polling), credits, history, and schema generation
- Uses the v2 API base URL (
https://api.scrapegraphai.com/api/v2) with theSGAI-APIKEYheader — wire format matches scrapegraph-py v2 - Remote HTTP MCP endpoint and local Python server support
- Works with Cursor, Claude Desktop, and any MCP‑compatible client
- Robust error handling, timeouts, and production‑tested reliability
Get Your API Key
Create an account and copy your API key from the ScrapeGraph Dashboard.Recommended: Use the Remote MCP Server
Endpoint:Cursor (HTTP MCP)
Add this to your Cursor MCP settings (~/.cursor/mcp.json):
Claude Desktop (via mcp-remote)
Claude Desktop connects to HTTP MCP via a lightweight proxy. Add the following to~/Library/Application Support/Claude/claude_desktop_config.json on macOS (adjust path on Windows):
Smithery (optional)
Local Usage (Python)
Prefer running locally? Install and wire the server via stdio.Install
Run the server
Configuration
The server reads the ScrapeGraph API key fromSGAI_API_KEY (local) or the X-API-Key header (remote). Environment variables align 1:1 with the Python SDK:
| Variable | Description | Default |
|---|---|---|
SGAI_API_KEY | ScrapeGraph API key | — |
SGAI_API_URL | Override the v2 API base URL | https://api.scrapegraphai.com/api/v2 |
SGAI_TIMEOUT | Request timeout in seconds | 120 |
SCRAPEGRAPH_API_BASE_URL | Legacy alias for SGAI_API_URL (still honored) | — |
SGAI_TIMEOUT_S | Legacy alias for SGAI_TIMEOUT (still honored) | — |
Available Tools
The server exposes the full v2 API surface.Content tools
All content tools accept the sameFetchConfig passthrough parameters: mode (auto | fast | js), stealth, timeout, wait, scrolls, country, headers, cookies, mock.
markdownify
Convert a webpage to clean markdown (wraps v2POST /scrape with a markdown format entry).
scrape
Fetch a URL via v2POST /scrape with a single format entry.
smartscraper
AI‑powered structured extraction (v2POST /extract).
searchscraper
Search the web and optionally extract structured results (v2POST /search).
generate_schema
Generate or augment a JSON Schema from a prompt (v2POST /schema).
Crawl tools
smartcrawler_initiate
Start a multi‑page crawl.extraction_mode defaults to markdown (also: html, links, images, summary, branding, screenshot).
smartcrawler_fetch_results
Poll status / results for a crawl.crawl_stop
Stop a running crawl.crawl_resume
Resume a paused / stopped crawl.Monitor tools
Replace v1 “scheduled jobs”.monitor_create wraps the supplied prompt (+ optional output_schema) into a v2 {type: "json", ...} format entry for you.
monitor_activity returns the tick history (id, createdAt, status, changed, elapsedMs, diffs) plus a nextCursor when more results are available — mirrors sgai.monitor.activity() in the SDKs.
Account tools
credits
Get the remaining credit balance.sgai_history
Browse paginated request history, optionally filtered by service.Troubleshooting
- Verify your key is present in config (
X-API-Keyfor remote,SGAI_API_KEYfor local). - Claude Desktop logs:
- macOS:
~/Library/Logs/Claude/ - Windows:
%APPDATA%\\Claude\\Logs\\
- macOS:
- If a long crawl is “still running”, keep polling
smartcrawler_fetch_results.