How to connect Ahrefs MCP to Claude Desktop
Add this block to ~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows), then restart Claude Desktop. Cursor and Codex use a similar schema.
{
"mcpServers": {
"ahrefs": {
"command": "npx",
"args": ["-y", "<server-package-name>"],
"env": {
"AHREFS_API_KEY": "your-api-key-here"
}
}
}
}
// Server source: https://ahrefs.com/mcp/
// Check the server's README for the exact "command" and required env vars.Some MCP servers require an API key. Check the source page for setup: ahrefs.com/mcp.
Does Ahrefs MCP cost extra?
Ahrefs ships an official MCP server that uses your existing subscription credentials.
- No separate MCP licence to buy. You pay for your Ahrefs plan, the MCP server queries that account.
- Whether it's gated to a specific tier wasn't extracted automatically — verify the access requirements on the MCP page or pricing docs.
Ahrefs subscription pricing
| Plan | Monthly | Annual / mo |
|---|---|---|
| Starter | $29 | $29 |
| Lite | $129 | $108 |
| Standard | $249 | $208 |
| Advanced | $449 | $374 |
| Enterprise | Contact sales | — |
Source: ahrefs.com/pricing. Scraped 2026-05-19.
Ahrefs also publishes a REST API
Ahrefs API is a separate product with its own tier ladder, billed on top of your Ahrefs subscription.
See Ahrefs API pageWhat you can do with Ahrefs from an AI agent
Three shapes of agent workflow. Pick the row that matches how you actually use Claude / Cursor / Codex day to day.
Skip the dashboard, ask Claude
- "What keywords moved this week?" answered in seconds
- Quick one-off questions without leaving the editor
- Pipe Ahrefs data into your personal notes / docs without writing a script
Run client analysis at agent speed
- Hand the MCP server to your team — every consultant can ask Claude about any client's Ahrefs account
- Multi-account workflows without context-switching the Ahrefs UI
- Reports you'd normally spend hours on, done before standup
Production agent workflows
- Embed in your internal Codex / Cursor agents that triage Ahrefs data daily
- Combine with other MCP servers in a multi-step agent chain
- Constrain agents to read-only roles to keep production Ahrefs safe
Limits and gotchas
- Official MCP server — published by Ahrefs themselves, so it should track product changes.
- Fallback: the REST API works for any flow the MCP server doesn't cover.
- Auth flow: MCP servers usually inherit the underlying API auth method (both). Expect to configure that on first install.
- Rate limits: MCP calls count against your underlying Ahrefs API quota. Burst usage from a curious agent can drain a daily allowance fast.
Agent-readiness verdict
Solid agent integration with official MCP support and documented API access across Claude and ChatGPT. The official MCP server and public API docs make it straightforward to wire into agentic workflows, though lack of structured outputs and webhooks limits real-time automation possibilities.
Scored 2026-05-19 by Joonas (TMB).
Ahrefs MCP & API FAQ
Is the Ahrefs MCP server official?+
Can I use the Ahrefs MCP with Cursor or Codex?+
Does Ahrefs have a public API?+
Which LLMs does Ahrefs integrate with directly?+
Sources
- Ahrefs official site: https://ahrefs.com/
- MCP server page: https://ahrefs.com/mcp/
- API docs: https://docs.ahrefs.com/
- Pricing source: https://ahrefs.com/pricing (scraped 2026-05-19)
Data verified by Joonas on the dates shown. MCP server status auto-rechecked weekly.

