Ahrefs API v2 has been deprecated
This documentation is for the legacy version of our API (v2), which was fully discontinued on November 1, 2025. All remaining API v2 integrations and apps built on it no longer have access to Ahrefs data.
To build new integrations, please use Ahrefs API v3 and the Ahrefs Connect program.
Documentation - positions_metrics
Contains the estimation of number of keywords, traffic and cost of the target URL.
Each request to positions_metrics costs 1 row.
Each result in the response costs 1 row.
Using 'where' costs 5 rows.
• metrics
| Column | Type | Where | Having | Description |
|---|---|---|---|---|
| positions | int | − | − | Total number of keywords that the target URL ranks for in the top 100 organic search results across all countries in our database. |
| positions_top3 | int | − | − | Total number of keywords that the target URL ranks for in the top 3 organic search results across all countries in our database. |
| positions_top10 | int | − | − | Total number of keywords that the target URL ranks for in the top 10 organic search results across all countries in our database. |
| traffic | float | − | − | Estimation of the total monthly search traffic to the target URL from the top 100 organic search results. |
| traffic_top3 | float | − | − | Estimation of the total monthly search traffic to the target URL from the top 3 organic search results. |
| traffic_top10 | float | − | − | Estimation of the total monthly search traffic to the target URL from the top 10 organic search results. |
| cost | float | − | − | The equivalent value of the organic search traffic, should that traffic have been acquired via PPC. Traffic value is in US cents. |
| cost_top3 | float | − | − | The equivalent value of the top 3 organic search traffic, should that traffic have been acquired via PPC. Traffic value is in US cents. |
| cost_top10 | float | − | − | The equivalent value of the top 10 organic search traffic, should that traffic have been acquired via PPC. Traffic value is in US cents. |
| country | string | + | − | Used to get data for a particular country. Parameter should be the country code (ISO-3166 alpha-2) in lowercase (e.g. &where=country:"ca"). |
Examples
Request
Response
{
"metrics": {
"positions": 166445,
"positions_top10": 34277,
"positions_top3": 9578,
"traffic": 695497.706219,
"traffic_top10": 655791.366397,
"traffic_top3": 467322.841172,
"cost": 152895377.353411,
"cost_top10": 145556581.485097,
"cost_top3": 103207073.519511
}
}