Get your Ahrefs API Key
1
Sign up or log in
Go to Ahrefs and sign in to your account.
2
Navigate to API Settings
- Click on your profile in the top right
- Go to “API” settings
- Or directly visit: https://ahrefs.com/api
3
Generate API Token
- Click “Generate new token” or use an existing token
- Copy the API token - you’ll need this for authentication
- Store it securely (you won’t be able to see it again)
4
Store in Corsair
Run the setup command:When prompted, enter:
api_key: Your Ahrefs API token
API Key Notes
Ahrefs API v3 uses the key in theAuthorization: Bearer <api_key> header. Only workspace owners and admins can create API keys, and keys expire after 1 year.
Rate Limits
Ahrefs API is limited to 60 requests per minute by default. Many endpoints also consume API units based on requested fields and returned rows, with a minimum request cost unless the endpoint is marked free in Ahrefs docs. Corsair retries rate-limited responses with exponential backoff.Required Permissions
The API key needs access to:- Site Explorer API - for domain metrics and backlinks data
- Keywords Explorer API - for keyword research and metrics