Ahrefs MCP: set up Ahrefs' official server
Ahrefs MCP connects your agent to Ahrefs' data: keywords, backlinks, competitors, rank tracking and site audits. This guide covers the plans that include it, setup in Claude, Claude Code, ChatGPT and Cursor, how units are spent, and the fixes for common errors.

How do I connect Ahrefs to Claude?
This guide covers Ahrefs' official MCP server: which Ahrefs plans include it, how to connect it in Claude, Claude Code, ChatGPT and Cursor, the problems people hit with API units and authentication, and example prompts.
What is Ahrefs MCP?
Ahrefs MCP is the bridge between your agent and the Ahrefs API. You ask a question in plain language, and the agent picks the Ahrefs tools to call. Ahrefs hosts it at https://api.ahrefs.com/mcp/mcp. When you connect, you approve access on an Ahrefs consent screen, and Ahrefs creates a dedicated API key tagged with MCP scope.
Ahrefs groups the tools by product in its tool categories documentation, including:
- Site Explorer: domain rating, backlink stats, organic and paid overviews, backlinks, referring domains, anchors, organic keywords, competitors and top pages
- Keywords Explorer: keyword overviews, volume by country and history, matching and related terms
- SERP overview for a keyword
- Rank Tracker overview and competitor reports
- Site Audit projects, issues and pages
- Brand Radar reports on how brands appear in AI answers
- Web Analytics, Google Search Console data, social media metrics and batch analysis of several targets at once
Ahrefs says its data comes from its own web index.
Who Ahrefs MCP is for
Ahrefs MCP fits when:
- You already pay for Ahrefs Lite or higher and want that data in conversation with your agent
- Your team uses Ahrefs daily and wants the same metrics in the app and in your agent
- You are comfortable watching your API unit balance and rows per request
It may not fit when:
- You do not have a paid Ahrefs plan and do not want to start one just for MCP
- You need more than about 4,000 calls a month on Lite, the most its 200,000 units allow at 50 units a call
- Your team pays for Semrush rather than Ahrefs: Semrush's own server is covered in our Semrush MCP guide
- You only need SEO data now and then
Which Ahrefs plans include MCP
Ahrefs MCP is available on Lite, Standard, Advanced and Enterprise. According to Ahrefs' help center, the plans include:
| Plan | API units per month | Max rows per request |
|---|---|---|
| Lite | 200,000 | 100 |
| Standard | 800,000 | 250 |
| Advanced | 2,000,000 | 500 |
| Enterprise | Custom | Unlimited |
In October 2026, Ahrefs' US pricing page listed Lite at $129/mo, Standard at $249/mo and Advanced at $449/mo, billed monthly. There is no extra fee for the MCP server itself, but each call costs at least 50 API units, with the exact amount depending on the request. The units are shared with your other Ahrefs API use, including direct API v3 calls. To get more, upgrade your plan; Enterprise customers can buy extra units.
Track your usage in Account settings → Limits and usage. Workspace admins can also set a monthly unit limit for each key in the API keys report.
How to connect Ahrefs MCP to Claude
Ahrefs is in Claude's list of approved connectors:
- In Claude, open Customize, select Connectors and click +
- Search for Ahrefs, click the card and click Connect
- Choose your Ahrefs workspace and account, then click Allow
- Enable the Ahrefs connector in a chat and ask your question
Ahrefs MCP in Claude Code
Add the server from your terminal, as Ahrefs' Claude Code guide shows, then run /mcp in Claude Code, authenticate the Ahrefs server, log in to Ahrefs, pick a workspace and click Allow:
claude mcp add ahrefs https://api.ahrefs.com/mcp/mcp -t httpHow to connect Ahrefs MCP to ChatGPT
Ahrefs says MCP support in ChatGPT is in beta, and only available in developer mode for Pro and Plus accounts on the web:
- Go to Settings → Apps → Advanced settings and turn on Developer mode
- Click Create app
- Enter
https://api.ahrefs.com/mcp/mcpas the MCP server URL and choose OAuth, leaving the client ID and secret blank - Tick "I trust this application", click Create, pick your workspace and click Allow
- In a chat, click +, then More, and enable the Ahrefs app
Ahrefs recommends being explicit in ChatGPT: name the Ahrefs MCP in your prompt, say which tool to use, and ask it not to use web search.
Ahrefs MCP in Cursor
Ahrefs does not publish a Cursor guide, but its server works with MCP clients that can connect to a remote server. In Settings → Cursor Settings → Tools & MCP, add the URL:
{
"mcpServers": {
"ahrefs": {
"url": "https://api.ahrefs.com/mcp/mcp"
}
}
}If sign-in does not start, generate an MCP key in Ahrefs under Account settings → API keys → Generate MCP key and pass it as a header, the format Ahrefs uses in its Claude Desktop guide:
{
"mcpServers": {
"ahrefs": {
"url": "https://api.ahrefs.com/mcp/mcp",
"headers": {
"Authorization": "Bearer YOUR_MCP_KEY"
}
}
}
}Ahrefs also documents setup for Claude Mobile, Copilot Studio, Lovable, n8n, Manus, Mistral's Le Chat and OpenClaw. Note that Ahrefs does not permit calling the MCP endpoint from custom scripts or standalone HTTP clients; for that, it points you to the Ahrefs API.
Common problems and fixes
Your plan does not include MCP access
Symptom: sign-in or requests fail.
Fix: check your plan in your Ahrefs account settings. Ahrefs MCP needs a paid plan from Lite upward.
Units run out faster than expected
Symptom: your unit balance drops quickly.
Cause: every call costs at least 50 units, and bigger requests cost more.
Fix:
- Be specific. Ask for "the top 50 keywords for example.com in the US" rather than "all keywords".
- Always set a result count, a country and filters.
- Keep related questions in one chat so the agent can reuse what it already fetched.
- Check Account settings → Limits and usage, and set a per-key unit limit if you share a workspace.
Ahrefs MCP 401 error
Ahrefs lists three common causes:
- Your key has expired. Generate a new one.
- Your subscription is no longer active. Renew it to keep using MCP.
- You are using a regular API key where an MCP key is needed. API keys and MCP keys are not interchangeable.
If the error persists, contact Ahrefs' live chat support.
An old config uses a different URL
Symptom: a setup that worked before no longer connects, or your client asks for an SSE server.
Fix: in October 2026, Ahrefs' MCP docs list one URL, Streamable HTTP at https://api.ahrefs.com/mcp/mcp. If an older config points at another Ahrefs MCP address, such as a legacy SSE URL ending in /mcpSse, replace it with that one.
Missing tools
Some MCP clients cap how many tools a server can advertise, and Ahrefs' server goes over that cap in many of them. Add a tools parameter to the URL to choose tool groups, or use the curated essentials set:
https://api.ahrefs.com/mcp/mcp?tools=essentialsYou can also list groups, for example ?tools=site-explorer-overview,keywords-explorer. A misspelled group name is rejected with an invalid tool category error.
Can I run it locally?
No. Ahrefs' help center says local MCP setup is no longer supported, and only the remote server is supported.
Example prompts
Here are prompts you can try once Ahrefs MCP is connected.
Keyword research
"Show the top 20 trending terms in my industry that have strong potential to grow in popularity throughout 2026. Include search volume, traffic potential and keyword difficulty."
Rank check
"Check where example.com ranks in Google US for 'project management software' and 'team collaboration tools'. Show the current position and the ranking URL."
Competitor backlinks
"Provide an overview of the backlink profiles of these five competitor websites, including domain rating and how many referring domains each gained in the past three months."
Keyword gap
"Find keywords that competitor.com ranks for that example.com does not, with at least 500 monthly searches and keyword difficulty under 40. Limit to 50 rows."
Brand in AI Overviews
"Use Ahrefs to find the top 10 most searched branded queries for our brand and the responses in AI Overviews. Analyze the overall sentiment and highlight how the answers differ from six months ago."
Ahrefs notes this prompt needs the Brand Radar AI Overviews and AI Mode add-on.
Run this in your agent
Connect Manifold to Claude, ChatGPT or Cursor, then paste this prompt.
Find keywords in our category with real search volume, check where we rank versus competitors, show their backlink profiles, and list keyword gaps we can target.
If you do not pay for Ahrefs
Ahrefs MCP is the natural choice when you already pay for Ahrefs. If you do not, Manifold is a hosted MCP server that answers the same kinds of questions (keywords, rankings, backlinks, domain metrics) from DataForSEO's data, charges per call, and needs no Ahrefs plan or DataForSEO account of your own. It also puts Search Console, Bing Webmaster Tools, AI answers, Reddit, ad libraries and leads in the same server.
The numbers will not match, because Ahrefs and DataForSEO run separate indexes. Volumes, difficulty scores and traffic estimates are estimates either way, so pick one source and stick with it when you track trends.
For the side by side, read Ahrefs MCP alternative. To compare every SEO server, read the best SEO MCP servers. For the other official servers, see Semrush MCP and the DataForSEO MCP setup guide.


