Site icon DataForSEO

How to get keywords a domain/URL ranks for?

With DataForSEO Labs API, you can enrich your tool with ranking keywords data.

Using the Ranked Keywords endpoint of Google or the Ranked Keywords endpoint of Bing, it’s easy to discover ranking keywords of any domain/URL on the web, along with valuable keyword metrics.

POST https://api.dataforseo.com/v3/dataforseo_labs/google/ranked_keywords/live

POST https://api.dataforseo.com/v3/dataforseo_labs/bing/ranked_keywords/live

How to get keywords a domain ranks for

1To get the ranking keywords of a domain, specify the domain name without https:// and www in the target field of the Task POST array.

2You can also specify location_name (or location_code) and language_name (or language code) to get country-specific keyword metrics and rankings. If you ignore these fields, the API will return global data.

To get the full list of locations and languages for DataForSEO Labs API, call the Locations and Languages endpoint.

GET https://api.dataforseo.com/v3/dataforseo_labs/locations_and_languages

3Set the limit on the number of returned keywords by adding the limit field to the Task POST array. Note that the Ranked Keywords endpoint can return no more than 1000 keywords per one request. Thus, the maximum limit value can be 1000. If you don’t add this parameter, the API response will return 100 keywords as the default limit value is 100.

Your Task POST request should be structured as in the example below.

[
    {
        "target": "dataforseo.com",
        "language_name": "English",
        "location_code": 2840,
        "limit": 50
    }
]

How to get keywords a URL ranks for

To get ranking keywords data for a particular URL of the domain, simply add the filters field with the ranked_serp_element.serp_item.relative_url parameter to the Task POST array.

Example:

[
    {
        "target": "dataforseo.com",
        "language_name": "English",
        "location_code": 2840,
        "limit": 50,
        "filters": ["ranked_serp_element.serp_item.relative_url", "=", "/blog/backlinks-api-now-in-dataforseo"]
    }
]

Exit mobile version