跳过安装。2 分钟内即可运行。
在 cloud.anythingmcp.com 开始免费试用,一键添加 Ahrefs,然后将你的 AI 客户端(Claude、ChatGPT、Copilot 或 Cursor)指向生成的 MCP 端点。无需 Docker,无需 git clone,无需任何工程经验。
AnythingMCP 已收录在 Claude 的连接器目录中:一键添加到 Claude (在新标签页中打开),然后登录并选择 Claude 可以使用哪些 MCP 服务器。
摘要
为你的 AI 提供 Ahrefs SEO 数据:Domain Rating、反向链接、引荐域名、自然关键词、热门页面、竞争对手、关键词搜索量、难度和关键词建议、SERP 概览和批量对比,并显示每次请求消耗的 API 单位。
试试这样问
Ahrefs 的示例提示
点击任意提示即可复制,然后粘贴到 Claude、ChatGPT、Cursor、Gemini、Copilot 或 OpenClaw 中,在该连接器上运行。
Claude 是 AI,可能会出错。请核对回答。
💡 无需安装? 直接使用 cloud.anythingmcp.com。 登录、点击 Connectors → Ahrefs、粘贴凭证、生成 MCP API key,即可完成。无 Docker、无
git clone、无本地服务器。
Ahrefs + Claude
为你的 AI 提供 Ahrefs SEO 数据:Domain Rating、反向链接、引荐域名、自然关键词、热门页面、竞争对手、关键词搜索量、难度和关键词建议、SERP 概览和批量对比,并显示每次请求消耗的 API 单位。
前提条件
完整的设置说明已内置在连接器中 (在 store 中选择连接器时可见)。所需环境变量:
AHREFS_API_KEY
步骤 1 — 获取凭证
- 符合条件的 Ahrefs 付费套餐包含 API 访问权限,每个套餐每月有一定的 API 单位额度(见
https://ahrefs.com/pricing);其他套餐只能运行免费的测试查询。只有工作区所有者和管理员可以创建密钥。 - 打开 Account settings → API keys(
https://app.ahrefs.com/account/api-keys),创建一个密钥,并建议为它设置每月单位上限。 - 将其粘贴到
AHREFS_API_KEY并安装连接器。密钥加密存储,并作为 Bearer 令牌只发送到 api.ahrefs.com。 - 先使用
ahrefs_get_limits_and_usage:它免费,会显示你的套餐、本月已用和可用的 API 单位,以及重置日期。
从你自己的 Ahrefs API 单位中扣费:每次请求都会消耗你 Ahrefs 工作区的 API 单位。每次请求至少 50 个单位;超出部分按所请求每一列的单位成本(默认 1 个单位,流量、搜索量、难度和引荐域名等指标为 5 或 10 个)乘以返回的行数计算。使用默认列时,反向链接每行 8 个单位,引荐域名 6 个,锚文本 10 个,自然关键词 34 个,热门页面 24 个,关键词指标每个关键词 33 个,SERP 概览每个排名位置 25 个。请求默认从 10 行开始,AI 只请求回答所需的列。Ahrefs 从缓存返回的请求免费。
免费测试查询:针对 ahrefs.com、yep.com 或 firehose.com 的 Site Explorer 请求,以及只针对关键词 ahrefs、yep 或 firehose 的 Keywords Explorer 或 SERP Overview 请求不收费(最多 100 行)。在花费单位之前,可以先用它们试用工具。
功能:Site Explorer(Domain Rating 和 Ahrefs Rank、反向链接总数、自然和付费搜索指标、流量和 Domain Rating 历史、反向链接、引荐域名、锚文本、自然关键词、热门页面和自然搜索竞争对手),Keywords Explorer(搜索量、Keyword Difficulty、CPC、流量潜力和父主题、匹配词和问题、相关词、月度搜索量历史),Ahrefs 为某个关键词记录的 SERP Overview,以及一次调用最多分析 100 个域名或 URL 的 Batch Analysis。所有工具都是只读的;Batch Analysis 使用 POST,但不会更改任何内容。
参数:大多数 Site Explorer 工具需要 date(查询当前数据时用今天的日期)。country 是小写的两字母国家代码。mode 设定目标的范围:subdomains(默认)、domain、prefix 或 exact。CPC 和流量价值以美分计。
常见错误:401:API 密钥错误、已过期或已被删除;请在 Account settings → API keys 下新建一个。403:套餐没有 API 访问权限,密钥或工作区已用完单位上限,或请求超出套餐范围(例如单次请求的行数超过套餐允许的数量)。400:某个参数无效,错误原因会指明是哪个参数。429:每分钟超过 60 次请求;请稍后重试。
该连接器不涵盖 Rank Tracker、Site Audit、Brand Radar、Web Analytics、GSC Insights、Social Media、Content Helper 或管理类端点(项目、关键词列表)。
步骤 2 — 安装 adapter
curl -fsSL https://raw.githubusercontent.com/HelpCode-ai/anythingmcp/main/docker-compose.quickstart.yml -o docker-compose.yml
printf 'JWT_SECRET=%s\nENCRYPTION_KEY=%s\n' "$(openssl rand -hex 32)" "$(openssl rand -hex 32)" > .env
docker compose up -d
步骤 3 — 在 Claude 中添加连接器
你的服务器 URL: 在 AnythingMCP 中打开 MCP Servers → 此连接器所在的服务器,复制它的 URL(
https://cloud.anythingmcp.com/mcp/…)。本指南中出现YOUR_SERVER_ID的地方都用它替换。
推荐路径:在 claude.ai web 上工作,无需触碰任何配置文件。
- 在 Claude 中打开 Customize → Connectors。
- 点击 +,然后点击 Add custom connector。
- 输入名称(例如
Ahrefs)和远程 MCP 服务器 URLhttps://cloud.anythingmcp.com/mcp/YOUR_SERVER_ID,然后点击 Add。 - 点击 Connect,登录 AnythingMCP(OAuth)并允许访问。
下面所有工具都会出现在你的聊天中,开始输入提示。
可用工具
| Tool | What it does |
|---|---|
ahrefs_get_limits_and_usage | Show the Ahrefs plan, the API units used and allowed this month for the key and the workspace, the reset date and the key's expiry |
ahrefs_domain_rating | Domain Rating (0 to 100, strength of the backlink profile) and Ahrefs Rank of a domain on a date |
ahrefs_backlinks_stats | Backlink totals of a domain or URL on a date: live and all-time backlinks and referring domains |
ahrefs_site_metrics | Organic and paid search metrics of a domain or URL on a date: organic keywords (all and top 3), organic traffic and its value, paid… |
ahrefs_metrics_history | History of a domain's organic (and optionally paid) traffic and traffic value, grouped by month, week or day |
ahrefs_domain_rating_history | History of a domain's Domain Rating, grouped by month, week or day |
ahrefs_backlinks | Backlinks of a domain or URL: linking page, target, anchor, Domain Rating of the source, dofollow, first and last seen |
ahrefs_referring_domains | Domains linking to a domain or URL: Domain Rating, links to the target, dofollow links, first and last seen |
ahrefs_anchors | Anchor texts of the links to a domain or URL with referring domains and link counts |
ahrefs_organic_keywords | Keywords a domain or URL ranks for in Google on a date: best position and ranking URL, volume, traffic, difficulty, CPC |
ahrefs_top_pages | Pages of a domain that bring the most organic traffic on a date, with traffic value, keyword count and top keyword |
ahrefs_organic_competitors | Domains competing with a target in organic search in one country: common keywords, their keywords, share and traffic |
ahrefs_keywords_overview | Metrics of one or more keywords in a country: search volume, Keyword Difficulty, CPC, traffic potential and parent topic |
ahrefs_matching_terms | Keyword ideas that contain the words of the seed keywords (or questions with terms=questions), with volume, difficulty, CPC and traffic… |
ahrefs_related_terms | Related keywords: terms the top-ranking pages also rank for or also mention, with volume, difficulty, CPC and traffic potential |
ahrefs_volume_history | Monthly search volume history of one keyword in a country |
ahrefs_serp_overview | The Google results page Ahrefs recorded for a keyword in a country: position, URL, title, type, Domain Rating, URL Rating, backlinks… |
ahrefs_batch_analysis | Compare up to 100 domains or URLs in one call: Domain Rating, backlinks, referring domains, organic keywords and traffic for each |
示例提示
- “example.com 今天的 Domain Rating、当前有效的引荐域名数和自然流量分别是多少?”
- “列出 competitor.com 中 Domain Rating 最高的 20 个 dofollow 引荐域名,以及它的外链最常用的锚文本。”
- “找出 example.com 在德国的自然搜索竞争对手,以及为它们带来最多流量的页面。”
- “给我美国市场中 ‘running shoes’ 的关键词建议,要求搜索量高于 1,000、难度低于 30,并附上流量潜力。”
- “本月我们已经用了多少 Ahrefs API 单位?额度什么时候重置?”
FAQ
Claude Code 和 Claude Desktop 一样工作吗? 是的,两者都指向 https://cloud.anythingmcp.com/mcp/YOUR_SERVER_ID。
下一步
这份指南对你有帮助吗?