Token-optimized SEO MCP server for AI agents β SERP analysis, keyword research, backlink audits & competitive intelligence via DataForSEO
npm install mcp-marketers
Token-optimized SEO tools for AI agents. 19 tools. One MCP server. Zero context window waste.
---
Get Started •
Why Marketers MCP •
Tools •
Configuration •
Examples
---
Your AI spends half its context window on raw API responses it can barely parse. marketers-mcp fixes this. 19 SEO tools powered by DataForSEO, each returning token-optimized previews (300-500 tokens) with download URLs for the full dataset. Ask your AI to research keywords, audit backlinks, or spy on competitors β it queries DataForSEO directly and gives you actionable insights without drowning in data.
π KeywordsSeed keywords β goldmine of opportunities. Volume, difficulty, CPC, trends β all in one call. | π BacklinksFull backlink profile analysis. Referring domains, anchor text, new/lost links, competitor comparisons. | π SERP AnalysisSERP features, ranking positions, content analysis. See what Google actually shows users. | π’ Competitor IntelFind competitors, compare domains head-to-head, discover gaps in your strategy. |
``
You: "Find keywords related to 'email marketing' with volume > 1000"
ββββββββββββββββ ββββββββββββββββββββ ββββββββββββββββββ
β AI Agent β ββββ β marketers-mcp β ββββ β DataForSEO β
β (Claude) β β MCP Server β β API β
ββββββββββββββββ ββββββββββββββββββββ ββββββββββββββββββ
AI receives (300-500 tokens):
{
"summary": "Found 247 keywords for 'email marketing'. Top: 'email marketing tools' (14,800/mo)",
"preview": [ ...top 10 keywords with volume, difficulty, CPC... ],
"stats": { "totalRows": 247, "avgVolume": 3200 },
"downloadUrl": "https://r2.example.com/full-dataset.json?presigned...",
"nextSteps": ["analyze_keywords for difficulty deep-dive", "analyze_serp for ranking intent"]
}
Full dataset (247 rows) available via download URL β AI never chokes on data.
`
---
| β Without Marketers MCP | β With Marketers MCP |
|---|---|
1. Open SEMrush, Ahrefs, or Moz | 1. Ask your AI about any SEO topic |
---
> Note: This package is not yet published to npm. You must clone and build locally.
`bash`
git clone https://github.com/yigitkonur/mcp-marketers.git
cd mcp-marketers
npm install
npm run build
Sign up at dataforseo.com and grab your API login and password from the dashboard.
Add this to your Claude Desktop config file:
macOS: ~/Library/Application Support/Claude/claude_desktop_config.json%APPDATA%\Claude\claude_desktop_config.json
Windows: ~/.config/Claude/claude_desktop_config.json
Linux:
`json`
{
"mcpServers": {
"seo": {
"command": "node",
"args": ["/absolute/path/to/mcp-marketers/build/index.js"],
"env": {
"DATAFORSEO_USERNAME": "your_username",
"DATAFORSEO_PASSWORD": "your_password",
"R2_ACCOUNT_ID": "optional_r2_account_id",
"R2_ACCESS_KEY_ID": "optional_r2_access_key",
"R2_SECRET_ACCESS_KEY": "optional_r2_secret",
"R2_BUCKET": "optional_r2_bucket"
}
}
}
}
Restart Claude Desktop after saving the config.
`bash`
claude mcp add seo \
-e DATAFORSEO_USERNAME=your_username \
-e DATAFORSEO_PASSWORD=your_password \
-- node /absolute/path/to/mcp-marketers/build/index.js
Add to your .cursor/mcp.json or Windsurf MCP config:
`json`
{
"mcpServers": {
"seo": {
"command": "node",
"args": ["/absolute/path/to/mcp-marketers/build/index.js"],
"env": {
"DATAFORSEO_USERNAME": "your_username",
"DATAFORSEO_PASSWORD": "your_password"
}
}
}
}
---
Marketers MCP supports three transport modes:
| Mode | Use Case | How to Start |
|------|----------|-------------|
| STDIO (default) | Claude Desktop, Cursor, Windsurf | npx mcp-marketers |MCP_TRANSPORT=http npx mcp-marketers
| HTTP Streamable | Self-hosted, Docker, LAN sharing | |
| Cloudflare Workers | Serverless, globally distributed | Already deployed β |
A remote MCP endpoint is deployed and ready to use:
``
https://mcp-marketers.seodoold.workers.dev/mcp
Connect from any MCP client that supports HTTP Streamable transport:
`json`
{
"mcpServers": {
"marketers-remote": {
"type": "streamable-http",
"url": "https://mcp-marketers.seodoold.workers.dev/mcp"
}
}
}
`bashStart on default port 3001
MCP_TRANSPORT=http npx mcp-marketers
`json
{
"mcpServers": {
"marketers-http": {
"type": "streamable-http",
"url": "http://localhost:3001/mcp"
}
}
}
`---
Tool Reference
π
Keywords
research analyze compare
π
Domains
analyze competitors compare
π
Backlinks
analyze compare monitor
π
SERP & Content
serp content suggestions
π’
Business
analyze find
π±
App
analyze
βοΈ
Utilities
locations categories languages download
$3
| # | Tool | Category | Description |
|---|------|----------|-------------|
| 1 |
research_keywords | Keywords | Discover keyword ideas from seed keywords across multiple data sources |
| 2 | analyze_keywords | Keywords | Get detailed metrics β difficulty, volume, CPC, trends β for specific keywords |
| 3 | compare_keywords | Keywords | Side-by-side keyword comparison with relative metrics |
| 4 | analyze_domain | Domains | Full domain SEO overview β traffic, top pages, organic keywords |
| 5 | analyze_competitors | Domains | Discover competing domains and their overlap with yours |
| 6 | compare_domains | Domains | Head-to-head comparison of 2-5 domains on key SEO metrics |
| 7 | analyze_backlinks | Backlinks | Backlink profile analysis β referring domains, anchors, link types |
| 8 | compare_backlinks | Backlinks | Compare backlink profiles between domains |
| 9 | monitor_backlinks | Backlinks | Track new and lost backlinks over time |
| 10 | analyze_serp | SERP & Content | SERP feature analysis β featured snippets, PAA, local packs, rankings |
| 11 | analyze_content | SERP & Content | Content analysis for target keywords β word count, readability, topics |
| 12 | get_suggestions | SERP & Content | Autocomplete and related search suggestions |
| 13 | analyze_business | Business | Business listing data β reviews, ratings, hours, contact info |
| 14 | find_businesses | Business | Search businesses by category, location, and keyword |
| 15 | analyze_app | App | App Store and Google Play metrics β ratings, reviews, rankings |
| 16 | get_locations | Utilities | List all available target locations with codes |
| 17 | get_categories | Utilities | Browse business and content categories |
| 18 | get_languages | Utilities | List supported languages with codes |
| 19 | download_data | Utilities | Retrieve full datasets from R2 presigned URLs |---
π Keywords Tools β research, analyze, compare
####
research_keywords
Discover keyword ideas from seed keywords using multiple discovery methods. Supports Google, Bing, and Clickstream data sources.`json
research_keywords({
"keywords": ["seo tools"],
"dataType": "suggestions",
"minVolume": 1000,
"location": "United States"
})
`####
analyze_keywords
Get detailed keyword metrics including difficulty scores, search volume, CPC, competition, and historical trends.`json
analyze_keywords({
"keywords": ["email marketing", "content marketing"],
"location": "United States"
})
`####
compare_keywords
Compare keywords side-by-side on volume, difficulty, CPC, and trend data for prioritization.`json
compare_keywords({
"keywords": ["react vs vue", "angular vs svelte"],
"location": "United States"
})
`
π Domains Tools β analyze, competitors, compare
####
analyze_domain
Full domain SEO overview including organic traffic estimates, top ranking pages, keyword distribution, and technology stack.`json
analyze_domain({
"domain": "example.com",
"location": "United States"
})
`####
analyze_competitors
Discover which domains compete with yours for the same organic keywords and traffic.`json
analyze_competitors({
"domain": "example.com",
"location": "United States"
})
`####
compare_domains
Head-to-head comparison of 2-5 domains on traffic, keyword overlap, backlink strength, and domain authority.`json
compare_domains({
"domains": ["site-a.com", "site-b.com", "site-c.com"],
"location": "United States"
})
`
π Backlinks Tools β analyze, compare, monitor
####
analyze_backlinks
Comprehensive backlink profile analysis β referring domains, anchor text distribution, dofollow/nofollow ratio, link types.`json
analyze_backlinks({
"target": "example.com",
"sortBy": "rank",
"limit": 100
})
`####
compare_backlinks
Compare backlink profiles between two or more domains to find link-building opportunities.`json
compare_backlinks({
"targets": ["site-a.com", "site-b.com"]
})
`####
monitor_backlinks
Track newly acquired and recently lost backlinks for any domain.`json
monitor_backlinks({
"target": "example.com",
"mode": "new"
})
`
π SERP & Content Tools β serp, content, suggestions
####
analyze_serp
Analyze SERP features for a keyword β featured snippets, People Also Ask, local packs, knowledge panels, and organic rankings.`json
analyze_serp({
"keyword": "best crm software",
"location": "United States"
})
`####
analyze_content
Content analysis for target keywords β typical word count, readability scores, topic coverage among top-ranking pages.`json
analyze_content({
"keyword": "how to start a blog",
"location": "United States"
})
`####
get_suggestions
Get autocomplete suggestions and related searches from Google, Bing, and YouTube.`json
get_suggestions({
"keyword": "email marketing",
"source": "google"
})
`
π’ Business Tools β analyze, find
####
analyze_business
Retrieve business listing data including reviews, ratings, hours, photos, and contact information from Google, Trustpilot, TripAdvisor, and more.`json
analyze_business({
"keyword": "best coffee shop",
"location": "New York, United States",
"source": "google"
})
`####
find_businesses
Search and discover businesses by category, keyword, and geographic location.`json
find_businesses({
"keyword": "plumber",
"location": "San Francisco, United States"
})
`
π± App Tools β analyze
####
analyze_app
Get App Store and Google Play data β ratings, reviews, rankings, category position, and competitor apps.`json
analyze_app({
"appId": "com.example.app",
"store": "google_play",
"location": "United States"
})
`
βοΈ Utility Tools β locations, categories, languages, download
####
get_locations
List all available target locations with their location codes for use in other tools.`json
get_locations({ "query": "united" })
`####
get_categories
Browse available business and content categories with their category codes.`json
get_categories({ "query": "marketing" })
`####
get_languages
List all supported languages with their language codes.`json
get_languages({})
`####
download_data
Retrieve a full dataset from a presigned R2 download URL returned by any other tool.`json
download_data({ "url": "https://r2.example.com/data.json?presigned..." })
`---
$3
Every tool returns a PreviewResponse β a token-optimized envelope designed for AI consumption:
`json
{
"summary": "Found 150 keywords for 'seo tools'. Top: 'best seo tools' (12,100 searches/mo, KD 67)",
"preview": [
{
"keyword": "best seo tools",
"volume": 12100,
"difficulty": 67,
"cpc": 8.50
},
{
"keyword": "free seo tools",
"volume": 8400,
"difficulty": 42,
"cpc": 3.20
}
],
"stats": {
"totalRows": 150,
"avgVolume": 2500,
"avgDifficulty": 45
},
"downloadUrl": "https://r2.example.com/data.json?presigned...",
"appliedFilters": {
"sortBy": "volume",
"order": "desc",
"location": "United States"
},
"nextSteps": [
{
"description": "Get difficulty deep-dive for top keywords",
"toolCall": "analyze_keywords({ keywords: [\"best seo tools\", \"free seo tools\"] })"
},
{
"description": "Check SERP features for top keyword",
"toolCall": "analyze_serp({ keyword: \"best seo tools\" })"
}
]
}
`| Field | Tokens | Purpose |
|-------|--------|---------|
|
summary | ~50 | One-line actionable insight |
| preview | ~200-400 | Top 5-10 representative rows for quick decisions |
| stats | ~30 | Dataset-level aggregates |
| downloadUrl | ~50 | Presigned R2 URL for the full dataset (all rows) |
| appliedFilters | ~30 | What filters/sorting were applied |
| nextSteps | ~50 | Suggested follow-up tool calls |---
Environment Variables
| Variable | Required | Default | Description |
|----------|----------|---------|-------------|
|
DATAFORSEO_USERNAME | Yes | β | Your DataForSEO API username |
| DATAFORSEO_PASSWORD | Yes | β | Your DataForSEO API password |
| R2_ACCOUNT_ID | No | β | Cloudflare R2 account ID (enables full dataset downloads) |
| R2_ACCESS_KEY_ID | No | β | R2 access key ID |
| R2_SECRET_ACCESS_KEY | No | β | R2 secret access key |
| R2_BUCKET | No | β | R2 bucket name for dataset storage |
| HEALTH_PORT | No | 8080 | Port for health check and metrics HTTP server |
| DISABLE_HEALTH_SERVER | No | β | Set to true to disable the health/metrics HTTP server |
| LOG_LEVEL | No | info | Log level: debug, info, warn, error |> Tip: Without R2 configured, tools still work β you just won't get
downloadUrl for full datasets. Previews always work.---
Recommended Workflows
$3
Ask your AI to run a complete SEO audit in one conversation:
`
1. "Analyze the domain example.com"
β analyze_domain β traffic overview, top pages, keyword distribution2. "How's their backlink profile?"
β analyze_backlinks β referring domains, anchor distribution, link quality
3. "Who are their main competitors?"
β analyze_competitors β competing domains ranked by keyword overlap
4. "Compare their backlinks with the top competitor"
β compare_backlinks β side-by-side link profile comparison
5. "Find keyword gaps between us and the top competitor"
β compare_domains β keywords they rank for that you don't
`$3
`
1. "Find competitors for my domain example.com"
β analyze_competitors β list of competing domains2. "Compare my domain with the top 3 competitors"
β compare_domains β traffic, keywords, authority comparison
3. "What keywords does competitor.com rank for that I don't?"
β research_keywords({ keywords: ["competitor.com"], dataType: "for_site" })
4. "Analyze the SERP for their top keyword"
β analyze_serp β SERP features, ranking positions, content requirements
`$3
`
1. "Research keywords for 'project management software'"
β research_keywords β 200+ keyword ideas with volume and difficulty2. "Analyze difficulty for the top 10 keywords"
β analyze_keywords β difficulty scores, SERP competition, trends
3. "What does the SERP look like for 'best project management tools'?"
β analyze_serp β featured snippets, PAA questions, top results
4. "Analyze the content of top-ranking pages for that keyword"
β analyze_content β word count, topics covered, readability benchmarks
5. "Get autocomplete suggestions for content angles"
β get_suggestions β related queries and long-tail variations
`---
Development
`bash
Clone the repository
git clone https://github.com/yigitkonur/mcp-marketers.git
cd mcp-marketersInstall dependencies (runs postinstall patches automatically)
npm installBuild TypeScript
npm run buildRun all unit tests (336 tests)
npm testRun a specific test
npm test -- -t "analyze_backlinks"Lint
npm run lintValidate SDK-only boundary (no direct HTTP calls)
npm run validate:sdk-onlyDev mode with auto-reload
npm run devTest with MCP Inspector
npx @modelcontextprotocol/inspector \
-e DATAFORSEO_USERNAME=xxx -e DATAFORSEO_PASSWORD=xxx \
--cli node build/index.js --method tools/list
`$3
`
src/
βββ index.ts # Entry point β registers tools + middleware pipeline
βββ mcp/
β βββ tools/ # 19 tool handlers (research-keywords, analyze-*, etc.)
β βββ middleware/ # compose β errorBoundary β rateLimit β timeout β circuitBreaker
β βββ response/ # ResponseBuilder (preview, stats, nextSteps)
β βββ client/ # DataForSEO SDK wrapper (all API calls go through here)
βββ services/ # Business logic layer
βββ data/
β βββ dataforseo/ # SDK client initialization
β βββ cache/ # In-memory cache with TTL
βββ utils/
β βββ storage/ # R2 client for full dataset uploads/downloads
β βββ tokens/ # Token counting and response compression
βββ health/ # Health checks and graceful shutdown
βββ observability/ # Structured logging, metrics, tracing
`---
Troubleshooting
DataForSEO credentials not working
- Verify your username and password at app.dataforseo.com
- Make sure
DATAFORSEO_USERNAME and DATAFORSEO_PASSWORD are set in the env block of your MCP config
- Credentials are the API login/password from the DataForSEO dashboard, not your account email
- Check that your DataForSEO account has an active balance β most endpoints cost credits per request
R2 download URLs not working / no downloadUrl in response
- R2 is optional β tools work without it, you just won't get full dataset download URLs
- If you want download URLs, set all four R2 environment variables:
R2_ACCOUNT_ID, R2_ACCESS_KEY_ID, R2_SECRET_ACCESS_KEY, R2_BUCKET
- Make sure your R2 bucket exists and the access key has read/write permissions
- Presigned URLs expire after a set period β if a URL stops working, re-run the tool
Token limits / large responses
- Marketers MCP is designed to avoid this β preview responses are 300-500 tokens
- If you're seeing large responses, check that
tokenBudget is configured in the tool definition
- The downloadUrl field provides access to the full dataset without consuming context window
- Use download_data tool to retrieve specific datasets when the AI needs full data
Build or install errors
- Requires Node.js 18 or higher: check with
node --version
- The postinstall script patches the DataForSEO SDK β if it fails, run npm run patch:dataforseo-client && npm run patch:sdk-missing-methods manually
- If TypeScript build fails, ensure you have npm install completed successfully first
- Delete node_modules and package-lock.json then run npm install for a clean start
Tool not found / "Unknown tool" error
- Restart Claude Desktop after modifying
claude_desktop_config.json
- Verify the args path in your config points to the built file: /path/to/mcp-marketers/build/index.js
- Run npm run build if you haven't built yet β the build/ directory must exist
- Test with MCP Inspector to verify tools are loading: npx @modelcontextprotocol/inspector --cli node build/index.js --method tools/list
Health server port conflict
- The health server defaults to port 8080 β if that's in use, set
HEALTH_PORT to another port
- Set DISABLE_HEALTH_SERVER=true` to skip the health server entirely---
License
MIT © Yigit Konur
Built with Model Context Protocol and DataForSEO