# Copilot Studio

Follow these steps to add Ahrefs MCP server to Copilot Studio:
- On the left-hand menu, click "Create" and then "New agent".
![](../images/cs-1.jpg)
- Enter the agent details: Name, Description and Instructions and click "Create".
![](../images/cs-2.jpg)
- Under "Tools", click "Add a tool" to attach a connector or custom action.
![](../images/cs-3.jpg)
- Choose "Model Context Protocol" and click "New tool".
![](../images/cs-4.jpg)
- Choose "Model Context Protocol"
![](../images/cs-5.jpg)
- Fill in the required information and click "Create"
   - Server URL: `https://api.ahrefs.com/mcp/mcp`
   - Authentication: "API Key"
   - Type: Header
   - Header name: `Authorization`
![](../images/cs-6.jpg)
- Create a new connection
![](../images/cs-7.jpg)
- Go to Ahrefs workspace → Account Settings → [API Keys](https://app.ahrefs.com/account/api-keys) and click "Generate MCP key" to create a new key.
![](../images/clw-6.jpg)
- Paste the key into Copilot, making sure to add the `Bearer` prefix: `Bearer YOUR_API_KEY`.
![](../images/cs-9-2.jpg)
- Add the tool to your agent.
![](../images/cs-10.jpg)
