Ahrefs MCP for Codex
Ask Codex about your Ahrefs data in plain words. Add one server, sign in with Google, and it reads your own numbers on each request.
Get started free- 1
Add the server, then sign in. The CLI, IDE extension and desktop app share this config:
codex mcp add seoskill --url https://seoskill.dev/mcp codex mcp login seoskill - 2
Check it with /mcp in Codex, or codex mcp list.
- 3
Save your Ahrefs API key under Keys on your account page at seoskill.dev/account. It works in every client you connect.
- 4
Or send the key as a header from ~/.codex/config.toml, so nothing is saved on your account. Each header takes its value from the environment variable named here:
[mcp_servers.seoskill] url = "https://seoskill.dev/mcp" env_http_headers = { "X-Ahrefs-Key" = "AHREFS_API_KEY" }
codex mcp login opens the Google sign-in in your browser. Codex keeps the token for later sessions.
Prompts to try in Codex
Ask in plain words and your agent picks the tool. Ahrefs numbers are estimates from its own index. They stay separate from your first-party data.
What keywords does example.org rank for that I don't?
Ranked keywords for the competitor, which your agent can set against your own Search Console queries.
Which sites compete with mine?
Competitors: domains that rank for the same keywords, each with its Domain Rating.
Who links to this competitor?
Backlinks: the referring domains for a domain or URL.
How hard is this keyword?
Keyword metrics with volume, keyword difficulty and cost per click.
Ahrefs in other AI clients
The same server and sign-in, with each client's own setup steps.
Claude Code
One command in your terminal.
Ahrefs in Claude CodeClaude
A custom connector, added once for web, desktop and mobile.
Ahrefs in ClaudeChatGPT
A custom MCP server added from Plugins.
Ahrefs in ChatGPTCursor
One entry in mcp.json.
Ahrefs in CursorVS Code
The Add Server command, or one entry in .mcp.json.
Ahrefs in VS CodeGemini CLI
One command in your terminal.
Ahrefs in Gemini CLIWindsurf
Two commands, or one entry in mcp_config.json.
Ahrefs in WindsurfLe Chat
A custom MCP connector.
Ahrefs in Le ChatMore data for Codex
One server reads all of these. Add a key or a site and your agent can use it.
Google Search Console
Clicks, impressions, CTR, positions, queries, pages and URL Inspection.
Google Search Console in CodexGoogle Analytics
Search sessions beside your clicks, landing pages and visits from AI assistants.
Google Analytics in CodexDataForSEO
Keyword metrics, rankings, SERPs, competitors, backlinks and AI answer checks with your own login.
DataForSEO in CodexClicky
Visits by landing page, with the traffic sources and search engines that sent them.
Clicky in Codex