Installation guide
How to install Ahrefs MCP
In Claude, ChatGPT, Gemini, Microsoft Copilot, Perplexity, Cursor and Claude Code, with what to check before you start and the first prompts to run.
Ahrefs MCP is a remote server hosted by Ahrefs. You add it to your assistant by URL and sign in with your Ahrefs account, so there is nothing to install locally and no package to run. The vendor article gives the remote connection URL as `https://api.ahrefs.com/mcp/mcp`. It is available on Lite, Standard, Advanced and Enterprise plans and draws API units.
Have the Ahrefs account owner, or an SEO lead they trust, do the setup with a normal Ahrefs login. Check with the account owner first how many API units are available and who else uses them. Start with read-only questions and keep large batch queries for supervised use.

Before you start
- An Ahrefs account on the Lite, Standard, Advanced or Enterprise plan.
- Agreement from the account owner on how many API units this connection may use, and who else draws on them.
- An AI assistant that supports remote MCP servers, such as Claude, ChatGPT or Microsoft Copilot Studio (the vendor article names these three).
- Access to the Ahrefs MCP help docs, which have guides for five AI tools. Use them for exact menu names and steps.
- The domains you want to test with, for example your own site and one competitor.
- How it runs
- Remote, added by URL
- Access
- Read-only
- Server address
https://api.ahrefs.com/mcp/mcp
Ahrefs MCP in Claude
- Open Claude.ai in the browser or the Claude Desktop app and go to
Settings > Connectors. - Choose the option to add a custom connector by URL.
- Paste
https://api.ahrefs.com/mcp/mcpas the server URL and name itAhrefs. - Sign in with your Ahrefs account when prompted and approve access.
- Enable the connector in a new chat. The vendor article says it prefers the Claude experience over ChatGPT, but follow the Ahrefs help doc for Claude for exact steps.
https://api.ahrefs.com/mcp/mcp
Ahrefs MCP in ChatGPT
- Open ChatGPT and enable Developer mode in the settings if you want to add a custom MCP connector. Menu names can change, so check the current ChatGPT interface.
- Add a new connector and paste
https://api.ahrefs.com/mcp/mcpas the server URL. - Sign in with your Ahrefs account when prompted.
- Enable the connector in your chat. The vendor article notes that MCP connectors are in beta in ChatGPT, so some rough edges are expected.
- Start prompts with "Using the Ahrefs MCP server" so ChatGPT does not fall back to web search.
https://api.ahrefs.com/mcp/mcp
Ahrefs MCP in Gemini
- The Ahrefs documentation provided to us does not cover Gemini. Check the Ahrefs MCP help docs for current support.
- In Gemini CLI, a remote server is normally added under
mcpServersin the settings file. Take the exact key for remote URLs from the Gemini CLI documentation. - Use
https://api.ahrefs.com/mcp/mcpas the server URL. - Complete the Ahrefs sign-in if the client prompts for it. The documentation does not describe the authentication flow for Gemini.
- Run a small read-only test before relying on it.
Ahrefs MCP in Microsoft Copilot
- The vendor article names Microsoft Copilot Studio as one of the five supported tools. Open the Ahrefs MCP help docs and follow the Copilot Studio guide.
- In Copilot Studio, add an MCP tool or custom connector to your agent. Use the exact menu path from the vendor guide.
- Enter
https://api.ahrefs.com/mcp/mcpwhen asked for the server address. - Sign in with your Ahrefs account when prompted.
- For GitHub Copilot in VS Code, the docs do not cover it. The standard route is a remote server entry in
mcp.json. Confirm the Ahrefs authentication details with the vendor.
Ahrefs MCP in Perplexity
- The Ahrefs documentation provided to us does not cover Perplexity. Check the Ahrefs MCP help docs for current support.
- In the Perplexity desktop app, open the connectors settings and look for the option to add a custom remote connector.
- Enter
https://api.ahrefs.com/mcp/mcpas the server URL if the app accepts one. - Sign in with your Ahrefs account when prompted.
- Run a small read-only test and confirm the answer comes from Ahrefs data.
https://api.ahrefs.com/mcp/mcp
Ahrefs MCP in Cursor
- The Ahrefs documentation provided to us does not cover Cursor. The standard way is to add a remote server to the MCP settings.
- Open Cursor settings and go to the MCP section, or edit the
mcp.jsonfile it uses. - Add an entry under
mcpServerswithurlset tohttps://api.ahrefs.com/mcp/mcp. - Save, then complete the Ahrefs sign-in if Cursor prompts for it. Confirm the auth flow with the Ahrefs help docs.
- Check that the server shows as connected, then run a small test.
{
"mcpServers": {
"ahrefs": {
"url": "https://api.ahrefs.com/mcp/mcp"
}
}
}
Ahrefs MCP in Claude Code
- The Ahrefs article does not give a Claude Code command. Use the standard remote
HTTPform ofclaude mcp addwith the URL from the article. - Run the command in the snippet in your terminal.
- Start
claudeand run/mcpto see the server and complete the sign-in with your Ahrefs account. - Ask a small read-only question and begin it with "Using the Ahrefs MCP server".
- If sign-in fails, check the Ahrefs MCP help docs for the current authentication method.
claude mcp add --transport http ahrefs https://api.ahrefs.com/mcp/mcpCheck that it works
Start with questions that only read data. If these answer from your real account, the connection is good.
- Using the Ahrefs MCP server, list the closest organic search competitors for [your domain].
- Using the Ahrefs MCP server, list the top 10 pages on [your domain] ranked by how many links each has, with estimated organic search traffic.
- Using the Ahrefs MCP server, tell me whether [your domain] has grown organic search traffic from January 2025 to September 2025.
Troubleshooting
+The assistant answers from a web search instead of Ahrefs. What should I do?
The vendor article says assistants do not always choose the Ahrefs MCP server over web search. Start the request with "Use the Ahrefs MCP server" or "Using the Ahrefs MCP server,". Also check that the connector is enabled for the current chat.
+The sign-in fails or the server does not appear. What should I check?
Confirm you are signing in with an Ahrefs account on the Lite, Standard, Advanced or Enterprise plan, and that the URL is exactly `https://api.ahrefs.com/mcp/mcp`. Then follow the Ahrefs MCP help guide for your assistant. ChatGPT connectors are in beta, so retry or remove and re-add the connector.
+Why are results truncated or why are API units running out quickly?
The vendor article says your account level determines how many rows each request returns. Larger requests, such as batch domain metrics or multi-site backlink comparisons, use more units and take longer. Ask the account owner to check unit usage and start with narrower prompts.
Written Nov 10, 2026 from the vendor documentation. Exact menus, addresses and commands change; the official documentation is the source of truth.
Questions and answers
Questions readers and searchers ask about installing Ahrefs MCP, answered by the site editor from the vendor documentation, plus reader experience. Every comment is reviewed before it appears.