> ## Documentation Index
> Fetch the complete documentation index at: https://composio-preview.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Ahrefs

> Ahrefs is an SEO and marketing platform offering site audits, keyword research, content analysis, and competitive insights to improve search rankings and drive organic traffic

![Ahrefs logo](https://mintcdn.com/composio-preview/qzegrvAapILigeDI/images/toolkits/ahrefs.svg?fit=max\&auto=format\&n=qzegrvAapILigeDI\&q=85\&s=f53e1587174e9a5700be419f3c1d9297)

* **Category:** seo & ai visibility
* **Auth:** API\_KEY, OAUTH2
* **Composio-managed OAuth available?** No
* **Tools:** 46
* **Triggers:** 0
* **Slug:** `AHREFS`
* **Version:** 20261101\_00
* **Instant:** Supported on the latest version. Support varies by tool.

## Tools

> [accordion] Backlinks stats retrieval
>
> **Slug:** `AHREFS_BACKLINKS_STATS_RETRIEVAL`
>
> Retrieves comprehensive backlink statistics for a specified website or URL using Ahrefs' Site Explorer tool. This endpoint provides crucial data for SEO analysis, including the total number of backlinks, referring domains, and potentially the Domain Rating (DR). It's essential for understanding a site's link profile, assessing its SEO performance, and conducting competitive analysis. The tool is particularly useful when users need detailed insights into a website's backlink structure or when comparing the backlink profiles of multiple domains. Note that the data returned is based on Ahrefs' extensive web crawl and may not include very recent backlinks.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **date** `string` *required*
>
> A date to report metrics on in YYYY-MM-DD format.
>
> **mode** `string ("exact" | "prefix" | "domain" | "subdomains")`
>
> The scope of the search based on the target you entered.
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **target** `string` *required*
>
> The target of the search: a domain or a URL.
>
> **protocol** `string ("both" | "http" | "https")`
>
> The protocol of your target.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Batch Url Analysis
>
> **Slug:** `AHREFS_BATCH_URL_ANALYSIS`
>
> Performs a batch analysis on multiple URLs or domains using Ahrefs' powerful SEO metrics. This endpoint allows users to retrieve key SEO data for up to 100 targets simultaneously, streamlining the process of analyzing multiple websites or pages. It's particularly useful for comparing competitors, analyzing site sections, or processing large sets of URLs efficiently. The endpoint offers customization options for selecting specific metrics, filtering by country, and choosing the calculation mode for volume-based metrics. While it provides comprehensive data, users should be aware of the 100-target limit per request and ensure they have sufficient API quota for large-scale analyses.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **output** `string ("json" | "php")`
>
> The output format.
>
> **select** `array` *required*
>
> A list of columns to return. See response schema for valid column identifiers.
>
> **country** `string ("ad" | "ae" | "af" | "ag" | "ai" | "al" | "am" | "ao" | "ar" | "as" | "at" | "au" | "aw" | "az" | "ba" | "bb" | "bd" | "be" | "bf" | "bg" | "bh" | "bi" | "bj" | "bn" | "bo" | "br" | "bs" | "bt" | "bw" | "by" | "bz" | "ca" | "cd" | "cf" | "cg" | "ch" | "ci" | "ck" | "cl" | "cm" | "cn" | "co" | "cr" | "cu" | "cv" | "cy" | "cz" | "de" | "dj" | "dk" | "dm" | "do" | "dz" | "ec" | "ee" | "eg" | "es" | "et" | "fi" | "fj" | "fm" | "fo" | "fr" | "ga" | "gb" | "gd" | "ge" | "gf" | "gg" | "gh" | "gi" | "gl" | "gm" | "gn" | "gp" | "gq" | "gr" | "gt" | "gu" | "gy" | "hk" | "hn" | "hr" | "ht" | "hu" | "id" | "ie" | "il" | "im" | "in" | "iq" | "is" | "it" | "je" | "jm" | "jo" | "jp" | "ke" | "kg" | "kh" | "ki" | "kn" | "kr" | "kw" | "ky" | "kz" | "la" | "lb" | "lc" | "li" | "lk" | "ls" | "lt" | "lu" | "lv" | "ly" | "ma" | "mc" | "md" | "me" | "mg" | "mk" | "ml" | "mm" | "mn" | "mq" | "mr" | "ms" | "mt" | "mu" | "mv" | "mw" | "mx" | "my" | "mz" | "na" | "nc" | "ne" | "ng" | "ni" | "nl" | "no" | "np" | "nr" | "nu" | "nz" | "om" | "pa" | "pe" | "pf" | "pg" | "ph" | "pk" | "pl" | "pn" | "pr" | "ps" | "pt" | "py" | "qa" | "re" | "ro" | "rs" | "ru" | "rw" | "sa" | "sb" | "sc" | "se" | "sg" | "sh" | "si" | "sk" | "sl" | "sm" | "sn" | "so" | "sr" | "st" | "sv" | "td" | "tg" | "th" | "tj" | "tk" | "tl" | "tm" | "tn" | "to" | "tr" | "tt" | "tw" | "tz" | "ua" | "ug" | "us" | "uy" | "uz" | "vc" | "ve" | "vg" | "vi" | "vn" | "vu" | "ws" | "ye" | "yt" | "za" | "zm" | "zw")`
>
> A two-letter country code (ISO 3166-1 alpha-2).
>
> **targets** `array` *required*
>
> A list of targets to do batch analysis.
>
> **order\_by** `string`
>
> A column to order results by. See response schema for valid column identifiers.
>
> **volume\_mode** `string ("monthly" | "average")`
>
> The search volume calculation mode: monthly or average. It affects volume, traffic, and traffic value.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Domain rating for site explorer
>
> **Slug:** `AHREFS_DOMAIN_RATING_FOR_SITE_EXPLORER`
>
> Retrieves Ahrefs Domain Rating and Ahrefs Rank for a specified domain or URL on a requested date. Domain Rating measures the strength of a website's backlink profile on a logarithmic scale from 0 to 100.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **date** `string` *required*
>
> A date to report metrics on in YYYY-MM-DD format.
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **target** `string` *required*
>
> The target of the search: a domain or a URL.
>
> **protocol** `string ("both" | "http" | "https")`
>
> The protocol of your target.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Domain rating history
>
> **Slug:** `AHREFS_DOMAIN_RATING_HISTORY`
>
> Retrieves the historical Domain Rating (DR) data for a specified domain over time. This endpoint is part of Ahrefs' Site Explorer tool and provides insights into how a domain's authority has changed. It's useful for tracking the impact of SEO efforts, analyzing competitors, or understanding long-term trends in domain strength. The tool returns a time series of Domain Rating values, allowing users to visualize changes in a domain's perceived authority according to Ahrefs' metrics. It should be used when analyzing the historical performance of a domain in terms of its overall SEO strength and backlink profile quality. Note that this endpoint focuses solely on Domain Rating and does not provide other metrics like backlink counts or organic traffic data.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **target** `string` *required*
>
> The target of the search: a domain or a URL.
>
> **date\_to** `string`
>
> The end date of the historical period in YYYY-MM-DD format.
>
> **date\_from** `string` *required*
>
> The start date of the historical period in YYYY-MM-DD format.
>
> **history\_grouping** `string ("daily" | "weekly" | "monthly")`
>
> The time interval used to group historical data.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Explore keywords overview
>
> **Slug:** `AHREFS_EXPLORE_KEYWORDS_OVERVIEW`
>
> Retrieves keyword-level overview metrics from Ahrefs' Keywords Explorer for specified keywords or an existing keyword list in a country. Available metrics include search volume, keyword difficulty and traffic potential.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **limit** `integer`
>
> The number of results to return.
>
> **where** `string`
>
> The filter expression. The following column identifiers are recognized (this differs from the identifiers recognized by the `select` parameter). **clicks**: The average monthly number of clicks on the search results that people make while searching for the target keyword.   type: integer nullable **cpc**: Cost Per Click shows the average price that advertisers pay for each ad click in paid search results for a keyword, in USD cents.   type: integer nullable **cps**: Clicks Per Search (or CPS) is the ratio of Clicks to Keyword Search volume. It shows how many different search results get clicked, on average, when people search for the target keyword in a given country.   type: float nullable **difficulty** (10 units): An estimation of how hard it is to rank in the top 10 organic search results for a keyword on a 100-point scale.   type: integer nullable **first\_seen**: The date when we first checked search engine results for a keyword.   type: datetime nullable **global\_volume** (10 units): How many times per month, on average, people search for the target keyword across all countries in our database.   type: integer nullable **intents** (10 units): Indicates the purpose behind the user"s search query. Object fields: `informational`, `navigational`, `commercial`, `transactional`, `branded` or `local`. All the fields are of type `bool`, with posible values `true` or `false`.   type: object nullable **keyword**:    type: string **parent\_topic**: Parent Topic determines if you can rank for your target keyword while targeting a more general topic on your page instead. To identify the Parent Topic, we take the #1 ranking page for your keyword and find the keyword responsible for sending the most traffic to that page.   type: string nullable **parent\_volume** (10 units): The search volume of the parent topic.   type: integer nullable **serp\_domain\_rating\_top10\_min**: The keyword must have at least one ranking position in the top 10 results with a DR of up to this value.   type: float nullable **serp\_domain\_rating\_top5\_min**: The keyword must have at least one ranking position in the top 5 results with a DR of up to this value.   type: float nullable **serp\_features**: The enriched results on a search engine results page (SERP) that are not traditional organic results.   type: array(string)   enum: `"ai_overview_sitelink"` `"snippet"` `"ai_overview"` `"local_pack"` `"sitelink"` `"news"` `"image"` `"video"` `"discussion"` `"tweet"` `"paid_top"` `"paid_bottom"` `"paid_sitelink"` `"shopping"` `"knowledge_card"` `"knowledge_panel"` `"question"` `"image_th"` `"video_th"` `"organic_shopping"` **serp\_last\_update**: The date when we last checked search engine results for a keyword.   type: datetime nullable **traffic\_potential** (10 units): The sum of organic traffic that the #1 ranking page for your target keyword receives from all the keywords that it ranks for.   type: integer nullable **volume** (10 units): An estimation of the average monthly number of searches for a keyword over the latest known 12 months of data.   type: integer nullable **volume\_desktop\_pct**: The percentage of searches for a keyword performed on desktop devices.   type: float nullable **volume\_mobile\_pct**: The percentage of searches for a keyword performed on mobile devices.   type: float nullable **word\_count**:    type: integer
>
> **offset** `integer`
>
> \[Deprecated on 31 May 2024].
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **select** `string` *required*
>
> A comma-separated list of columns to return. See response schema for valid column identifiers.
>
> **target** `string`
>
> The target of the search: a domain or a URL.
>
> **country** `string ("ad" | "ae" | "af" | "ag" | "ai" | "al" | "am" | "ao" | "ar" | "as" | "at" | "au" | "aw" | "az" | "ba" | "bb" | "bd" | "be" | "bf" | "bg" | "bh" | "bi" | "bj" | "bn" | "bo" | "br" | "bs" | "bt" | "bw" | "by" | "bz" | "ca" | "cd" | "cf" | "cg" | "ch" | "ci" | "ck" | "cl" | "cm" | "cn" | "co" | "cr" | "cu" | "cv" | "cy" | "cz" | "de" | "dj" | "dk" | "dm" | "do" | "dz" | "ec" | "ee" | "eg" | "es" | "et" | "fi" | "fj" | "fm" | "fo" | "fr" | "ga" | "gb" | "gd" | "ge" | "gf" | "gg" | "gh" | "gi" | "gl" | "gm" | "gn" | "gp" | "gq" | "gr" | "gt" | "gu" | "gy" | "hk" | "hn" | "hr" | "ht" | "hu" | "id" | "ie" | "il" | "im" | "in" | "iq" | "is" | "it" | "je" | "jm" | "jo" | "jp" | "ke" | "kg" | "kh" | "ki" | "kn" | "kr" | "kw" | "ky" | "kz" | "la" | "lb" | "lc" | "li" | "lk" | "ls" | "lt" | "lu" | "lv" | "ly" | "ma" | "mc" | "md" | "me" | "mg" | "mk" | "ml" | "mm" | "mn" | "mq" | "mr" | "ms" | "mt" | "mu" | "mv" | "mw" | "mx" | "my" | "mz" | "na" | "nc" | "ne" | "ng" | "ni" | "nl" | "no" | "np" | "nr" | "nu" | "nz" | "om" | "pa" | "pe" | "pf" | "pg" | "ph" | "pk" | "pl" | "pn" | "pr" | "ps" | "pt" | "py" | "qa" | "re" | "ro" | "rs" | "ru" | "rw" | "sa" | "sb" | "sc" | "se" | "sg" | "sh" | "si" | "sk" | "sl" | "sm" | "sn" | "so" | "sr" | "st" | "sv" | "td" | "tg" | "th" | "tj" | "tk" | "tl" | "tm" | "tn" | "to" | "tr" | "tt" | "tw" | "tz" | "ua" | "ug" | "us" | "uy" | "uz" | "vc" | "ve" | "vg" | "vi" | "vn" | "vu" | "ws" | "ye" | "yt" | "za" | "zm" | "zw")` *required*
>
> A two-letter country code (ISO 3166-1 alpha-2).
>
> **timeout** `integer`
>
> A manual timeout duration in seconds.
>
> **keywords** `string`
>
> A comma-separated list of keywords to show metrics for.
>
> **order\_by** `string`
>
> A column to order results by. See response schema for valid column identifiers.
>
> **target\_mode** `string ("exact" | "prefix" | "domain" | "subdomains")`
>
> The scope of the target URL you specified.
>
> **search\_engine** `string ("google")`
>
> \[Deprecated on 5 Aug 2024].
>
> **keyword\_list\_id** `integer`
>
> The id of an existing keyword list to show metrics for.
>
> **target\_position** `string ("in_top10" | "in_top100")`
>
> Filters keywords based on the ranking position of the specified `target`.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Explore keyword volume by country
>
> **Slug:** `AHREFS_EXPLORE_KEYWORD_VOLUME_BY_COUNTRY`
>
> Retrieves monthly search volume data across countries for a specified keyword using Ahrefs' Keywords Explorer. The data can help compare keyword popularity across geographic markets.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **limit** `integer`
>
> The number of results to return.
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **keyword** `string` *required*
>
> The keyword to show metrics for.
>
> **search\_engine** `string ("google")`
>
> \[Deprecated on 5 Aug 2024].
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Explore linked domains of a site
>
> **Slug:** `AHREFS_EXPLORE_LINKED_DOMAINS_OF_A_SITE`
>
> Retrieves a list of external domains that the specified target website or URL links to, using Ahrefs' Site Explorer functionality. This endpoint is crucial for analyzing a website's external linking structure, which can provide insights into its content strategy, partnerships, and overall SEO approach. It's particularly useful for competitive analysis, link building strategies, and identifying potential opportunities or risks in a website's outbound link profile. The endpoint returns detailed information about each linked domain, including the number of links pointing to it from the target site.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **mode** `string ("exact" | "prefix" | "domain" | "subdomains")`
>
> The scope of the search based on the target you entered.
>
> **limit** `integer`
>
> The number of results to return.
>
> **where** `string`
>
> The filter expression. The following column identifiers are recognized (this differs from the identifiers recognized by the `select` parameter). **anchor**: The clickable words in a link that point to a URL.   type: string **dofollow\_linked\_domains**: The number of unique root domains with dofollow links linked from the linked domain.   type: integer **dofollow\_links**: The number of links from your target to the linked domain that don"t have the "nofollow" attribute.   type: integer **dofollow\_refdomains** (5 units): The number of unique domains with dofollow links to the linked domain.   type: integer **domain**: A linked domain that has at least one link from your target.   type: string **domain\_rating**: The strength of a domain"s backlink profile compared to the others in our database on a 100-point scale.   type: float **first\_seen**: The date we first found a link to the linked domain from your target.   type: datetime **is\_content**: The link was found in the biggest piece of content on the page.   type: boolean **is\_dofollow**: The link has no special nofollow attribute.   type: boolean **is\_nofollow**: The link or the referring page has the nofollow attribute set.   type: boolean **is\_non\_html**: The link points to a URL with non-HTML content.   type: boolean **is\_root\_domain**: The domain name is a root domain name.   type: boolean **is\_sponsored**: The link has the Sponsored attribute set in the referring page HTML.   type: boolean **is\_ugc**: The link has the User Generated Content attribute set in the referring page HTML.   type: boolean **languages**: The languages listed in the referring page metadata or detected by the crawler to appear in the HTML.   type: array(string) **len\_url\_redirect**: The number of redirect chain URLs.   type: integer **link\_type**: The kind of the backlink.   type: string   enum: `"redirect"` `"frame"` `"text"` `"form"` `"canonical"` `"alternate"` `"rss"` `"image"` **linked\_domain\_traffic** (10 units): The linked domain"s estimated monthly organic traffic from search   type: integer **linked\_domains**: The number of unique root domains linked from the referring page.   type: integer **linked\_pages**: The number of the domain"s pages linked from your target.   type: integer **links\_external**: The number of external links from the referring page.   type: integer **links\_from\_target**: The number of links to the linked domain from your target.   type: integer **port\_source**: The network port of the referring page URL.   type: integer **port\_target**: The network port of the target page URL.   type: integer **positions**: The number of keywords that the referring page ranks for in the top 100 positions.   type: integer **powered\_by**: Web technologies used to build and serve the referring page content.   type: array(string) **refdomains** (5 units): The number of unique referring domains linking to the referring page.   type: integer **root\_domain\_name**: The root domain name of the referring domain, not including subdomains.   type: string **snippet\_left**: The snippet of text appearing just before the link.   type: string **snippet\_right**: The snippet of text appearing just after the link.   type: string **title**: The html title of the referring page.   type: string **traffic\_page** (10 units): The referring page"s estimated monthly organic traffic from search.   type: integer **url\_from**: The URL of the page containing a link from your target.   type: string **url\_redirect**: A redirect chain the target URL of the link points to.   type: array(url) **url\_redirect\_with\_target**: The target URL of the link with its redirect chain.   type: array(string) **url\_to**: The URL the outgoing link points to.   type: string
>
> **offset** `integer`
>
> \[Deprecated on 31 May 2024].
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **select** `string` *required*
>
> A comma-separated list of columns to return. See response schema for valid column identifiers.
>
> **target** `string` *required*
>
> The target of the search: a domain or a URL.
>
> **timeout** `integer`
>
> A manual timeout duration in seconds.
>
> **order\_by** `string`
>
> A column to order results by. See response schema for valid column identifiers.
>
> **protocol** `string ("both" | "http" | "https")`
>
> The protocol of your target.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Explore matching terms for keywords
>
> **Slug:** `AHREFS_EXPLORE_MATCHING_TERMS_FOR_KEYWORDS`
>
> The keywords\_explorer\_matching\_terms endpoint retrieves a list of keyword phrases that match or contain the specified keyword from Ahrefs' vast database. This tool is part of Ahrefs' Keyword Explorer functionality and is designed to assist in comprehensive keyword research for SEO purposes. It returns matching terms along with their relevant metrics such as search volume, keyword difficulty, and potential traffic. This endpoint is particularly useful when expanding a seed keyword list, finding long-tail variations, or discovering closely related search terms. The tool takes into account the specified country for localized results, allowing for targeted keyword strategies in different markets. It's important to note that while this tool provides valuable keyword suggestions, it should be used in conjunction with other Ahrefs features for a complete SEO strategy.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **limit** `integer`
>
> The number of results to return.
>
> **terms** `string ("all" | "questions")`
>
> All keywords ideas or keywords ideas phrased as questions.
>
> **where** `string`
>
> The filter expression. The following column identifiers are recognized (this differs from the identifiers recognized by the `select` parameter). **cpc**: Cost Per Click shows the average price that advertisers pay for each ad click in paid search results for a keyword, in USD cents.   type: integer nullable **cps**: Clicks Per Search (or CPS) is the ratio of Clicks to Keyword Search volume. It shows how many different search results get clicked, on average, when people search for the target keyword in a given country.   type: float nullable **difficulty** (10 units): An estimation of how hard it is to rank in the top 10 organic search results for a keyword on a 100-point scale.   type: integer nullable **first\_seen**: The date when we first checked search engine results for a keyword.   type: datetime nullable **global\_volume** (10 units): How many times per month, on average, people search for the target keyword across all countries in our database.   type: integer nullable **intents** (10 units): Indicates the purpose behind the user"s search query. Object fields: `informational`, `navigational`, `commercial`, `transactional`, `branded` or `local`. All the fields are of type `bool`, with posible values `true` or `false`.   type: object nullable **keyword**:    type: string **parent\_topic**: Parent Topic determines if you can rank for your target keyword while targeting a more general topic on your page instead. To identify the Parent Topic, we take the #1 ranking page for your keyword and find the keyword responsible for sending the most traffic to that page.   type: string nullable **serp\_domain\_rating\_top10\_min**: The keyword must have at least one ranking position in the top 10 results with a DR of up to this value.   type: float nullable **serp\_domain\_rating\_top5\_min**: The keyword must have at least one ranking position in the top 5 results with a DR of up to this value.   type: float nullable **serp\_features**: The enriched results on a search engine results page (SERP) that are not traditional organic results.   type: array(string)   enum: `"ai_overview_sitelink"` `"snippet"` `"ai_overview"` `"local_pack"` `"sitelink"` `"news"` `"image"` `"video"` `"discussion"` `"tweet"` `"paid_top"` `"paid_bottom"` `"paid_sitelink"` `"shopping"` `"knowledge_card"` `"knowledge_panel"` `"question"` `"image_th"` `"video_th"` `"organic_shopping"` **serp\_last\_update**: The date when we last checked search engine results for a keyword.   type: datetime nullable **traffic\_potential** (10 units): The sum of organic traffic that the #1 ranking page for your target keyword receives from all the keywords that it ranks for.   type: integer nullable **volume** (10 units): An estimation of the average monthly number of searches for a keyword over the latest known 12 months of data.   type: integer nullable **volume\_desktop\_pct**: The percentage of searches for a keyword performed on desktop devices.   type: float nullable **volume\_mobile\_pct**: The percentage of searches for a keyword performed on mobile devices.   type: float nullable **word\_count**:    type: integer
>
> **offset** `integer`
>
> \[Deprecated on 31 May 2024].
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **select** `string` *required*
>
> A comma-separated list of columns to return. See response schema for valid column identifiers.
>
> **country** `string ("ad" | "ae" | "af" | "ag" | "ai" | "al" | "am" | "ao" | "ar" | "as" | "at" | "au" | "aw" | "az" | "ba" | "bb" | "bd" | "be" | "bf" | "bg" | "bh" | "bi" | "bj" | "bn" | "bo" | "br" | "bs" | "bt" | "bw" | "by" | "bz" | "ca" | "cd" | "cf" | "cg" | "ch" | "ci" | "ck" | "cl" | "cm" | "cn" | "co" | "cr" | "cu" | "cv" | "cy" | "cz" | "de" | "dj" | "dk" | "dm" | "do" | "dz" | "ec" | "ee" | "eg" | "es" | "et" | "fi" | "fj" | "fm" | "fo" | "fr" | "ga" | "gb" | "gd" | "ge" | "gf" | "gg" | "gh" | "gi" | "gl" | "gm" | "gn" | "gp" | "gq" | "gr" | "gt" | "gu" | "gy" | "hk" | "hn" | "hr" | "ht" | "hu" | "id" | "ie" | "il" | "im" | "in" | "iq" | "is" | "it" | "je" | "jm" | "jo" | "jp" | "ke" | "kg" | "kh" | "ki" | "kn" | "kr" | "kw" | "ky" | "kz" | "la" | "lb" | "lc" | "li" | "lk" | "ls" | "lt" | "lu" | "lv" | "ly" | "ma" | "mc" | "md" | "me" | "mg" | "mk" | "ml" | "mm" | "mn" | "mq" | "mr" | "ms" | "mt" | "mu" | "mv" | "mw" | "mx" | "my" | "mz" | "na" | "nc" | "ne" | "ng" | "ni" | "nl" | "no" | "np" | "nr" | "nu" | "nz" | "om" | "pa" | "pe" | "pf" | "pg" | "ph" | "pk" | "pl" | "pn" | "pr" | "ps" | "pt" | "py" | "qa" | "re" | "ro" | "rs" | "ru" | "rw" | "sa" | "sb" | "sc" | "se" | "sg" | "sh" | "si" | "sk" | "sl" | "sm" | "sn" | "so" | "sr" | "st" | "sv" | "td" | "tg" | "th" | "tj" | "tk" | "tl" | "tm" | "tn" | "to" | "tr" | "tt" | "tw" | "tz" | "ua" | "ug" | "us" | "uy" | "uz" | "vc" | "ve" | "vg" | "vi" | "vn" | "vu" | "ws" | "ye" | "yt" | "za" | "zm" | "zw")` *required*
>
> A two-letter country code (ISO 3166-1 alpha-2).
>
> **timeout** `integer`
>
> A manual timeout duration in seconds.
>
> **keywords** `string`
>
> A comma-separated list of keywords to show metrics for.
>
> **order\_by** `string`
>
> A column to order results by. See response schema for valid column identifiers.
>
> **match\_mode** `string ("terms" | "phrase")`
>
> Keyword ideas contain the words from your query in any order (terms mode) or in the exact order they are written (phrase mode).
>
> **search\_engine** `string ("google")`
>
> \[Deprecated on 5 Aug 2024].
>
> **keyword\_list\_id** `integer`
>
> The id of an existing keyword list to show metrics for.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Fetch all backlinks
>
> **Slug:** `AHREFS_FETCH_ALL_BACKLINKS`
>
> Retrieves a comprehensive list of backlinks for a specified website or URL using Ahrefs' Site Explorer tool. This endpoint provides detailed information about the backlink profile of the target, including the source URLs, link attributes, and potentially other SEO metrics like Domain Rating (DR) or URL Rating (UR) of the linking pages. It's particularly useful for analyzing a website's link-building efforts, identifying potential link-building opportunities, and assessing the overall health of a site's backlink profile. The endpoint can handle large-scale backlink data, making it suitable for in-depth SEO analysis and competitive research. However, users should be aware that for websites with a substantial number of backlinks, multiple API calls or pagination may be necessary to retrieve the complete dataset.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **mode** `string ("exact" | "prefix" | "domain" | "subdomains")`
>
> The scope of the search based on the target you entered.
>
> **limit** `integer`
>
> The number of results to return.
>
> **where** `string`
>
> The filter expression. The following column identifiers are recognized (this differs from the identifiers recognized by the `select` parameter). **ahrefs\_rank\_source**: The strength of the referring domain"s backlink profile compared to the other websites in our database, with rank #1 being the strongest.   type: integer **ahrefs\_rank\_target**: The strength of the target domain"s backlink profile compared to the other websites in our database, with rank #1 being the strongest.   type: integer **alt**: The alt attribute of the link.   type: string nullable **anchor**: The clickable words in a link that point to a URL.   type: string **broken\_redirect\_new\_target**: The new destination of a modified redirect.   type: string nullable **broken\_redirect\_reason**: The reason the redirect was considered broken during the last crawl.   type: string nullable   enum: `"droppedmanual"` `"droppedtooold"` `"dropped"` `"codechanged"` `"nxdomain"` `"robotsdisallowed"` `"curlerror"` `"invalidtarget"` `"nomorecanonical"` `"isnowparked"` `"targetchanged"` **broken\_redirect\_source**: The redirecting URL that was modified, causing the redirect to become broken.   type: string nullable **class\_c** (5 units): The number of unique class\_c subnets linking to the referring page.   type: integer **discovered\_status**: The reason the link was discovered during the last crawl: the page was crawled for the first time, the link was added to the page, or the link re-appeared after being removed.   type: string nullable   enum: `"pagefound"` `"linkfound"` `"linkrestored"` **domain\_rating\_source**: The strength of the referring domain"s backlink profile compared to the others in our database on a 100-point scale.   type: float **domain\_rating\_target**: The strength of the referring domain"s backlink profile compared to the others in our database on a 100-point scale.   type: float **drop\_reason**: The reason we removed the link from our index.   type: string nullable   enum: `"manual"` `"noratingunused"` `"notop"` `"tooold"` `"oldunavailable"` `"rescursive"` `"duplicate"` `"nxdomain"` `"malformed"` `"blockedport"` `"disallowed"` `"unlinked"` **encoding**: The character set encoding of the referring page HTML.   type: string **first\_seen**: The date the referring page URL was first discovered.   type: datetime **first\_seen\_link**: The date we first found a backlink to your target on a given referring page.   type: datetime **http\_code**: The return code from HTTP protocol returned during the referring page crawl.   type: integer **http\_crawl**: The link was discovered without executing javascript and rendering the page.   type: boolean **ip\_source**: The referring domain IP address.   type: string nullable **is\_alternate**: The link with the rel=“alternate” attribute.   type: boolean **is\_canonical**: The link with the rel=“canonical” attribute.   type: boolean **is\_content**: The link was found in the biggest piece of content on the page.   type: boolean **is\_dofollow**: The link has no special nofollow attribute.   type: boolean **is\_form**: The link was found in a form HTML tag.   type: boolean **is\_frame**: The link was found in an iframe HTML tag.   type: boolean **is\_homepage\_link**: The link was found on the homepage of a referring website.   type: boolean **is\_image**: The link is a regular link that has an image inside their href attribute.   type: boolean **is\_lost**: The link currently does not exist anymore.   type: boolean **is\_new**: The link was discovered on the last crawl.   type: boolean **is\_nofollow**: The link or the referring page has the nofollow attribute set.   type: boolean **is\_non\_html**: The link points to a URL with non-HTML content.   type: boolean **is\_redirect**: The link pointing to your target via a redirect.   type: boolean **is\_redirect\_lost**: The redirected link currently does not exist anymore.   type: boolean **is\_root\_source**: The referring domain name is a root domain name.   type: boolean **is\_root\_target**: The target domain name is a root domain name.   type: boolean **is\_rss**: The link was found in an RSS feed.   type: boolean **is\_sponsored**: The link has the Sponsored attribute set in the referring page HTML.   type: boolean **is\_text**: The link is a standard href hyperlink.   type: boolean **is\_ugc**: The link has the User Generated Content attribute set in the referring page HTML.   type: boolean **js\_crawl**: The link was discovered after executing javascript and rendering the page.   type: boolean **languages**: The languages listed in the referring page metadata or detected by the crawler to appear in the HTML.   type: array(string) **last\_seen**: The date we discovered that the link was lost.   type: datetime nullable **last\_visited**: The date we last verified a live link to your target page.   type: datetime **len\_url\_redirect**: The number of redirect chain URLs.   type: integer **link\_group\_count**: The number of backlinks that were grouped together based on the aggregation parameter. This field cannot be used with aggregation "all".   type: integer **link\_type**: The kind of the backlink.   type: string   enum: `"redirect"` `"frame"` `"text"` `"form"` `"canonical"` `"alternate"` `"rss"` `"image"` **linked\_domains\_source\_domain**: The number of unique root domains linked from the referring domain.   type: integer **linked\_domains\_source\_page**: The number of unique root domains linked from the referring page.   type: integer **linked\_domains\_target\_domain**: The number of unique root domains linked from the target domain.   type: integer **links\_external**: The number of external links from the referring page.   type: integer **links\_internal**: The number of internal links from the referring page.   type: integer **lost\_reason**: The reason the link was lost during the last crawl.   type: string nullable   enum: `"removedfromhtml"` `"notcanonical"` `"noindex"` `"pageredirected"` `"pageerror"` `"lostredirect"` `"notfound"` **name\_source**: The complete referring domain name, including subdomains.   type: string **name\_target**: The complete target domain name, including subdomains.   type: string **noindex**: The referring page has the noindex meta attribute.   type: boolean **page\_size**: The size in bytes of the referring page content.   type: integer **port\_source**: The network port of the referring page URL.   type: integer **port\_target**: The network port of the target page URL.   type: integer **positions**: The number of keywords that the referring page ranks for in the top 100 positions.   type: integer **positions\_source\_domain**: The number of keywords that the referring domain ranks for in the top 100 positions.   type: integer **powered\_by**: Web technologies used to build and serve the referring page content.   type: array(string) **redirect\_code**: The HTTP status code of a referring page pointing to your target via a redirect.   type: integer nullable **redirect\_kind**: The HTTP status codes returned by the target redirecting URL or redirect chain.   type: array(integer) **refdomains\_source** (5 units): The number of unique referring domains linking to the referring page.   type: integer **refdomains\_source\_domain** (5 units): The number of unique referring domains linking to the referring domain.   type: integer **refdomains\_target\_domain** (5 units): The number of unique referring domains linking to the target domain.   type: integer **root\_name\_source**: The root domain name of the referring domain, not including subdomains.   type: string **root\_name\_target**: The root domain name of the target domain, not including subdomains.   type: string **snippet\_left**: The snippet of text appearing just before the link.   type: string **snippet\_right**: The snippet of text appearing just after the link.   type: string **source\_page\_author**: The author of the referring page.   type: string nullable **source\_page\_publish\_date**: the date we identified the page was published   type: date nullable **title**: The html title of the referring page.   type: string **tld\_class\_source**: The top level domain class of the referring domain.   type: string   enum: `"gov"` `"edu"` `"normal"` **tld\_class\_target**: The top level domain class of the target domain.   type: string   enum: `"gov"` `"edu"` `"normal"` **traffic** (10 units): The referring page"s estimated monthly organic traffic from search.   type: integer **traffic\_domain** (10 units): The referring domain"s estimated monthly organic traffic from search.   type: integer **url\_from**: The URL of the page containing a link to your target.   type: string **url\_from\_plain**: The referring page URL optimized for use as a filter.   type: string **url\_rating\_source**: The strength of the referring page"s backlink profile compared to the others in our database on a 100-point scale.   type: float **url\_redirect**: A redirect chain the target URL of the link points to.   type: array(url) **url\_redirect\_with\_target**: The target URL of the link with its redirect chain.   type: array(string) **url\_to**: The URL the backlink points to.   type: string **url\_to\_plain**: The target page URL optimized for use as a filter.   type: string
>
> **offset** `integer`
>
> \[Deprecated on 31 May 2024].
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **select** `string` *required*
>
> A comma-separated list of columns to return. See response schema for valid column identifiers.
>
> **target** `string` *required*
>
> The target of the search: a domain or a URL.
>
> **history** `string`
>
> A time frame to add lost backlinks to the report. Choose between `live` (no history), `since:<date>` (history since a specified date), and `all_time` (full history). The date should be in YYYY-MM-DD format.
>
> **timeout** `integer`
>
> A manual timeout duration in seconds.
>
> **order\_by** `string`
>
> A column to order results by. See response schema for valid column identifiers.
>
> **protocol** `string ("both" | "http" | "https")`
>
> The protocol of your target.
>
> **aggregation** `string ("similar_links" | "1_per_domain" | "all")`
>
> The backlinks grouping mode.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Fetch broken backlinks data
>
> **Slug:** `AHREFS_FETCH_BROKEN_BACKLINKS_DATA`
>
> Retrieves a list of broken backlinks for a specified website using Ahrefs' Site Explorer tool. This endpoint helps identify and analyze backlinks that are no longer functional, potentially affecting the website's SEO performance. It should be used when conducting a backlink audit, cleaning up a website's link profile, or identifying opportunities for link reclamation. The tool provides detailed information about each broken backlink, including the referring page, anchor text, and the specific broken URL. It's important to note that this endpoint may have limitations on the number of results returned and may require additional API calls for pagination if there are many broken backlinks.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **mode** `string ("exact" | "prefix" | "domain" | "subdomains")`
>
> The scope of the search based on the target you entered.
>
> **limit** `integer`
>
> The number of results to return.
>
> **where** `string`
>
> The filter expression. The following column identifiers are recognized (this differs from the identifiers recognized by the `select` parameter). **ahrefs\_rank\_source**: The strength of the referring domain"s backlink profile compared to the other websites in our database, with rank #1 being the strongest.   type: integer **ahrefs\_rank\_target**: The strength of the target domain"s backlink profile compared to the other websites in our database, with rank #1 being the strongest.   type: integer **alt**: The alt attribute of the link.   type: string nullable **anchor**: The clickable words in a link that point to a URL.   type: string **class\_c** (5 units): The number of unique class\_c subnets linking to the referring page.   type: integer **domain\_rating\_source**: The strength of the referring domain"s backlink profile compared to the others in our database on a 100-point scale.   type: float **domain\_rating\_target**: The strength of the referring domain"s backlink profile compared to the others in our database on a 100-point scale.   type: float **encoding**: The character set encoding of the referring page HTML.   type: string **first\_seen**: The date the referring page URL was first discovered.   type: datetime **first\_seen\_link**: The date we first found a backlink to your target on a given referring page.   type: datetime **http\_code**: The return code from HTTP protocol returned during the referring page crawl.   type: integer **http\_code\_target**: The return code from HTTP protocol returned during the target page crawl.   type: integer nullable **http\_crawl**: The link was discovered without executing javascript and rendering the page.   type: boolean **ip\_source**: The referring domain IP address.   type: string nullable **is\_alternate**: The link with the rel=“alternate” attribute.   type: boolean **is\_canonical**: The link with the rel=“canonical” attribute.   type: boolean **is\_content**: The link was found in the biggest piece of content on the page.   type: boolean **is\_dofollow**: The link has no special nofollow attribute.   type: boolean **is\_form**: The link was found in a form HTML tag.   type: boolean **is\_frame**: The link was found in an iframe HTML tag.   type: boolean **is\_homepage\_link**: The link was found on the homepage of a referring website.   type: boolean **is\_image**: The link is a regular link that has an image inside their href attribute.   type: boolean **is\_nofollow**: The link or the referring page has the nofollow attribute set.   type: boolean **is\_non\_html**: The link points to a URL with non-HTML content.   type: boolean **is\_redirect**: The link pointing to your target via a redirect.   type: boolean **is\_root\_source**: The referring domain name is a root domain name.   type: boolean **is\_root\_target**: The target domain name is a root domain name.   type: boolean **is\_rss**: The link was found in an RSS feed.   type: boolean **is\_sponsored**: The link has the Sponsored attribute set in the referring page HTML.   type: boolean **is\_text**: The link is a standard href hyperlink.   type: boolean **is\_ugc**: The link has the User Generated Content attribute set in the referring page HTML.   type: boolean **js\_crawl**: The link was discovered after executing javascript and rendering the page.   type: boolean **languages**: The languages listed in the referring page metadata or detected by the crawler to appear in the HTML.   type: array(string) **last\_seen**: The date we discovered that the link was lost.   type: datetime nullable **last\_visited**: The date we last re-crawled the referring page to verify the backlink is alive.   type: datetime **last\_visited\_target**: The date we last re-crawled the target page to verify that it is broken.   type: datetime nullable **len\_url\_redirect**: The number of redirect chain URLs.   type: integer **link\_group\_count**: The number of backlinks that were grouped together based on the aggregation parameter. This field cannot be used with aggregation "all".   type: integer **link\_type**: The kind of the backlink.   type: string   enum: `"redirect"` `"frame"` `"text"` `"form"` `"canonical"` `"alternate"` `"rss"` `"image"` **linked\_domains\_source\_domain**: The number of unique root domains linked from the referring domain.   type: integer **linked\_domains\_source\_page**: The number of unique root domains linked from the referring page.   type: integer **linked\_domains\_target\_domain**: The number of unique root domains linked from the target domain.   type: integer **links\_external**: The number of external links from the referring page.   type: integer **links\_internal**: The number of internal links from the referring page.   type: integer **name\_source**: The complete referring domain name, including subdomains.   type: string **name\_target**: The complete target domain name, including subdomains.   type: string **page\_size**: The size in bytes of the referring page content.   type: integer **port\_source**: The network port of the referring page URL.   type: integer **port\_target**: The network port of the target page URL.   type: integer **positions**: The number of keywords that the referring page ranks for in the top 100 positions.   type: integer **positions\_source\_domain**: The number of keywords that the referring domain ranks for in the top 100 positions.   type: integer **powered\_by**: Web technologies used to build and serve the referring page content.   type: array(string) **redirect\_code**: The HTTP status code of a referring page pointing to your target via a redirect.   type: integer nullable **redirect\_kind**: The HTTP status codes returned by the target redirecting URL or redirect chain.   type: array(integer) **refdomains\_source** (5 units): The number of unique referring domains linking to the referring page.   type: integer **refdomains\_source\_domain** (5 units): The number of unique referring domains linking to the referring domain.   type: integer **refdomains\_target\_domain** (5 units): The number of unique referring domains linking to the target domain.   type: integer **root\_name\_source**: The root domain name of the referring domain, not including subdomains.   type: string **root\_name\_target**: The root domain name of the target domain, not including subdomains.   type: string **snippet\_left**: The snippet of text appearing just before the link.   type: string **snippet\_right**: The snippet of text appearing just after the link.   type: string **source\_page\_author**: The author of the referring page.   type: string nullable **title**: The html title of the referring page.   type: string **tld\_class\_source**: The top level domain class of the referring domain.   type: string   enum: `"gov"` `"edu"` `"normal"` **tld\_class\_target**: The top level domain class of the target domain.   type: string   enum: `"gov"` `"edu"` `"normal"` **traffic** (10 units): The referring page"s estimated monthly organic traffic from search.   type: integer **traffic\_domain** (10 units): The referring domain"s estimated monthly organic traffic from search.   type: integer **url\_from**: The URL of the page containing a link to your target.   type: string **url\_from\_plain**: The referring page URL optimized for use as a filter.   type: string **url\_rating\_source**: The strength of the referring page"s backlink profile compared to the others in our database on a 100-point scale.   type: float **url\_redirect**: A redirect chain the target URL of the link points to.   type: array(url) **url\_redirect\_with\_target**: The target URL of the link with its redirect chain.   type: array(string) **url\_to**: The URL the backlink points to.   type: string **url\_to\_plain**: The target page URL optimized for use as a filter.   type: string
>
> **offset** `integer`
>
> \[Deprecated on 31 May 2024].
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **select** `string` *required*
>
> A comma-separated list of columns to return. See response schema for valid column identifiers.
>
> **target** `string` *required*
>
> The target of the search: a domain or a URL.
>
> **timeout** `integer`
>
> A manual timeout duration in seconds.
>
> **order\_by** `string`
>
> A column to order results by. See response schema for valid column identifiers.
>
> **protocol** `string ("both" | "http" | "https")`
>
> The protocol of your target.
>
> **aggregation** `string ("similar_links" | "1_per_domain" | "all")`
>
> The backlinks grouping mode.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Fetch competitors overview
>
> **Slug:** `AHREFS_FETCH_COMPETITORS_OVERVIEW`
>
> Retrieves a Rank Tracker competitor overview for a project, including comparative keyword ranking and organic search performance data. Requires a connected Ahrefs account; managed Ahrefs credentials cannot access this action.
>
> #### Input Parameters
>
> **date** `string` *required*
>
> A date to report metrics on in YYYY-MM-DD format.
>
> **limit** `integer`
>
> The number of results to return.
>
> **where** `string`
>
> The filter expression. The following column identifiers are recognized (this differs from the identifiers recognized by the `select` parameter). **country**: The country that a given keyword is being tracked in. A two-letter country code (ISO 3166-1 alpha-2).   type: string   enum: `"AD"` `"AE"` `"AF"` `"AG"` `"AI"` `"AL"` `"AM"` `"AO"` `"AQ"` `"AR"` `"AS"` `"AT"` `"AU"` `"AW"` `"AX"` `"AZ"` `"BA"` `"BB"` `"BD"` `"BE"` `"BF"` `"BG"` `"BH"` `"BI"` `"BJ"` `"BL"` `"BM"` `"BN"` `"BO"` `"BQ"` `"BR"` `"BS"` `"BT"` `"BV"` `"BW"` `"BY"` `"BZ"` `"CA"` `"CC"` `"CD"` `"CF"` `"CG"` `"CH"` `"CI"` `"CK"` `"CL"` `"CM"` `"CN"` `"CO"` `"CR"` `"CU"` `"CV"` `"CW"` `"CX"` `"CY"` `"CZ"` `"DE"` `"DJ"` `"DK"` `"DM"` `"DO"` `"DZ"` `"EC"` `"EE"` `"EG"` `"EH"` `"ER"` `"ES"` `"ET"` `"FI"` `"FJ"` `"FK"` `"FM"` `"FO"` `"FR"` `"GA"` `"GB"` `"GD"` `"GE"` `"GF"` `"GG"` `"GH"` `"GI"` `"GL"` `"GM"` `"GN"` `"GP"` `"GQ"` `"GR"` `"GS"` `"GT"` `"GU"` `"GW"` `"GY"` `"HK"` `"HM"` `"HN"` `"HR"` `"HT"` `"HU"` `"ID"` `"IE"` `"IL"` `"IM"` `"IN"` `"IO"` `"IQ"` `"IR"` `"IS"` `"IT"` `"JE"` `"JM"` `"JO"` `"JP"` `"KE"` `"KG"` `"KH"` `"KI"` `"KM"` `"KN"` `"KP"` `"KR"` `"KW"` `"KY"` `"KZ"` `"LA"` `"LB"` `"LC"` `"LI"` `"LK"` `"LR"` `"LS"` `"LT"` `"LU"` `"LV"` `"LY"` `"MA"` `"MC"` `"MD"` `"ME"` `"MF"` `"MG"` `"MH"` `"MK"` `"ML"` `"MM"` `"MN"` `"MO"` `"MP"` `"MQ"` `"MR"` `"MS"` `"MT"` `"MU"` `"MV"` `"MW"` `"MX"` `"MY"` `"MZ"` `"NA"` `"NC"` `"NE"` `"NF"` `"NG"` `"NI"` `"NL"` `"NO"` `"NP"` `"NR"` `"NU"` `"NZ"` `"OM"` `"OTHER"` `"PA"` `"PE"` `"PF"` `"PG"` `"PH"` `"PK"` `"PL"` `"PM"` `"PN"` `"PR"` `"PS"` `"PT"` `"PW"` `"PY"` `"QA"` `"RE"` `"RO"` `"RS"` `"RU"` `"RW"` `"SA"` `"SB"` `"SC"` `"SD"` `"SE"` `"SG"` `"SH"` `"SI"` `"SJ"` `"SK"` `"SL"` `"SM"` `"SN"` `"SO"` `"SR"` `"SS"` `"ST"` `"SV"` `"SX"` `"SY"` `"SZ"` `"TC"` `"TD"` `"TF"` `"TG"` `"TH"` `"TJ"` `"TK"` `"TL"` `"TM"` `"TN"` `"TO"` `"TR"` `"TT"` `"TV"` `"TW"` `"TZ"` `"UA"` `"UG"` `"UM"` `"US"` `"UY"` `"UZ"` `"VA"` `"VC"` `"VE"` `"VG"` `"VI"` `"VN"` `"VU"` `"WF"` `"WS"` `"YE"` `"YT"` `"ZA"` `"ZM"` `"ZW"` **keyword**: The keyword your target ranks for.   type: string **keyword\_difficulty**: An estimation of how hard it is to rank in the top 10 organic search results for a keyword on a 100-point scale.   type: integer nullable **keyword\_has\_data**: Will return `false` if the keyword is still processing and no SERP has been fetched yet.   type: boolean **keyword\_is\_frozen**: Indicates whether a keyword has exceeded the tracked keywords limit on your plan. Such keywords are "frozen", meaning they do not have their rankings updated.   type: boolean **language**: The SERP language that a given keyword is being tracked for.   type: string **location**: The location (country, state/province, or city) that a given keyword is being tracked in.   type: string **serp\_features**: The SERP features that appear in search results for a keyword.   type: array(string)   enum: `"paid_top"` `"paid_bottom"` `"paid_right"` `"paid_sitelink"` `"organic"` `"sitelink"` `"snippet"` `"image"` `"article"` `"knowledge_card"` `"knowledge_panel"` `"local_pack"` `"local_teaser"` `"news"` `"question"` `"review"` `"shopping"` `"tweet"` `"spelling"` `"video"` `"discussion"` `"ai_overview"` `"ai_overview_sitelink"` `"organic_shopping"` `"image_th"` `"video_th"` `"ai_overview_found"` **serp\_updated**: The date when we last checked search engine results for a keyword.   type: datetime nullable **tags**: A list of tags assigned to a given keyword.   type: array(string) **volume**: An estimation of the average monthly number of searches for a keyword over the latest month or over the latest known 12 months of data depending on the "volume\_mode" parameter.   type: integer nullable
>
> **device** `string ("desktop" | "mobile")` *required*
>
> Choose between mobile and desktop rankings.
>
> **offset** `integer`
>
> \[Deprecated on 31 May 2024].
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **select** `string` *required*
>
> A comma-separated list of columns to return. See response schema for valid column identifiers.
>
> **timeout** `integer`
>
> A manual timeout duration in seconds.
>
> **order\_by** `string`
>
> A column to order results by. See response schema for valid column identifiers.
>
> **project\_id** `integer` *required*
>
> The unique identifier of the project. You can find it in the URL of your Rank Tracker project in Ahrefs: `https://app.ahrefs.com/rank-tracker/overview/#project_id#`
>
> **volume\_mode** `string ("monthly" | "average")`
>
> The search volume calculation mode: monthly or average. It affects volume, traffic, and traffic value.
>
> **date\_compared** `string`
>
> A date to compare metrics with in YYYY-MM-DD format.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Fetch rank tracker overview
>
> **Slug:** `AHREFS_FETCH_RANK_TRACKER_OVERVIEW`
>
> Retrieves an Ahrefs Rank Tracker overview for a project, date and device, with ranking and search-performance metrics. Requires a connected Ahrefs account.
>
> #### Input Parameters
>
> **date** `string` *required*
>
> A date to report metrics on in YYYY-MM-DD format.
>
> **limit** `integer`
>
> The number of results to return.
>
> **where** `string`
>
> The filter expression. The following column identifiers are recognized (this differs from the identifiers recognized by the `select` parameter). **best\_position\_has\_thumbnail**: The top position has a thumbnail.   type: boolean nullable **best\_position\_has\_thumbnail\_previous**: The top position has a thumbnail on the comparison date.   type: boolean nullable **best\_position\_has\_video\_preview**: The top position has a video preview.   type: boolean nullable **best\_position\_has\_video\_preview\_previous**: The top position has a video preview on the comparison date.   type: boolean nullable **best\_position\_kind**: The kind of the top position: organic, paid, or a SERP feature.   type: string nullable   enum: `"paid_top"` `"paid_bottom"` `"paid_right"` `"paid_sitelink"` `"organic"` `"sitelink"` `"snippet"` `"image"` `"article"` `"knowledge_card"` `"knowledge_panel"` `"local_pack"` `"local_teaser"` `"news"` `"question"` `"review"` `"shopping"` `"tweet"` `"spelling"` `"video"` `"discussion"` `"ai_overview"` `"ai_overview_sitelink"` `"organic_shopping"` **best\_position\_kind\_previous**: The kind of the top position on the comparison date.   type: string nullable   enum: `"paid_top"` `"paid_bottom"` `"paid_right"` `"paid_sitelink"` `"organic"` `"sitelink"` `"snippet"` `"image"` `"article"` `"knowledge_card"` `"knowledge_panel"` `"local_pack"` `"local_teaser"` `"news"` `"question"` `"review"` `"shopping"` `"tweet"` `"spelling"` `"video"` `"discussion"` `"ai_overview"` `"ai_overview_sitelink"` `"organic_shopping"` **clicks**: Clicks metric refers to the average monthly number of clicks on the search results that people make while searching for the target keyword. Some searches generate clicks on multiple results, while others might not end in any clicks at all.   type: integer nullable **clicks\_per\_search**: Clicks Per Search is the ratio of Clicks to Keyword Search volume. It shows how many different search results get clicked, on average, when people search for the target keyword in a given country.   type: float nullable **cost\_per\_click**: Cost Per Click shows the average price that advertisers pay for each ad click in paid search results for a keyword.   type: integer nullable **country**: The country that a given keyword is being tracked in. A two-letter country code (ISO 3166-1 alpha-2).   type: string   enum: `"AD"` `"AE"` `"AF"` `"AG"` `"AI"` `"AL"` `"AM"` `"AO"` `"AQ"` `"AR"` `"AS"` `"AT"` `"AU"` `"AW"` `"AX"` `"AZ"` `"BA"` `"BB"` `"BD"` `"BE"` `"BF"` `"BG"` `"BH"` `"BI"` `"BJ"` `"BL"` `"BM"` `"BN"` `"BO"` `"BQ"` `"BR"` `"BS"` `"BT"` `"BV"` `"BW"` `"BY"` `"BZ"` `"CA"` `"CC"` `"CD"` `"CF"` `"CG"` `"CH"` `"CI"` `"CK"` `"CL"` `"CM"` `"CN"` `"CO"` `"CR"` `"CU"` `"CV"` `"CW"` `"CX"` `"CY"` `"CZ"` `"DE"` `"DJ"` `"DK"` `"DM"` `"DO"` `"DZ"` `"EC"` `"EE"` `"EG"` `"EH"` `"ER"` `"ES"` `"ET"` `"FI"` `"FJ"` `"FK"` `"FM"` `"FO"` `"FR"` `"GA"` `"GB"` `"GD"` `"GE"` `"GF"` `"GG"` `"GH"` `"GI"` `"GL"` `"GM"` `"GN"` `"GP"` `"GQ"` `"GR"` `"GS"` `"GT"` `"GU"` `"GW"` `"GY"` `"HK"` `"HM"` `"HN"` `"HR"` `"HT"` `"HU"` `"ID"` `"IE"` `"IL"` `"IM"` `"IN"` `"IO"` `"IQ"` `"IR"` `"IS"` `"IT"` `"JE"` `"JM"` `"JO"` `"JP"` `"KE"` `"KG"` `"KH"` `"KI"` `"KM"` `"KN"` `"KP"` `"KR"` `"KW"` `"KY"` `"KZ"` `"LA"` `"LB"` `"LC"` `"LI"` `"LK"` `"LR"` `"LS"` `"LT"` `"LU"` `"LV"` `"LY"` `"MA"` `"MC"` `"MD"` `"ME"` `"MF"` `"MG"` `"MH"` `"MK"` `"ML"` `"MM"` `"MN"` `"MO"` `"MP"` `"MQ"` `"MR"` `"MS"` `"MT"` `"MU"` `"MV"` `"MW"` `"MX"` `"MY"` `"MZ"` `"NA"` `"NC"` `"NE"` `"NF"` `"NG"` `"NI"` `"NL"` `"NO"` `"NP"` `"NR"` `"NU"` `"NZ"` `"OM"` `"OTHER"` `"PA"` `"PE"` `"PF"` `"PG"` `"PH"` `"PK"` `"PL"` `"PM"` `"PN"` `"PR"` `"PS"` `"PT"` `"PW"` `"PY"` `"QA"` `"RE"` `"RO"` `"RS"` `"RU"` `"RW"` `"SA"` `"SB"` `"SC"` `"SD"` `"SE"` `"SG"` `"SH"` `"SI"` `"SJ"` `"SK"` `"SL"` `"SM"` `"SN"` `"SO"` `"SR"` `"SS"` `"ST"` `"SV"` `"SX"` `"SY"` `"SZ"` `"TC"` `"TD"` `"TF"` `"TG"` `"TH"` `"TJ"` `"TK"` `"TL"` `"TM"` `"TN"` `"TO"` `"TR"` `"TT"` `"TV"` `"TW"` `"TZ"` `"UA"` `"UG"` `"UM"` `"US"` `"UY"` `"UZ"` `"VA"` `"VC"` `"VE"` `"VG"` `"VI"` `"VN"` `"VU"` `"WF"` `"WS"` `"YE"` `"YT"` `"ZA"` `"ZM"` `"ZW"` **country\_prev**: The country that a given keyword is being tracked in on the comparison date. A two-letter country code (ISO 3166-1 alpha-2).   type: string   enum: `"AD"` `"AE"` `"AF"` `"AG"` `"AI"` `"AL"` `"AM"` `"AO"` `"AQ"` `"AR"` `"AS"` `"AT"` `"AU"` `"AW"` `"AX"` `"AZ"` `"BA"` `"BB"` `"BD"` `"BE"` `"BF"` `"BG"` `"BH"` `"BI"` `"BJ"` `"BL"` `"BM"` `"BN"` `"BO"` `"BQ"` `"BR"` `"BS"` `"BT"` `"BV"` `"BW"` `"BY"` `"BZ"` `"CA"` `"CC"` `"CD"` `"CF"` `"CG"` `"CH"` `"CI"` `"CK"` `"CL"` `"CM"` `"CN"` `"CO"` `"CR"` `"CU"` `"CV"` `"CW"` `"CX"` `"CY"` `"CZ"` `"DE"` `"DJ"` `"DK"` `"DM"` `"DO"` `"DZ"` `"EC"` `"EE"` `"EG"` `"EH"` `"ER"` `"ES"` `"ET"` `"FI"` `"FJ"` `"FK"` `"FM"` `"FO"` `"FR"` `"GA"` `"GB"` `"GD"` `"GE"` `"GF"` `"GG"` `"GH"` `"GI"` `"GL"` `"GM"` `"GN"` `"GP"` `"GQ"` `"GR"` `"GS"` `"GT"` `"GU"` `"GW"` `"GY"` `"HK"` `"HM"` `"HN"` `"HR"` `"HT"` `"HU"` `"ID"` `"IE"` `"IL"` `"IM"` `"IN"` `"IO"` `"IQ"` `"IR"` `"IS"` `"IT"` `"JE"` `"JM"` `"JO"` `"JP"` `"KE"` `"KG"` `"KH"` `"KI"` `"KM"` `"KN"` `"KP"` `"KR"` `"KW"` `"KY"` `"KZ"` `"LA"` `"LB"` `"LC"` `"LI"` `"LK"` `"LR"` `"LS"` `"LT"` `"LU"` `"LV"` `"LY"` `"MA"` `"MC"` `"MD"` `"ME"` `"MF"` `"MG"` `"MH"` `"MK"` `"ML"` `"MM"` `"MN"` `"MO"` `"MP"` `"MQ"` `"MR"` `"MS"` `"MT"` `"MU"` `"MV"` `"MW"` `"MX"` `"MY"` `"MZ"` `"NA"` `"NC"` `"NE"` `"NF"` `"NG"` `"NI"` `"NL"` `"NO"` `"NP"` `"NR"` `"NU"` `"NZ"` `"OM"` `"OTHER"` `"PA"` `"PE"` `"PF"` `"PG"` `"PH"` `"PK"` `"PL"` `"PM"` `"PN"` `"PR"` `"PS"` `"PT"` `"PW"` `"PY"` `"QA"` `"RE"` `"RO"` `"RS"` `"RU"` `"RW"` `"SA"` `"SB"` `"SC"` `"SD"` `"SE"` `"SG"` `"SH"` `"SI"` `"SJ"` `"SK"` `"SL"` `"SM"` `"SN"` `"SO"` `"SR"` `"SS"` `"ST"` `"SV"` `"SX"` `"SY"` `"SZ"` `"TC"` `"TD"` `"TF"` `"TG"` `"TH"` `"TJ"` `"TK"` `"TL"` `"TM"` `"TN"` `"TO"` `"TR"` `"TT"` `"TV"` `"TW"` `"TZ"` `"UA"` `"UG"` `"UM"` `"US"` `"UY"` `"UZ"` `"VA"` `"VC"` `"VE"` `"VG"` `"VI"` `"VN"` `"VU"` `"WF"` `"WS"` `"YE"` `"YT"` `"ZA"` `"ZM"` `"ZW"` **is\_main\_position**: Excludes positions in Sitelinks, Top stories, Image packs, and posts on X (Twitter).   type: boolean **is\_main\_position\_prev**: Excludes positions in Sitelinks, Top stories, Image packs, and posts on X (Twitter) on the comparison date.   type: boolean **keyword**: The keyword your target ranks for.   type: string **keyword\_difficulty**: An estimation of how hard it is to rank in the top 10 organic search results for a keyword on a 100-point scale.   type: integer nullable **keyword\_has\_data**: Will return `false` if the keyword is still processing and no SERP has been fetched yet.   type: boolean **keyword\_is\_frozen**: Indicates whether a keyword has exceeded the tracked keywords limit on your plan. Such keywords are "frozen", meaning they do not have their rankings updated.   type: boolean **keyword\_prev**: The keyword your target ranks for on the comparison date.   type: string **keyword\_words**: The number of words in a keyword.   type: integer **keyword\_words\_prev**: The number of words in a keyword on the comparison date.   type: integer **language**: The SERP language that a given keyword is being tracked for.   type: string **language\_prev**: The SERP language on the comparison date.   type: string **location**: The location (country, state/province, or city) that a given keyword is being tracked in.   type: string **location\_prev**: The location (country, state/province, or city) that a given keyword is being tracked in on the comparison date.   type: string **parent\_topic**: Parent Topic determines if you can rank for your target keyword while targeting a more general topic on your page instead.  To identify the Parent Topic, we take the #1 ranking page for your keyword and find the keyword responsible for sending the most traffic to that page.   type: string nullable **position**: The top position your target ranks for in the organic search results for a keyword.   type: integer nullable **position\_diff**: The change in position between your selected dates.   type: integer nullable **position\_prev**: The top position on the comparison date.   type: integer nullable **search\_type\_image**: Search type Image shows the percentage of searches for a keyword made for images, highlighting interest in visual content.   type: float nullable **search\_type\_news**: Search type News shows the percentage of searches for a keyword made for news articles.   type: float nullable **search\_type\_video**: Search type Video shows the percentage of searches for a keyword made for video, reflecting interest in video content.   type: float nullable **search\_type\_web**: Search type Web shows the percentage of searches for a keyword made for general web content, indicating interest in a wide range of information.   type: float nullable **serp\_features**: The SERP features that appear in search results for a keyword.   type: array(string)   enum: `"paid_top"` `"paid_bottom"` `"paid_right"` `"paid_sitelink"` `"organic"` `"sitelink"` `"snippet"` `"image"` `"article"` `"knowledge_card"` `"knowledge_panel"` `"local_pack"` `"local_teaser"` `"news"` `"question"` `"review"` `"shopping"` `"tweet"` `"spelling"` `"video"` `"discussion"` `"ai_overview"` `"ai_overview_sitelink"` `"organic_shopping"` `"image_th"` `"video_th"` `"ai_overview_found"` **serp\_updated**: The date when we last checked search engine results for a keyword.   type: datetime nullable **serp\_updated\_prev**: The date when we checked search engine results up to the comparison date.   type: datetime nullable **tags**: A list of tags assigned to a given keyword.   type: array(string) **tags\_prev**: A list of tags assigned to a given keyword on the comparison date.   type: array(string) **target\_positions\_count**: The number of target URLs ranking for a keyword.   type: integer **traffic**: An estimation of the number of monthly visits that a page gets from organic search over the latest month or over the latest known 12 months of data depending on the "volume\_mode" parameter.   type: integer nullable **traffic\_diff**: The change in traffic between your selected dates.   type: integer nullable **traffic\_prev**: An estimation of the number of monthly visits that a page gets from organic search over the latest month or over the latest known 12 months of data depending on the "volume\_mode" parameter.   type: integer nullable **url**: The top ranking URL in organic search results for a given keyword.   type: string nullable **url\_prev**: The top ranking URL in organic search results for a given keyword on the comparison date.   type: string nullable **volume**: An estimation of the average monthly number of searches for a keyword over the latest month or over the latest known 12 months of data depending on the "volume\_mode" parameter.   type: integer nullable
>
> **device** `string ("desktop" | "mobile")` *required*
>
> Choose between mobile and desktop rankings.
>
> **offset** `integer`
>
> \[Deprecated on 31 May 2024].
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **select** `string` *required*
>
> A comma-separated list of columns to return. See response schema for valid column identifiers.
>
> **timeout** `integer`
>
> A manual timeout duration in seconds.
>
> **order\_by** `string`
>
> A column to order results by. See response schema for valid column identifiers.
>
> **project\_id** `integer` *required*
>
> The unique identifier of the project. You can find it in the URL of your Rank Tracker project in Ahrefs: `https://app.ahrefs.com/rank-tracker/overview/#project_id#`
>
> **volume\_mode** `string ("monthly" | "average")`
>
> The search volume calculation mode: monthly or average. It affects volume, traffic, and traffic value.
>
> **date\_compared** `string`
>
> A date to compare metrics with in YYYY-MM-DD format.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Fetch site explorer referring domains
>
> **Slug:** `AHREFS_FETCH_SITE_EXPLORER_REFERRING_DOMAINS`
>
> Retrieves a list of domains that have backlinks pointing to a specified target website. This endpoint is essential for conducting comprehensive backlink analysis, allowing users to identify and evaluate the sources of incoming links to their website. It provides valuable data for assessing the strength and quality of a site's backlink profile, which is crucial for SEO strategies and competitor analysis. The endpoint returns detailed information about each referring domain, likely including metrics such as Domain Rating (DR), number of backlinks, and first seen date. It should be used when analyzing a website's backlink structure, identifying potential link-building opportunities, or auditing the quality of incoming links. Note that while this endpoint provides aggregate data about referring domains, it does not offer specifics about individual backlinks or anchor texts.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **mode** `string ("exact" | "prefix" | "domain" | "subdomains")`
>
> The scope of the search based on the target you entered.
>
> **limit** `integer`
>
> The number of results to return.
>
> **where** `string`
>
> The filter expression. The following column identifiers are recognized (this differs from the identifiers recognized by the `select` parameter). **anchor**: The clickable words in a link that point to a URL.   type: string **discovered\_status**: The reason the link was discovered during the last crawl: the page was crawled for the first time, the link was added to the page, or the link re-appeared after being removed.   type: string nullable   enum: `"pagefound"` `"linkfound"` `"linkrestored"` **dofollow\_linked\_domains**: The number of unique root domains with dofollow links linked from the referring domain.   type: integer **dofollow\_links**: The number of links from the referring domain to your target that don"t have the "nofollow" attribute.   type: integer **dofollow\_refdomains** (5 units): The number of unique domains with dofollow links to the referring domain.   type: integer **domain**: A referring domain that has at least one link to your target.   type: string **domain\_rating**: The strength of a domain"s backlink profile compared to the others in our database on a 100-point scale.   type: float **drop\_reason**: The reason we removed the link from our index.   type: string nullable   enum: `"manual"` `"noratingunused"` `"notop"` `"tooold"` `"oldunavailable"` `"rescursive"` `"duplicate"` `"nxdomain"` `"malformed"` `"blockedport"` `"disallowed"` `"unlinked"` **first\_seen**: The date we first found a backlink to your target from the referring domain.   type: datetime **ip\_source**: The referring domain IP address.   type: string nullable **is\_content**: The link was found in the biggest piece of content on the page.   type: boolean **is\_dofollow**: The link has no special nofollow attribute.   type: boolean **is\_homepage\_link**: The link was found on the homepage of a referring website.   type: boolean **is\_nofollow**: The link or the referring page has the nofollow attribute set.   type: boolean **is\_non\_html**: The link points to a URL with non-HTML content.   type: boolean **is\_root\_domain**: The domain name is a root domain name.   type: boolean **is\_sponsored**: The link has the Sponsored attribute set in the referring page HTML.   type: boolean **is\_ugc**: The link has the User Generated Content attribute set in the referring page HTML.   type: boolean **languages**: The languages listed in the referring page metadata or detected by the crawler to appear in the HTML.   type: array(string) **last\_seen**: The date your target lost its last live backlink for the referring domain.   type: datetime nullable **len\_url\_redirect**: The number of redirect chain URLs.   type: integer **link\_type**: The kind of the backlink.   type: string   enum: `"redirect"` `"frame"` `"text"` `"form"` `"canonical"` `"alternate"` `"rss"` `"image"` **linked\_domains**: The number of unique root domains linked from the referring page.   type: integer **links\_external**: The number of external links from the referring page.   type: integer **links\_to\_target**: The number of backlinks from the referring domain to your target.   type: integer **lost\_links**: The number of backlinks lost from the referring domain for the selected time period.   type: integer **lost\_reason**: The reason the link was lost during the last crawl.   type: string nullable   enum: `"removedfromhtml"` `"notcanonical"` `"noindex"` `"pageredirected"` `"pageerror"` `"lostredirect"` `"notfound"` **new\_links**: The number of new backlinks found from the referring domain for the selected time period.   type: integer **noindex**: The referring page has the noindex meta attribute.   type: boolean **port\_source**: The network port of the referring page URL.   type: integer **port\_target**: The network port of the target page URL.   type: integer **positions**: The number of keywords that the referring page ranks for in the top 100 positions.   type: integer **positions\_source\_domain**: The number of keywords that the referring domain ranks for in the top 100 positions.   type: integer **powered\_by**: Web technologies used to build and serve the referring page content.   type: array(string) **refdomains** (5 units): The number of unique referring domains linking to the referring page.   type: integer **root\_domain\_name**: The root domain name of the referring domain, not including subdomains.   type: string **snippet\_left**: The snippet of text appearing just before the link.   type: string **snippet\_right**: The snippet of text appearing just after the link.   type: string **source\_page\_author**: The author of the referring page.   type: string nullable **title**: The html title of the referring page.   type: string **traffic\_domain** (10 units): The referring domain"s estimated monthly organic traffic from search.   type: integer **traffic\_page** (10 units): The referring page"s estimated monthly organic traffic from search.   type: integer **url\_from**: The URL of the page containing a link to your target.   type: string **url\_redirect**: A redirect chain the target URL of the link points to.   type: array(url) **url\_redirect\_with\_target**: The target URL of the link with its redirect chain.   type: array(string) **url\_to**: The URL the backlink points to.   type: string
>
> **offset** `integer`
>
> \[Deprecated on 31 May 2024].
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **select** `string` *required*
>
> A comma-separated list of columns to return. See response schema for valid column identifiers.
>
> **target** `string` *required*
>
> The target of the search: a domain or a URL.
>
> **history** `string`
>
> A time frame to add lost backlinks to the report. Choose between `live` (no history), `since:<date>` (history since a specified date), and `all_time` (full history). The date should be in YYYY-MM-DD format.
>
> **timeout** `integer`
>
> A manual timeout duration in seconds.
>
> **order\_by** `string`
>
> A column to order results by. See response schema for valid column identifiers.
>
> **protocol** `string ("both" | "http" | "https")`
>
> The protocol of your target.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Fetch total search volume history
>
> **Slug:** `AHREFS_FETCH_TOTAL_SEARCH_VOLUME_HISTORY`
>
> Retrieves historical total search volume for keywords associated with a target domain or URL using Ahrefs Site Explorer. The history can be grouped over time and scoped by country and top organic positions.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **mode** `string ("exact" | "prefix" | "domain" | "subdomains")`
>
> The scope of the search based on the target you entered.
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **target** `string` *required*
>
> The target of the search: a domain or a URL.
>
> **country** `string ("ad" | "ae" | "af" | "ag" | "ai" | "al" | "am" | "ao" | "ar" | "as" | "at" | "au" | "aw" | "az" | "ba" | "bb" | "bd" | "be" | "bf" | "bg" | "bh" | "bi" | "bj" | "bn" | "bo" | "br" | "bs" | "bt" | "bw" | "by" | "bz" | "ca" | "cd" | "cf" | "cg" | "ch" | "ci" | "ck" | "cl" | "cm" | "cn" | "co" | "cr" | "cu" | "cv" | "cy" | "cz" | "de" | "dj" | "dk" | "dm" | "do" | "dz" | "ec" | "ee" | "eg" | "es" | "et" | "fi" | "fj" | "fm" | "fo" | "fr" | "ga" | "gb" | "gd" | "ge" | "gf" | "gg" | "gh" | "gi" | "gl" | "gm" | "gn" | "gp" | "gq" | "gr" | "gt" | "gu" | "gy" | "hk" | "hn" | "hr" | "ht" | "hu" | "id" | "ie" | "il" | "im" | "in" | "iq" | "is" | "it" | "je" | "jm" | "jo" | "jp" | "ke" | "kg" | "kh" | "ki" | "kn" | "kr" | "kw" | "ky" | "kz" | "la" | "lb" | "lc" | "li" | "lk" | "ls" | "lt" | "lu" | "lv" | "ly" | "ma" | "mc" | "md" | "me" | "mg" | "mk" | "ml" | "mm" | "mn" | "mq" | "mr" | "ms" | "mt" | "mu" | "mv" | "mw" | "mx" | "my" | "mz" | "na" | "nc" | "ne" | "ng" | "ni" | "nl" | "no" | "np" | "nr" | "nu" | "nz" | "om" | "pa" | "pe" | "pf" | "pg" | "ph" | "pk" | "pl" | "pn" | "pr" | "ps" | "pt" | "py" | "qa" | "re" | "ro" | "rs" | "ru" | "rw" | "sa" | "sb" | "sc" | "se" | "sg" | "sh" | "si" | "sk" | "sl" | "sm" | "sn" | "so" | "sr" | "st" | "sv" | "td" | "tg" | "th" | "tj" | "tk" | "tl" | "tm" | "tn" | "to" | "tr" | "tt" | "tw" | "tz" | "ua" | "ug" | "us" | "uy" | "uz" | "vc" | "ve" | "vg" | "vi" | "vn" | "vu" | "ws" | "ye" | "yt" | "za" | "zm" | "zw")`
>
> A two-letter country code (ISO 3166-1 alpha-2).
>
> **date\_to** `string`
>
> The end date of the historical period in YYYY-MM-DD format.
>
> **protocol** `string ("both" | "http" | "https")`
>
> The protocol of your target.
>
> **date\_from** `string` *required*
>
> The start date of the historical period in YYYY-MM-DD format.
>
> **volume\_mode** `string ("monthly" | "average")`
>
> The search volume calculation mode: monthly or average. It affects volume, traffic, and traffic value.
>
> **top\_positions** `string ("top_10" | "top_100")`
>
> The number of top organic search positions to consider when calculating total search volume.
>
> **history\_grouping** `string ("daily" | "weekly" | "monthly")`
>
> The time interval used to group historical data.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Get content helper topics
>
> **Slug:** `AHREFS_GET_CONTENT_HELPER_TOPICS`
>
> Retrieve topics covered by top-ranking pages for a keyword. The analysis runs on demand from Ahrefs' collected SERP data and may take several seconds on the first request; repeated keyword and country requests can use cached results. When target\_url is provided, Ahrefs fetches that page live.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **output** `string ("json" | "php")`
>
> The output format.
>
> **country** `string ("ad" | "ae" | "af" | "ag" | "ai" | "al" | "am" | "ao" | "ar" | "as" | "at" | "au" | "aw" | "az" | "ba" | "bb" | "bd" | "be" | "bf" | "bg" | "bh" | "bi" | "bj" | "bn" | "bo" | "br" | "bs" | "bt" | "bw" | "by" | "bz" | "ca" | "cd" | "cf" | "cg" | "ch" | "ci" | "ck" | "cl" | "cm" | "cn" | "co" | "cr" | "cu" | "cv" | "cy" | "cz" | "de" | "dj" | "dk" | "dm" | "do" | "dz" | "ec" | "ee" | "eg" | "es" | "et" | "fi" | "fj" | "fm" | "fo" | "fr" | "ga" | "gb" | "gd" | "ge" | "gf" | "gg" | "gh" | "gi" | "gl" | "gm" | "gn" | "gp" | "gq" | "gr" | "gt" | "gu" | "gy" | "hk" | "hn" | "hr" | "ht" | "hu" | "id" | "ie" | "il" | "im" | "in" | "iq" | "is" | "it" | "je" | "jm" | "jo" | "jp" | "ke" | "kg" | "kh" | "ki" | "kn" | "kr" | "kw" | "ky" | "kz" | "la" | "lb" | "lc" | "li" | "lk" | "ls" | "lt" | "lu" | "lv" | "ly" | "ma" | "mc" | "md" | "me" | "mg" | "mk" | "ml" | "mm" | "mn" | "mq" | "mr" | "ms" | "mt" | "mu" | "mv" | "mw" | "mx" | "my" | "mz" | "na" | "nc" | "ne" | "ng" | "ni" | "nl" | "no" | "np" | "nr" | "nu" | "nz" | "om" | "pa" | "pe" | "pf" | "pg" | "ph" | "pk" | "pl" | "pn" | "pr" | "ps" | "pt" | "py" | "qa" | "re" | "ro" | "rs" | "ru" | "rw" | "sa" | "sb" | "sc" | "se" | "sg" | "sh" | "si" | "sk" | "sl" | "sm" | "sn" | "so" | "sr" | "st" | "sv" | "td" | "tg" | "th" | "tj" | "tk" | "tl" | "tm" | "tn" | "to" | "tr" | "tt" | "tw" | "tz" | "ua" | "ug" | "us" | "uy" | "uz" | "vc" | "ve" | "vg" | "vi" | "vn" | "vu" | "ws" | "ye" | "yt" | "za" | "zm" | "zw")` *required*
>
> A two-letter country code (ISO 3166-1 alpha-2).
>
> **keyword** `string` *required*
>
> The keyword to retrieve content helper topics for.
>
> **target\_url** `string`
>
> The target page URL to compare with competitor content.
>
> **top\_competitors** `integer`
>
> The number of top-ranking competitor pages to analyze.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Get domain rating free
>
> **Slug:** `AHREFS_GET_DOMAIN_RATING_FREE`
>
> Retrieve the free Ahrefs Domain Rating for a domain or URL. Use of the returned data is subject to the license URL in the response and requires attribution as "Domain Rating by Ahrefs" with a link to [https://ahrefs.com/](https://ahrefs.com/).
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0 per request
>
> #### Input Parameters
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **target** `string` *required*
>
> The target of the search: a domain or a URL.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Get domain rating top domains
>
> **Slug:** `AHREFS_GET_DOMAIN_RATING_TOP_DOMAINS`
>
> Retrieves domains ordered by Ahrefs Domain Rating. Use this action to inspect a ranked range of top domains. The endpoint can return up to 250,000 rows.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0 per request
>
> #### Input Parameters
>
> **to** `integer`
>
> The ending rank of the requested range. Up to 250,000 rows can be returned.
>
> **from** `integer`
>
> The starting rank of the requested range.
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Get serp overview
>
> **Slug:** `AHREFS_GET_SERP_OVERVIEW`
>
> Retrieves a SERP overview for one keyword in a specified country, optionally at a historical date. Results can include ranking positions, URLs and associated page metrics.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **date** `string`
>
> A timestamp on which the last available SERP Overview is returned in YYYY-MM-DDThh:mm:ss format. If it is not specified, the most recent SERP Overview is returned.
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **select** `string` *required*
>
> A comma-separated list of columns to return. See response schema for valid column identifiers.
>
> **country** `string ("ad" | "ae" | "af" | "ag" | "ai" | "al" | "am" | "ao" | "ar" | "as" | "at" | "au" | "aw" | "az" | "ba" | "bb" | "bd" | "be" | "bf" | "bg" | "bh" | "bi" | "bj" | "bn" | "bo" | "br" | "bs" | "bt" | "bw" | "by" | "bz" | "ca" | "cd" | "cf" | "cg" | "ch" | "ci" | "ck" | "cl" | "cm" | "cn" | "co" | "cr" | "cu" | "cv" | "cy" | "cz" | "de" | "dj" | "dk" | "dm" | "do" | "dz" | "ec" | "ee" | "eg" | "es" | "et" | "fi" | "fj" | "fm" | "fo" | "fr" | "ga" | "gb" | "gd" | "ge" | "gf" | "gg" | "gh" | "gi" | "gl" | "gm" | "gn" | "gp" | "gq" | "gr" | "gt" | "gu" | "gy" | "hk" | "hn" | "hr" | "ht" | "hu" | "id" | "ie" | "il" | "im" | "in" | "iq" | "is" | "it" | "je" | "jm" | "jo" | "jp" | "ke" | "kg" | "kh" | "ki" | "kn" | "kr" | "kw" | "ky" | "kz" | "la" | "lb" | "lc" | "li" | "lk" | "ls" | "lt" | "lu" | "lv" | "ly" | "ma" | "mc" | "md" | "me" | "mg" | "mk" | "ml" | "mm" | "mn" | "mq" | "mr" | "ms" | "mt" | "mu" | "mv" | "mw" | "mx" | "my" | "mz" | "na" | "nc" | "ne" | "ng" | "ni" | "nl" | "no" | "np" | "nr" | "nu" | "nz" | "om" | "pa" | "pe" | "pf" | "pg" | "ph" | "pk" | "pl" | "pn" | "pr" | "ps" | "pt" | "py" | "qa" | "re" | "ro" | "rs" | "ru" | "rw" | "sa" | "sb" | "sc" | "se" | "sg" | "sh" | "si" | "sk" | "sl" | "sm" | "sn" | "so" | "sr" | "st" | "sv" | "td" | "tg" | "th" | "tj" | "tk" | "tl" | "tm" | "tn" | "to" | "tr" | "tt" | "tw" | "tz" | "ua" | "ug" | "us" | "uy" | "uz" | "vc" | "ve" | "vg" | "vi" | "vn" | "vu" | "ws" | "ye" | "yt" | "za" | "zm" | "zw")` *required*
>
> A two-letter country code (ISO 3166-1 alpha-2).
>
> **keyword** `string` *required*
>
> The keyword to return SERP Overview for.
>
> **top\_positions** `integer`
>
> The number of top organic SERP positions to return. If not specified, all available positions will be returned.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Get site audit projects
>
> **Slug:** `AHREFS_GET_SITE_AUDIT_PROJECTS`
>
> Lists Site Audit projects associated with the authenticated Ahrefs account, with project and crawl status details. Requires a connected Ahrefs account.
>
> #### Input Parameters
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Get site explorer AI responses count
>
> **Slug:** `AHREFS_GET_SITE_EXPLORER_AI_RESPONSES_COUNT`
>
> Retrieve AI response citation and page counts for a site.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **date** `string`
>
> The date to report counts on in YYYY-MM-DD format.
>
> **mode** `string ("exact" | "prefix" | "domain" | "subdomains")`
>
> The scope of the search based on the target.
>
> **output** `string ("json" | "php")`
>
> The output format.
>
> **select** `string` *required*
>
> Comma-separated response fields to return. Valid fields are all\_platforms, chatgpt, copilot, gemini, google\_ai\_mode, google\_ai\_overviews, google\_ai\_overviews\_keywords, grok, and perplexity.
>
> **target** `string` *required*
>
> The target domain or URL.
>
> **country** `string ("ad" | "ae" | "af" | "ag" | "ai" | "al" | "am" | "ao" | "ar" | "as" | "at" | "au" | "aw" | "az" | "ba" | "bb" | "bd" | "be" | "bf" | "bg" | "bh" | "bi" | "bj" | "bn" | "bo" | "br" | "bs" | "bt" | "bw" | "by" | "bz" | "ca" | "cd" | "cf" | "cg" | "ch" | "ci" | "ck" | "cl" | "cm" | "cn" | "co" | "cr" | "cu" | "cv" | "cy" | "cz" | "de" | "dj" | "dk" | "dm" | "do" | "dz" | "ec" | "ee" | "eg" | "es" | "et" | "fi" | "fj" | "fm" | "fo" | "fr" | "ga" | "gb" | "gd" | "ge" | "gf" | "gg" | "gh" | "gi" | "gl" | "gm" | "gn" | "gp" | "gq" | "gr" | "gt" | "gu" | "gy" | "hk" | "hn" | "hr" | "ht" | "hu" | "id" | "ie" | "il" | "im" | "in" | "iq" | "is" | "it" | "je" | "jm" | "jo" | "jp" | "ke" | "kg" | "kh" | "ki" | "kn" | "kr" | "kw" | "ky" | "kz" | "la" | "lb" | "lc" | "li" | "lk" | "ls" | "lt" | "lu" | "lv" | "ly" | "ma" | "mc" | "md" | "me" | "mg" | "mk" | "ml" | "mm" | "mn" | "mq" | "mr" | "ms" | "mt" | "mu" | "mv" | "mw" | "mx" | "my" | "mz" | "na" | "nc" | "ne" | "ng" | "ni" | "nl" | "no" | "np" | "nr" | "nu" | "nz" | "om" | "pa" | "pe" | "pf" | "pg" | "ph" | "pk" | "pl" | "pn" | "pr" | "ps" | "pt" | "py" | "qa" | "re" | "ro" | "rs" | "ru" | "rw" | "sa" | "sb" | "sc" | "se" | "sg" | "sh" | "si" | "sk" | "sl" | "sm" | "sn" | "so" | "sr" | "st" | "sv" | "td" | "tg" | "th" | "tj" | "tk" | "tl" | "tm" | "tn" | "to" | "tr" | "tt" | "tw" | "tz" | "ua" | "ug" | "us" | "uy" | "uz" | "vc" | "ve" | "vg" | "vi" | "vn" | "vu" | "ws" | "ye" | "yt" | "za" | "zm" | "zw")`
>
> A two-letter country code (ISO 3166-1 alpha-2).
>
> **protocol** `string ("both" | "http" | "https")`
>
> The protocol of the target.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Get site explorer country metrics
>
> **Slug:** `AHREFS_GET_SITE_EXPLORER_COUNTRY_METRICS`
>
> Retrieves country-specific Site Explorer metrics for a target website or URL, including organic traffic and keyword metrics. The validated response contains a country and its metrics.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **date** `string` *required*
>
> A date to report metrics on in YYYY-MM-DD format.
>
> **mode** `string ("exact" | "prefix" | "domain" | "subdomains")`
>
> The scope of the search based on the target you entered.
>
> **limit** `integer`
>
> The number of results to return.
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **target** `string` *required*
>
> The target of the search: a domain or a URL.
>
> **protocol** `string ("both" | "http" | "https")`
>
> The protocol of your target.
>
> **volume\_mode** `string ("monthly" | "average")`
>
> The search volume calculation mode: monthly or average. It affects volume, traffic, and traffic value.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Get site explorer crawled pages
>
> **Slug:** `AHREFS_GET_SITE_EXPLORER_CRAWLED_PAGES`
>
> Retrieve crawled pages and crawl metadata for a target URL.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **mode** `string ("exact" | "prefix" | "domain" | "subdomains")`
>
> The scope of the search based on the target.
>
> **limit** `integer`
>
> The number of results to return.
>
> **where** `string`
>
> A JSON-encoded filter expression over url, http\_code, last\_crawled, first\_seen, last\_attempt, url\_rating, title, publish\_date, languages, page\_type, or page\_category. Combine clauses with and, or, or not; supported comparisons are eq, neq, gt, gte, lt, lte, substring, isubstring, phrase\_match, iphrase\_match, prefix, and suffix. Example: \{"field":"http\_code","is":\["eq",200]}.
>
> **output** `string ("json" | "php" | "xml")`
>
> The output format.
>
> **select** `string` *required*
>
> A comma-separated list of columns to return. Valid columns are first\_seen, http\_code, languages, last\_attempt, last\_crawled, page\_category, page\_type, publish\_date, title, url, and url\_rating. Each response row contains only the selected columns.
>
> **target** `string` *required*
>
> The target URL to inspect.
>
> **order\_by** `string`
>
> A column and direction to order results by.
>
> **protocol** `string ("both" | "http" | "https")`
>
> The protocol of the target.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Get site explorer linked anchors external
>
> **Slug:** `AHREFS_GET_SITE_EXPLORER_LINKED_ANCHORS_EXTERNAL`
>
> Retrieves anchor text data for external links going out from a target website using Ahrefs Site Explorer. Use it to analyze the anchors and external domains linked from the target.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **mode** `string ("exact" | "prefix" | "domain" | "subdomains")`
>
> The scope of the search based on the target you entered.
>
> **limit** `integer`
>
> The number of results to return.
>
> **where** `string`
>
> The filter expression. The following column identifiers are recognized (this differs from the identifiers recognized by the `select` parameter). **anchor**: The clickable words in a link that point to a URL.   type: string **dofollow\_links**: The number of outbound links with a given anchor from your target that don’t have the “nofollow” attribute.   type: integer **domain**: A linked domain that has at least one link from your target with a given anchor.   type: string **domain\_rating**: The strength of a domain"s backlink profile compared to the others in our database on a 100-point scale.   type: float **first\_seen**: The date we first found a link with a given anchor on your target.   type: datetime **is\_content**: The link was found in the biggest piece of content on the page.   type: boolean **is\_dofollow**: The link has no special nofollow attribute.   type: boolean **is\_nofollow**: The link or the referring page has the nofollow attribute set.   type: boolean **is\_non\_html**: The link points to a URL with non-HTML content.   type: boolean **is\_sponsored**: The link has the Sponsored attribute set in the referring page HTML.   type: boolean **is\_ugc**: The link has the User Generated Content attribute set in the referring page HTML.   type: boolean **languages**: The languages listed in the referring page metadata or detected by the crawler to appear in the HTML.   type: array(string) **len\_url\_redirect**: The number of redirect chain URLs.   type: integer **link\_type**: The kind of the backlink.   type: string   enum: `"redirect"` `"frame"` `"text"` `"form"` `"canonical"` `"alternate"` `"rss"` `"image"` **linked\_domains**: The number of unique domains linked from your target with a given anchor.   type: integer **linked\_domains\_source**: The number of unique root domains linked from the source page.   type: integer **linked\_pages**: The number of unique pages linked from your target with a given anchor.   type: integer **links\_external**: The number of external links from the referring page.   type: integer **links\_from\_target**: The number of outbound links your target has with a given anchor.   type: integer **port\_source**: The network port of the referring page URL.   type: integer **port\_target**: The network port of the target page URL.   type: integer **positions**: The number of keywords that the referring page ranks for in the top 100 positions.   type: integer **powered\_by**: Web technologies used to build and serve the referring page content.   type: array(string) **refdomains\_source** (5 units): The number of unique referring domains linking to the referring page.   type: integer **snippet\_left**: The snippet of text appearing just before the link.   type: string **snippet\_right**: The snippet of text appearing just after the link.   type: string **title**: The html title of the referring page.   type: string **traffic\_page** (10 units): The referring page"s estimated monthly organic traffic from search.   type: integer **url\_from**: The URL of the page containing a link to your target.   type: string **url\_redirect**: A redirect chain the target URL of the link points to.   type: array(url) **url\_redirect\_with\_target**: The target URL of the link with its redirect chain.   type: array(string) **url\_to**: The URL the backlink points to.   type: string
>
> **offset** `integer`
>
> \[Deprecated on 31 May 2024].
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **select** `string` *required*
>
> A comma-separated list of columns to return. See response schema for valid column identifiers.
>
> **target** `string` *required*
>
> The target of the search: a domain or a URL.
>
> **timeout** `integer`
>
> A manual timeout duration in seconds.
>
> **order\_by** `string`
>
> A column to order results by. See response schema for valid column identifiers.
>
> **protocol** `string ("both" | "http" | "https")`
>
> The protocol of your target.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Get url rating history
>
> **Slug:** `AHREFS_GET_URL_RATING_HISTORY`
>
> Retrieves the historical URL Rating data for a specified URL over time. This endpoint provides insights into how a URL's SEO strength has changed, allowing users to track the impact of their SEO efforts or analyze competitors' URL performance. The URL Rating is a key Ahrefs metric that reflects the strength of a URL based on its backlink profile and other SEO factors. Use this endpoint to visualize URL Rating trends, identify significant changes in a URL's SEO performance, and correlate these changes with specific events or strategies. The data returned is particularly useful for long-term SEO analysis and competitive research.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **target** `string` *required*
>
> The target of the search: a domain or a URL.
>
> **date\_to** `string`
>
> The end date of the historical period in YYYY-MM-DD format.
>
> **date\_from** `string` *required*
>
> The start date of the historical period in YYYY-MM-DD format.
>
> **history\_grouping** `string ("daily" | "weekly" | "monthly")`
>
> The time interval used to group historical data.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Linked anchors explorer
>
> **Slug:** `AHREFS_LINKED_ANCHORS_EXPLORER`
>
> Retrieves information about internal linked anchors for a specified website using the Ahrefs API. This endpoint provides data on anchor text used in internal links and the number of outgoing links associated with each anchor. It's particularly useful for analyzing a website's internal linking structure, identifying commonly used anchor texts, and optimizing internal link distribution. The endpoint is part of Ahrefs' Site Explorer tool and helps in understanding the website's hierarchy and content relationships. Each request and result incurs a cost of 1 row, which should be considered when making multiple or large-scale queries.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **mode** `string ("exact" | "prefix" | "domain" | "subdomains")`
>
> The scope of the search based on the target you entered.
>
> **limit** `integer`
>
> The number of results to return.
>
> **where** `string`
>
> The filter expression. The following column identifiers are recognized (this differs from the identifiers recognized by the `select` parameter). **anchor**: The clickable words in a link that point to a URL.   type: string **dofollow\_links**: The number of outbound links with a given anchor from your target that don’t have the “nofollow” attribute.   type: integer **domain**: A linked domain that has at least one link from your target with a given anchor.   type: string **domain\_rating**: The strength of a domain"s backlink profile compared to the others in our database on a 100-point scale.   type: float **first\_seen**: The date we first found a link with a given anchor on your target.   type: datetime **is\_content**: The link was found in the biggest piece of content on the page.   type: boolean **is\_dofollow**: The link has no special nofollow attribute.   type: boolean **is\_nofollow**: The link or the referring page has the nofollow attribute set.   type: boolean **is\_non\_html**: The link points to a URL with non-HTML content.   type: boolean **is\_sponsored**: The link has the Sponsored attribute set in the referring page HTML.   type: boolean **is\_ugc**: The link has the User Generated Content attribute set in the referring page HTML.   type: boolean **languages**: The languages listed in the referring page metadata or detected by the crawler to appear in the HTML.   type: array(string) **len\_url\_redirect**: The number of redirect chain URLs.   type: integer **link\_type**: The kind of the backlink.   type: string   enum: `"redirect"` `"frame"` `"text"` `"form"` `"canonical"` `"alternate"` `"rss"` `"image"` **linked\_domains\_source**: The number of unique root domains linked from the source page.   type: integer **linked\_pages**: The number of unique pages linked from your target with a given anchor.   type: integer **links\_external**: The number of external links from the referring page.   type: integer **links\_from\_target**: The number of outbound links your target has with a given anchor.   type: integer **port\_source**: The network port of the referring page URL.   type: integer **port\_target**: The network port of the target page URL.   type: integer **positions**: The number of keywords that the referring page ranks for in the top 100 positions.   type: integer **powered\_by**: Web technologies used to build and serve the referring page content.   type: array(string) **refdomains\_source** (5 units): The number of unique referring domains linking to the referring page.   type: integer **snippet\_left**: The snippet of text appearing just before the link.   type: string **snippet\_right**: The snippet of text appearing just after the link.   type: string **title**: The html title of the referring page.   type: string **traffic\_page** (10 units): The referring page"s estimated monthly organic traffic from search.   type: integer **url\_from**: The URL of the page containing a link to your target.   type: string **url\_redirect**: A redirect chain the target URL of the link points to.   type: array(url) **url\_redirect\_with\_target**: The target URL of the link with its redirect chain.   type: array(string) **url\_to**: The URL the backlink points to.   type: string
>
> **offset** `integer`
>
> \[Deprecated on 31 May 2024].
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **select** `string` *required*
>
> A comma-separated list of columns to return. See response schema for valid column identifiers.
>
> **target** `string` *required*
>
> The target of the search: a domain or a URL.
>
> **timeout** `integer`
>
> A manual timeout duration in seconds.
>
> **order\_by** `string`
>
> A column to order results by. See response schema for valid column identifiers.
>
> **protocol** `string ("both" | "http" | "https")`
>
> The protocol of your target.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] List best by external links
>
> **Slug:** `AHREFS_LIST_BEST_BY_EXTERNAL_LINKS`
>
> Retrieves pages from a specified website using Ahrefs' Site Explorer best-by-external-links report. The report includes external backlink metrics and can also include page information such as internal link counts.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **mode** `string ("exact" | "prefix" | "domain" | "subdomains")`
>
> The scope of the search based on the target you entered.
>
> **limit** `integer`
>
> The number of results to return.
>
> **where** `string`
>
> The filter expression. The following column identifiers are recognized (this differs from the identifiers recognized by the `select` parameter). **anchor**: The clickable words in a link that point to a URL.   type: string **dofollow\_to\_target**: The number of links to your target page that don’t have the “nofollow” attribute.   type: integer **domain\_rating\_source**: The strength of the referring domain"s backlink profile compared to the others in our database on a 100-point scale.   type: float **first\_seen\_link**: The date we first found a link to your target.   type: datetime **http\_code\_source**: The return code from HTTP protocol returned during the referring page crawl.   type: integer **http\_code\_target**: The return code from HTTP protocol returned during the target page crawl.   type: integer nullable **is\_content**: The link was found in the biggest piece of content on the page.   type: boolean **is\_dofollow**: The link has no special nofollow attribute.   type: boolean **is\_homepage\_link**: The link was found on the homepage of a referring website.   type: boolean **is\_lost**: The link currently does not exist anymore.   type: boolean **is\_new**: The link was discovered on the last crawl.   type: boolean **is\_nofollow**: The link or the referring page has the nofollow attribute set.   type: boolean **is\_non\_html**: The link points to a URL with non-HTML content.   type: boolean **is\_root\_source**: The referring domain name is a root domain name.   type: boolean **is\_sponsored**: The link has the Sponsored attribute set in the referring page HTML.   type: boolean **is\_ugc**: The link has the User Generated Content attribute set in the referring page HTML.   type: boolean **languages\_source**: The languages listed in the referring page metadata or detected by the crawler to appear in the HTML.   type: array(string) **languages\_target**: The languages listed in the target page metadata or detected by the crawler to appear in the HTML.   type: array(string) **last\_seen**: The date your target page lost its last live link.   type: datetime nullable **last\_visited\_source**: The date we last verified a live link to your target page.   type: datetime **last\_visited\_target**: The date we last crawled your target page.   type: datetime nullable **len\_url\_redirect**: The number of redirect chain URLs.   type: integer **link\_type**: The kind of the backlink.   type: string   enum: `"redirect"` `"frame"` `"text"` `"form"` `"canonical"` `"alternate"` `"rss"` `"image"` **linked\_domains\_source**: The number of unique root domains linked from the referring page.   type: integer **links\_external\_source**: The number of external links from the referring page.   type: integer **links\_to\_target**: The number of inbound backlinks the target page has.   type: integer **lost\_links\_to\_target**: The number of backlinks lost during the selected time period.   type: integer **new\_links\_to\_target**: The number of new backlinks found during the selected time period.   type: integer **nofollow\_to\_target**: The number of links to your target page that have the “nofollow” attribute.   type: integer **positions\_source**: The number of keywords that the referring page ranks for in the top 100 positions.   type: integer **positions\_source\_domain**: The number of keywords that the referring domain ranks for in the top 100 positions.   type: integer **powered\_by\_source**: Web technologies used to build and serve the referring page content.   type: array(string) **powered\_by\_target**: Web technologies used to build and serve the target page content.   type: array(string) **redirects\_to\_target**: The number of inbound redirects to your target page.   type: integer **refdomains\_source** (5 units): The number of unique referring domains linking to the referring page.   type: integer **refdomains\_target** (5 units): The number of unique referring domains linking to the target page.   type: integer **root\_name\_source**: The root domain name of the referring domain, not including subdomains.   type: string **snippet\_left**: The snippet of text appearing just before the link.   type: string **snippet\_right**: The snippet of text appearing just after the link.   type: string **source\_page\_author**: The author of the referring page.   type: string nullable **target\_redirect**: The target"s redirect if any.   type: string nullable **title\_source**: The html title of the referring page.   type: string **title\_target**: The html title of the target page.   type: string nullable **top\_domain\_rating\_source**: The highest Domain Rating (DR) counted out of all referring domains. DR shows the strength of a website’s backlink profile compared to the others in our database on a 100-point scale.   type: float **traffic\_domain\_source** (10 units): The referring domain"s estimated monthly organic traffic from search.   type: integer **traffic\_source** (10 units): The referring page"s estimated monthly organic traffic from search.   type: integer **url\_from\_plain**: The referring page URL optimized for use as a filter.   type: string **url\_rating\_source**: The strength of the referring page"s backlink profile compared to the others in our database on a 100-point scale.   type: float **url\_rating\_target**: The strength of the target page"s backlink profile compared to the others in our database on a 100-point scale.   type: float nullable **url\_redirect**: A redirect chain the target URL of the link points to.   type: array(url) **url\_redirect\_with\_target**: The target URL of the link with its redirect chain.   type: array(string) **url\_to**: The URL the backlink points to.   type: string **url\_to\_plain**: The target page URL optimized for use as a filter.   type: string
>
> **offset** `integer`
>
> \[Deprecated on 31 May 2024].
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **select** `string` *required*
>
> A comma-separated list of columns to return. See response schema for valid column identifiers.
>
> **target** `string` *required*
>
> The target of the search: a domain or a URL.
>
> **history** `string`
>
> A time frame to add lost backlinks to the report. Choose between `live` (no history), `since:<date>` (history since a specified date), and `all_time` (full history). The date should be in YYYY-MM-DD format.
>
> **timeout** `integer`
>
> A manual timeout duration in seconds.
>
> **order\_by** `string`
>
> A column to order results by. See response schema for valid column identifiers.
>
> **protocol** `string ("both" | "http" | "https")`
>
> The protocol of your target.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Pages by traffic overview
>
> **Slug:** `AHREFS_PAGES_BY_TRAFFIC_OVERVIEW`
>
> Retrieves a list of pages from a specified website, ordered by their estimated organic search traffic. This endpoint is part of the Ahrefs Site Explorer tool and provides valuable insights into which pages on a website are performing well in terms of attracting organic search visitors. It's useful for identifying top-performing content, understanding traffic distribution across a site, and prioritizing optimization efforts. The endpoint returns data such as page URLs, estimated traffic, and other relevant metrics. It's important to note that the traffic data is an estimation based on Ahrefs' algorithms and may not exactly match actual analytics data. This tool is particularly useful for SEO professionals, content strategists, and website owners looking to analyze and improve their site's organic search performance.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **mode** `string ("exact" | "prefix" | "domain" | "subdomains")`
>
> The scope of the search based on the target you entered.
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **target** `string` *required*
>
> The target of the search: a domain or a URL.
>
> **country** `string ("ad" | "ae" | "af" | "ag" | "ai" | "al" | "am" | "ao" | "ar" | "as" | "at" | "au" | "aw" | "az" | "ba" | "bb" | "bd" | "be" | "bf" | "bg" | "bh" | "bi" | "bj" | "bn" | "bo" | "br" | "bs" | "bt" | "bw" | "by" | "bz" | "ca" | "cd" | "cf" | "cg" | "ch" | "ci" | "ck" | "cl" | "cm" | "cn" | "co" | "cr" | "cu" | "cv" | "cy" | "cz" | "de" | "dj" | "dk" | "dm" | "do" | "dz" | "ec" | "ee" | "eg" | "es" | "et" | "fi" | "fj" | "fm" | "fo" | "fr" | "ga" | "gb" | "gd" | "ge" | "gf" | "gg" | "gh" | "gi" | "gl" | "gm" | "gn" | "gp" | "gq" | "gr" | "gt" | "gu" | "gy" | "hk" | "hn" | "hr" | "ht" | "hu" | "id" | "ie" | "il" | "im" | "in" | "iq" | "is" | "it" | "je" | "jm" | "jo" | "jp" | "ke" | "kg" | "kh" | "ki" | "kn" | "kr" | "kw" | "ky" | "kz" | "la" | "lb" | "lc" | "li" | "lk" | "ls" | "lt" | "lu" | "lv" | "ly" | "ma" | "mc" | "md" | "me" | "mg" | "mk" | "ml" | "mm" | "mn" | "mq" | "mr" | "ms" | "mt" | "mu" | "mv" | "mw" | "mx" | "my" | "mz" | "na" | "nc" | "ne" | "ng" | "ni" | "nl" | "no" | "np" | "nr" | "nu" | "nz" | "om" | "pa" | "pe" | "pf" | "pg" | "ph" | "pk" | "pl" | "pn" | "pr" | "ps" | "pt" | "py" | "qa" | "re" | "ro" | "rs" | "ru" | "rw" | "sa" | "sb" | "sc" | "se" | "sg" | "sh" | "si" | "sk" | "sl" | "sm" | "sn" | "so" | "sr" | "st" | "sv" | "td" | "tg" | "th" | "tj" | "tk" | "tl" | "tm" | "tn" | "to" | "tr" | "tt" | "tw" | "tz" | "ua" | "ug" | "us" | "uy" | "uz" | "vc" | "ve" | "vg" | "vi" | "vn" | "vu" | "ws" | "ye" | "yt" | "za" | "zm" | "zw")`
>
> A two-letter country code (ISO 3166-1 alpha-2).
>
> **protocol** `string ("both" | "http" | "https")`
>
> The protocol of your target.
>
> **volume\_mode** `string ("monthly" | "average")`
>
> The search volume calculation mode: monthly or average. It affects volume, traffic, and traffic value.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Post Domain Rating Free
>
> **Slug:** `AHREFS_POST_DOMAIN_RATING_FREE`
>
> Retrieve Domain Rating scores for up to 1,000 target URLs. Use of the returned data is subject to the license URL in the response and requires attribution as "Domain Rating by Ahrefs" with a link to [https://ahrefs.com/](https://ahrefs.com/).
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0 per request
>
> #### Input Parameters
>
> **output** `string ("json" | "php")`
>
> The output format.
>
> **targets** `array` *required*
>
> URLs for which to retrieve Domain Rating scores.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Retrieve anchor data
>
> **Slug:** `AHREFS_RETRIEVE_ANCHOR_DATA`
>
> Retrieves anchor text data for a specified website or URL using Ahrefs' Site Explorer tool. This endpoint provides valuable insights into the anchor text distribution of backlinks pointing to the target URL or domain. It helps SEO professionals analyze the quality and diversity of anchor texts, which can influence search engine rankings. Use this endpoint when you need to understand how other websites are linking to a specific page or domain, and to identify potential opportunities for link building or anchor text optimization. The tool does not provide information about the linking pages themselves, focusing solely on the anchor text data.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **mode** `string ("exact" | "prefix" | "domain" | "subdomains")`
>
> The scope of the search based on the target you entered.
>
> **limit** `integer`
>
> The number of results to return.
>
> **where** `string`
>
> The filter expression. The following column identifiers are recognized (this differs from the identifiers recognized by the `select` parameter). **anchor**: The clickable words in a link that point to a URL.   type: string **discovered\_status**: The reason the link was discovered during the last crawl: the page was crawled for the first time, the link was added to the page, or the link re-appeared after being removed.   type: string nullable   enum: `"pagefound"` `"linkfound"` `"linkrestored"` **dofollow\_links**: The number of links with a given anchor to your target that don"t have the "nofollow" attribute.   type: integer **domain\_rating**: The strength of a domain"s backlink profile compared to the others in our database on a 100-point scale.   type: float **drop\_reason**: The reason we removed the link from our index.   type: string nullable   enum: `"manual"` `"noratingunused"` `"notop"` `"tooold"` `"oldunavailable"` `"rescursive"` `"duplicate"` `"nxdomain"` `"malformed"` `"blockedport"` `"disallowed"` `"unlinked"` **first\_seen**: The date we first found a link with a given anchor to your target.   type: datetime **is\_content**: The link was found in the biggest piece of content on the page.   type: boolean **is\_dofollow**: The link has no special nofollow attribute.   type: boolean **is\_homepage\_link**: The link was found on the homepage of a referring website.   type: boolean **is\_nofollow**: The link or the referring page has the nofollow attribute set.   type: boolean **is\_non\_html**: The link points to a URL with non-HTML content.   type: boolean **is\_root\_domain**: The domain name is a root domain name.   type: boolean **is\_sponsored**: The link has the Sponsored attribute set in the referring page HTML.   type: boolean **is\_ugc**: The link has the User Generated Content attribute set in the referring page HTML.   type: boolean **languages**: The languages listed in the referring page metadata or detected by the crawler to appear in the HTML.   type: array(string) **last\_seen**: The date we discovered the last backlink with a given anchor was lost.   type: datetime nullable **len\_url\_redirect**: The number of redirect chain URLs.   type: integer **link\_type**: The kind of the backlink.   type: string   enum: `"redirect"` `"frame"` `"text"` `"form"` `"canonical"` `"alternate"` `"rss"` `"image"` **linked\_domains**: The number of unique root domains linked from the referring page.   type: integer **links\_external**: The number of external links from the referring page.   type: integer **links\_to\_target**: The number of inbound backlinks your target has with a given anchor.   type: integer **lost\_links**: The number of backlinks with a given anchor lost during the selected time period.   type: integer **lost\_reason**: The reason the link was lost during the last crawl.   type: string nullable   enum: `"removedfromhtml"` `"notcanonical"` `"noindex"` `"pageredirected"` `"pageerror"` `"lostredirect"` `"notfound"` **new\_links**: The number of new backlinks with a given anchor found during the selected time period.   type: integer **noindex**: The referring page has the noindex meta attribute.   type: boolean **positions**: The number of keywords that the referring page ranks for in the top 100 positions.   type: integer **positions\_source\_domain**: The number of keywords that the referring domain ranks for in the top 100 positions.   type: integer **powered\_by**: Web technologies used to build and serve the referring page content.   type: array(string) **refdomains** (5 units): The number of unique domains linking to your target with a given anchor.   type: integer **refdomains\_source** (5 units): The number of unique referring domains linking to the referring page.   type: integer **refpages**: The number of pages containing a link with a given anchor to your target.   type: integer **root\_domain\_name**: The root domain name of the referring domain, not including subdomains.   type: string **snippet\_left**: The snippet of text appearing just before the link.   type: string **snippet\_right**: The snippet of text appearing just after the link.   type: string **source\_page\_author**: The author of the referring page.   type: string nullable **title**: The html title of the referring page.   type: string **top\_domain\_rating**: The highest Domain Rating (DR) counted out of all referring domains. DR shows the strength of a website"s backlink profile compared to the others in our database on a 100-point scale.   type: float **traffic\_domain** (10 units): The referring domain"s estimated monthly organic traffic from search.   type: integer **traffic\_page** (10 units): The referring page"s estimated monthly organic traffic from search.   type: integer **url\_from**: The URL of the page containing a link to your target.   type: string **url\_redirect**: A redirect chain the target URL of the link points to.   type: array(url) **url\_redirect\_with\_target**: The target URL of the link with its redirect chain.   type: array(string) **url\_to**: The URL the backlink points to.   type: string
>
> **offset** `integer`
>
> \[Deprecated on 31 May 2024].
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **select** `string` *required*
>
> A comma-separated list of columns to return. See response schema for valid column identifiers.
>
> **target** `string` *required*
>
> The target of the search: a domain or a URL.
>
> **history** `string`
>
> A time frame to add lost backlinks to the report. Choose between `live` (no history), `since:<date>` (history since a specified date), and `all_time` (full history). The date should be in YYYY-MM-DD format.
>
> **timeout** `integer`
>
> A manual timeout duration in seconds.
>
> **order\_by** `string`
>
> A column to order results by. See response schema for valid column identifiers.
>
> **protocol** `string ("both" | "http" | "https")`
>
> The protocol of your target.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Retrieve best by internal links
>
> **Slug:** `AHREFS_RETRIEVE_BEST_BY_INTERNAL_LINKS`
>
> Retrieves pages ranked by internal links for a specified website using Ahrefs' Site Explorer. The report can include page details such as internal link counts, URL Rating and external link counts.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **mode** `string ("exact" | "prefix" | "domain" | "subdomains")`
>
> The scope of the search based on the target you entered.
>
> **limit** `integer`
>
> The number of results to return.
>
> **where** `string`
>
> The filter expression. The following column identifiers are recognized (this differs from the identifiers recognized by the `select` parameter). **anchor**: The clickable words in a link that point to a URL.   type: string **canonical\_to\_target**: The number of inbound canonical links to your target page.   type: integer **dofollow\_to\_target**: The number of links to your target page that don’t have the “nofollow” attribute.   type: integer **domain\_rating\_source**: The strength of the referring domain"s backlink profile compared to the others in our database on a 100-point scale.   type: float **first\_seen\_link**: The date we first found a link to your target.   type: datetime **http\_code\_source**: The return code from HTTP protocol returned during the referring page crawl.   type: integer **http\_code\_target**: The return code from HTTP protocol returned during the target page crawl.   type: integer nullable **is\_content**: The link was found in the biggest piece of content on the page.   type: boolean **is\_dofollow**: The link has no special nofollow attribute.   type: boolean **is\_homepage\_link**: The link was found on the homepage of a referring website.   type: boolean **is\_nofollow**: The link or the referring page has the nofollow attribute set.   type: boolean **is\_non\_html**: The link points to a URL with non-HTML content.   type: boolean **is\_root\_source**: The referring domain name is a root domain name.   type: boolean **is\_sponsored**: The link has the Sponsored attribute set in the referring page HTML.   type: boolean **is\_ugc**: The link has the User Generated Content attribute set in the referring page HTML.   type: boolean **languages\_source**: The languages listed in the referring page metadata or detected by the crawler to appear in the HTML.   type: array(string) **languages\_target**: The languages listed in the target page metadata or detected by the crawler to appear in the HTML.   type: array(string) **last\_seen**: The date your target page lost its last live link.   type: datetime nullable **last\_visited\_source**: The date we last verified a live link to your target page.   type: datetime **last\_visited\_target**: The date we last crawled your target page.   type: datetime nullable **len\_url\_redirect**: The number of redirect chain URLs.   type: integer **link\_type**: The kind of the backlink.   type: string   enum: `"redirect"` `"frame"` `"text"` `"form"` `"canonical"` `"alternate"` `"rss"` `"image"` **linked\_domains\_source**: The number of unique root domains linked from the referring page.   type: integer **links\_external\_source**: The number of external links from the referring page.   type: integer **links\_to\_target**: The number of inbound backlinks the target page has.   type: integer **nofollow\_to\_target**: The number of links to your target page that have the “nofollow” attribute.   type: integer **positions\_source**: The number of keywords that the referring page ranks for in the top 100 positions.   type: integer **positions\_source\_domain**: The number of keywords that the referring domain ranks for in the top 100 positions.   type: integer **powered\_by\_source**: Web technologies used to build and serve the referring page content.   type: array(string) **powered\_by\_target**: Web technologies used to build and serve the target page content.   type: array(string) **redirects\_to\_target**: The number of inbound redirects to your target page.   type: integer **refdomains\_source** (5 units): The number of unique referring domains linking to the referring page.   type: integer **root\_name\_source**: The root domain name of the referring domain, not including subdomains.   type: string **snippet\_left**: The snippet of text appearing just before the link.   type: string **snippet\_right**: The snippet of text appearing just after the link.   type: string **source\_page\_author**: The author of the referring page.   type: string nullable **target\_redirect**: The target"s redirect if any.   type: string nullable **title\_source**: The html title of the referring page.   type: string **title\_target**: The html title of the target page.   type: string nullable **traffic\_domain\_source** (10 units): The referring domain"s estimated monthly organic traffic from search.   type: integer **traffic\_source** (10 units): The referring page"s estimated monthly organic traffic from search.   type: integer **url\_from\_plain**: The referring page URL optimized for use as a filter.   type: string **url\_rating\_source**: The strength of the referring page"s backlink profile compared to the others in our database on a 100-point scale.   type: float **url\_rating\_target**: The strength of the target page"s backlink profile compared to the others in our database on a 100-point scale.   type: float nullable **url\_redirect**: A redirect chain the target URL of the link points to.   type: array(url) **url\_redirect\_with\_target**: The target URL of the link with its redirect chain.   type: array(string) **url\_to**: The URL the backlink points to.   type: string **url\_to\_plain**: The target page URL optimized for use as a filter.   type: string
>
> **offset** `integer`
>
> \[Deprecated on 31 May 2024].
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **select** `string` *required*
>
> A comma-separated list of columns to return. See response schema for valid column identifiers.
>
> **target** `string` *required*
>
> The target of the search: a domain or a URL.
>
> **timeout** `integer`
>
> A manual timeout duration in seconds.
>
> **order\_by** `string`
>
> A column to order results by. See response schema for valid column identifiers.
>
> **protocol** `string ("both" | "http" | "https")`
>
> The protocol of your target.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Retrieve crawler ip ranges
>
> **Slug:** `AHREFS_RETRIEVE_CRAWLER_IP_RANGES`
>
> Retrieves the list of IP address ranges used by Ahrefs' web crawler (AhrefsBot). This endpoint provides essential information for website administrators to identify and potentially whitelist Ahrefs' crawler traffic. Use this endpoint when you need to configure your server's firewall rules, analyze server logs, or verify the authenticity of crawler requests claiming to be from Ahrefs. The returned data includes the current set of IP ranges, which may change over time, so it's recommended to check this endpoint periodically for updates. Note that while this information helps in identifying Ahrefs' crawler, it should not be used as the sole method of authentication for the crawler.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0 per request
>
> #### Input Parameters
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Retrieve organic competitors
>
> **Slug:** `AHREFS_RETRIEVE_ORGANIC_COMPETITORS`
>
> Retrieves organic search competitors for a target domain or URL, with keyword overlap and performance metrics. Results may also include paid-search metrics.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **date** `string` *required*
>
> A date to report metrics on in YYYY-MM-DD format.
>
> **mode** `string ("exact" | "prefix" | "domain" | "subdomains")`
>
> The scope of the search based on the target you entered.
>
> **limit** `integer`
>
> The number of results to return.
>
> **where** `string`
>
> The filter expression. The following column identifiers are recognized (this differs from the identifiers recognized by the `select` parameter). **competitor\_domain**: A competitor"s domain of your target in “domains" group mode.   type: domain nullable **competitor\_url**: A competitor"s URL of your target in pages" group mode.   type: url nullable **cpc\_competitor**: Cost Per Click shows the average price that advertisers pay for each ad click in paid search results for a keyword, in USD cents for a competitor.   type: integer nullable **cpc\_target**: Cost Per Click shows the average price that advertisers pay for each ad click in paid search results for a keyword, in USD cents for a target.   type: integer nullable **domain\_rating**: The strength of a domain"s backlink profile compared to the others in our database on a 100-point scale.   type: float **group\_mode**: To see competing pages instead, use the “exact URL” target mode or “path” target mode if your target doesn"t have multiple pages.   type: string   enum: `"domains"` `"pages"` **keyword\_difficulty\_competitor** (10 units): An estimation of how hard it is to rank in the top 10 organic search results for a keyword on a 100-point scale for a competitor.   type: integer nullable **keyword\_difficulty\_target** (10 units): An estimation of how hard it is to rank in the top 10 organic search results for a keyword on a 100-point scale for a target.   type: integer nullable **keywords\_common**: Organic keywords that both your target and a competitor are ranking for.   type: integer **keywords\_competitor**: Organic keywords that a competitor is ranking for, but your target isn"t.   type: integer **keywords\_target**: Organic keywords that your target is ranking for, but a competitor isn"t.   type: integer **pages**: The total number of pages from a target ranking in search results.   type: integer nullable **pages\_diff**: The change in pages between your selected dates.   type: integer **pages\_merged**: The pages field optimized for sorting.   type: integer **pages\_prev**: The total number of pages from a target ranking in search results on the comparison date.   type: integer nullable **share**: The percentage of common keywords out of the total number of keywords that your target and a competitor both rank for.   type: float **traffic** (10 units): An estimation of the number of monthly visits that a page gets from organic search over the latest month or over the latest known 12 months of data depending on the "volume\_mode" parameter.   type: integer nullable **traffic\_diff**: The change in traffic between your selected dates.   type: integer **traffic\_merged** (10 units): The traffic field optimized for sorting.   type: integer **traffic\_prev** (10 units): An estimation of the number of monthly visits that a page gets from organic search over the latest month or over the latest known 12 months of data depending on the "volume\_mode" parameter on the comparison date.   type: integer nullable **value** (10 units): The estimated value of a page"s monthly organic search traffic, in USD cents.   type: integer nullable **value\_diff**: The change in value between your selected dates.   type: integer **value\_merged** (10 units): The value field optimized for sorting.   type: integer nullable **value\_prev** (10 units): The estimated value of a page"s monthly organic search traffic, in USD cents on the comparison date.   type: integer nullable **volume\_competitor** (10 units): An estimation of the average monthly number of searches for a keyword over the latest month or over the latest known 12 months of data depending on the "volume\_mode" parameter for a competitor.   type: integer nullable **volume\_target** (10 units): An estimation of the average monthly number of searches for a keyword over the latest month or over the latest known 12 months of data depending on the "volume\_mode" parameter for a target.   type: integer nullable **words\_competitor**: The number of words in a keyword for a competitor.   type: integer **words\_target**: The number of words in a keyword for a target.   type: integer
>
> **offset** `integer`
>
> \[Deprecated on 31 May 2024].
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **select** `string` *required*
>
> A comma-separated list of columns to return. See response schema for valid column identifiers.
>
> **target** `string` *required*
>
> The target of the search: a domain or a URL.
>
> **country** `string ("ad" | "ae" | "af" | "ag" | "ai" | "al" | "am" | "ao" | "ar" | "as" | "at" | "au" | "aw" | "az" | "ba" | "bb" | "bd" | "be" | "bf" | "bg" | "bh" | "bi" | "bj" | "bn" | "bo" | "br" | "bs" | "bt" | "bw" | "by" | "bz" | "ca" | "cd" | "cf" | "cg" | "ch" | "ci" | "ck" | "cl" | "cm" | "cn" | "co" | "cr" | "cu" | "cv" | "cy" | "cz" | "de" | "dj" | "dk" | "dm" | "do" | "dz" | "ec" | "ee" | "eg" | "es" | "et" | "fi" | "fj" | "fm" | "fo" | "fr" | "ga" | "gb" | "gd" | "ge" | "gf" | "gg" | "gh" | "gi" | "gl" | "gm" | "gn" | "gp" | "gq" | "gr" | "gt" | "gu" | "gy" | "hk" | "hn" | "hr" | "ht" | "hu" | "id" | "ie" | "il" | "im" | "in" | "iq" | "is" | "it" | "je" | "jm" | "jo" | "jp" | "ke" | "kg" | "kh" | "ki" | "kn" | "kr" | "kw" | "ky" | "kz" | "la" | "lb" | "lc" | "li" | "lk" | "ls" | "lt" | "lu" | "lv" | "ly" | "ma" | "mc" | "md" | "me" | "mg" | "mk" | "ml" | "mm" | "mn" | "mq" | "mr" | "ms" | "mt" | "mu" | "mv" | "mw" | "mx" | "my" | "mz" | "na" | "nc" | "ne" | "ng" | "ni" | "nl" | "no" | "np" | "nr" | "nu" | "nz" | "om" | "pa" | "pe" | "pf" | "pg" | "ph" | "pk" | "pl" | "pn" | "pr" | "ps" | "pt" | "py" | "qa" | "re" | "ro" | "rs" | "ru" | "rw" | "sa" | "sb" | "sc" | "se" | "sg" | "sh" | "si" | "sk" | "sl" | "sm" | "sn" | "so" | "sr" | "st" | "sv" | "td" | "tg" | "th" | "tj" | "tk" | "tl" | "tm" | "tn" | "to" | "tr" | "tt" | "tw" | "tz" | "ua" | "ug" | "us" | "uy" | "uz" | "vc" | "ve" | "vg" | "vi" | "vn" | "vu" | "ws" | "ye" | "yt" | "za" | "zm" | "zw")` *required*
>
> A two-letter country code (ISO 3166-1 alpha-2).
>
> **timeout** `integer`
>
> A manual timeout duration in seconds.
>
> **order\_by** `string`
>
> A column to order results by. See response schema for valid column identifiers.
>
> **protocol** `string ("both" | "http" | "https")`
>
> The protocol of your target.
>
> **volume\_mode** `string ("monthly" | "average")`
>
> The search volume calculation mode: monthly or average. It affects volume, traffic, and traffic value.
>
> **date\_compared** `string`
>
> A date to compare metrics with in YYYY-MM-DD format.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Retrieve organic keywords
>
> **Slug:** `AHREFS_RETRIEVE_ORGANIC_KEYWORDS`
>
> Retrieves organic keywords data for a specified website using Ahrefs' Site Explorer tool. This endpoint provides valuable insights into a website's SEO performance by returning a list of keywords for which the site ranks in organic search results. It's particularly useful for analyzing a website's organic search visibility, identifying ranking opportunities, and comparing keyword performance against competitors. The data returned includes key metrics such as keyword position, search volume, and estimated traffic, allowing users to make informed decisions about their SEO strategy. Note that the results are based on Ahrefs' database and may not reflect real-time search engine results.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **date** `string` *required*
>
> A date to report metrics on in YYYY-MM-DD format.
>
> **mode** `string ("exact" | "prefix" | "domain" | "subdomains")`
>
> The scope of the search based on the target you entered.
>
> **limit** `integer`
>
> The number of results to return.
>
> **where** `string`
>
> The filter expression. The following column identifiers are recognized (this differs from the identifiers recognized by the `select` parameter). **best\_position**: The top position your target ranks for in the organic search results for a keyword.   type: integer nullable **best\_position\_diff**: The change in position between your selected dates.   type: integer nullable **best\_position\_has\_thumbnail**: The top position has a thumbnail.   type: boolean nullable **best\_position\_has\_thumbnail\_prev**: The top position has a thumbnail on the comparison date.   type: boolean nullable **best\_position\_has\_video**: The top position has a video.   type: boolean nullable **best\_position\_has\_video\_prev**: The top position has a video on the comparison date.   type: boolean nullable **best\_position\_kind**: The kind of the top position: organic, paid, or a SERP feature.   type: string nullable   enum: `"paid_top"` `"paid_bottom"` `"paid_right"` `"paid_sitelink"` `"organic"` `"sitelink"` `"snippet"` `"image"` `"article"` `"knowledge_card"` `"knowledge_panel"` `"local_pack"` `"local_teaser"` `"news"` `"question"` `"review"` `"shopping"` `"tweet"` `"spelling"` `"video"` `"discussion"` `"ai_overview"` `"ai_overview_sitelink"` `"organic_shopping"` **best\_position\_kind\_merged**: The kind of the top position optimized for sorting.   type: string   enum: `"paid_top"` `"paid_bottom"` `"paid_right"` `"paid_sitelink"` `"organic"` `"sitelink"` `"snippet"` `"image"` `"article"` `"knowledge_card"` `"knowledge_panel"` `"local_pack"` `"local_teaser"` `"news"` `"question"` `"review"` `"shopping"` `"tweet"` `"spelling"` `"video"` `"discussion"` `"ai_overview"` `"ai_overview_sitelink"` `"organic_shopping"` **best\_position\_kind\_prev**: The kind of the top position on the comparison date.   type: string nullable   enum: `"paid_top"` `"paid_bottom"` `"paid_right"` `"paid_sitelink"` `"organic"` `"sitelink"` `"snippet"` `"image"` `"article"` `"knowledge_card"` `"knowledge_panel"` `"local_pack"` `"local_teaser"` `"news"` `"question"` `"review"` `"shopping"` `"tweet"` `"spelling"` `"video"` `"discussion"` `"ai_overview"` `"ai_overview_sitelink"` `"organic_shopping"` **best\_position\_prev**: The top position on the comparison date.   type: integer nullable **best\_position\_set**: The ranking group of the top position.   type: string   enum: `"top_3"` `"top_4_10"` `"top_11_50"` `"top_51_more"` **best\_position\_set\_prev**: The ranking group of the top position on the comparison date.   type: string nullable   enum: `"top_3"` `"top_4_10"` `"top_11_50"` `"top_51_more"` **best\_position\_url**: The ranking URL in organic search results.   type: string nullable **best\_position\_url\_prev**: The ranking URL on the comparison date.   type: string nullable **best\_position\_url\_raw**: The ranking page URL in encoded format.   type: string nullable **best\_position\_url\_raw\_prev**: The ranking page URL on the comparison date in encoded format.   type: string nullable **cpc**: Cost Per Click shows the average price that advertisers pay for each ad click in paid search results for a keyword, in USD cents.   type: integer nullable **cpc\_merged**: The CPC field optimized for sorting.   type: integer nullable **cpc\_prev**: The CPC metric on the comparison date.   type: integer nullable **is\_best\_position\_set\_top\_11\_50**: The ranking group of the top position is 11-50.   type: boolean **is\_best\_position\_set\_top\_11\_50\_prev**: The ranking group of the top position was 11-50 on the comparison date.   type: boolean nullable **is\_best\_position\_set\_top\_3**: The ranking group of the top position is Top 3.   type: boolean **is\_best\_position\_set\_top\_3\_prev**: The ranking group of the top position was Top 3 on the comparison date.   type: boolean nullable **is\_best\_position\_set\_top\_4\_10**: The ranking group of the top position is 4-10.   type: boolean **is\_best\_position\_set\_top\_4\_10\_prev**: The ranking group of the top position was 4-10 on the comparison date.   type: boolean nullable **is\_branded**: User intent: branded. The user is searching for a specific brand or company name.   type: boolean **is\_commercial**: User intent: commercial. The user is comparing products or services before making a purchase decision.   type: boolean **is\_informational**: User intent: informational. The user is looking for information or an answer to a specific question.   type: boolean **is\_local**: User intent: local. The user is looking for information relevant to a specific location or nearby services.   type: boolean **is\_main\_position**: Excludes positions in Sitelinks, Top stories, Image packs, and posts on X (Twitter).   type: boolean **is\_main\_position\_prev**: Excludes positions in Sitelinks, Top stories, Image packs, and posts on X (Twitter) on the comparison date.   type: boolean **is\_navigational**: User intent: navigational. The user is searching for a specific website or web page.   type: boolean **is\_transactional**: User intent: transactional. The user is ready to complete an action, often a purchase.   type: boolean **keyword**: The keyword your target ranks for.   type: string **keyword\_difficulty** (10 units): An estimation of how hard it is to rank in the top 10 organic search results for a keyword on a 100-point scale.   type: integer nullable **keyword\_difficulty\_merged** (10 units): The keyword difficulty field optimized for sorting.   type: integer nullable **keyword\_difficulty\_prev** (10 units): The keyword difficulty on the comparison date.   type: integer nullable **keyword\_merged**: The keyword field optimized for sorting.   type: string **keyword\_prev**: The keyword your target ranks for on the comparison date.   type: string **language**: The SERP language.   type: string **language\_prev**: The SERP language on the comparison date.   type: string nullable **last\_update**: The date when we last checked search engine results for a keyword.   type: datetime **last\_update\_prev**: The date when we checked search engine results up to the comparison date.   type: datetime nullable **position\_kind**: The kind of a position: organic, paid or a SERP feature. This applies to all positions for a given keyword and URL before picking the top position.   type: string   enum: `"paid_top"` `"paid_bottom"` `"paid_right"` `"paid_sitelink"` `"organic"` `"sitelink"` `"snippet"` `"image"` `"article"` `"knowledge_card"` `"knowledge_panel"` `"local_pack"` `"local_teaser"` `"news"` `"question"` `"review"` `"shopping"` `"tweet"` `"spelling"` `"video"` `"discussion"` `"ai_overview"` `"ai_overview_sitelink"` `"organic_shopping"` **position\_kind\_prev**: The kind of a position on the comparison date.   type: string   enum: `"paid_top"` `"paid_bottom"` `"paid_right"` `"paid_sitelink"` `"organic"` `"sitelink"` `"snippet"` `"image"` `"article"` `"knowledge_card"` `"knowledge_panel"` `"local_pack"` `"local_teaser"` `"news"` `"question"` `"review"` `"shopping"` `"tweet"` `"spelling"` `"video"` `"discussion"` `"ai_overview"` `"ai_overview_sitelink"` `"organic_shopping"` **positions\_kinds**: The kinds of the top positions.   type: array(string)   enum: `"paid_top"` `"paid_bottom"` `"paid_right"` `"paid_sitelink"` `"organic"` `"sitelink"` `"snippet"` `"image"` `"article"` `"knowledge_card"` `"knowledge_panel"` `"local_pack"` `"local_teaser"` `"news"` `"question"` `"review"` `"shopping"` `"tweet"` `"spelling"` `"video"` `"discussion"` `"ai_overview"` `"ai_overview_sitelink"` `"organic_shopping"` `"image_th"` `"video_th"` `"ai_overview_found"` **positions\_kinds\_prev**: The kinds of the top positions on the comparison date.   type: array(string)   enum: `"paid_top"` `"paid_bottom"` `"paid_right"` `"paid_sitelink"` `"organic"` `"sitelink"` `"snippet"` `"image"` `"article"` `"knowledge_card"` `"knowledge_panel"` `"local_pack"` `"local_teaser"` `"news"` `"question"` `"review"` `"shopping"` `"tweet"` `"spelling"` `"video"` `"discussion"` `"ai_overview"` `"ai_overview_sitelink"` `"organic_shopping"` `"image_th"` `"video_th"` `"ai_overview_found"` **serp\_features**: The SERP features that appear in search results for a keyword.   type: array(string)   enum: `"paid_top"` `"paid_bottom"` `"paid_right"` `"paid_sitelink"` `"organic"` `"sitelink"` `"snippet"` `"image"` `"article"` `"knowledge_card"` `"knowledge_panel"` `"local_pack"` `"local_teaser"` `"news"` `"question"` `"review"` `"shopping"` `"tweet"` `"spelling"` `"video"` `"discussion"` `"ai_overview"` `"ai_overview_sitelink"` `"organic_shopping"` `"image_th"` `"video_th"` `"ai_overview_found"` **serp\_features\_count**: The number of SERP features that appear in search results for a keyword.   type: integer **serp\_features\_count\_prev**: The number of SERP features on the comparison date.   type: integer nullable **serp\_features\_merged**: The SERP features field optimized for sorting.   type: array(string)   enum: `"paid_top"` `"paid_bottom"` `"paid_right"` `"paid_sitelink"` `"organic"` `"sitelink"` `"snippet"` `"image"` `"article"` `"knowledge_card"` `"knowledge_panel"` `"local_pack"` `"local_teaser"` `"news"` `"question"` `"review"` `"shopping"` `"tweet"` `"spelling"` `"video"` `"discussion"` `"ai_overview"` `"ai_overview_sitelink"` `"organic_shopping"` `"image_th"` `"video_th"` `"ai_overview_found"` **serp\_features\_prev**: The SERP features on the comparison date.   type: array(string)   enum: `"paid_top"` `"paid_bottom"` `"paid_right"` `"paid_sitelink"` `"organic"` `"sitelink"` `"snippet"` `"image"` `"article"` `"knowledge_card"` `"knowledge_panel"` `"local_pack"` `"local_teaser"` `"news"` `"question"` `"review"` `"shopping"` `"tweet"` `"spelling"` `"video"` `"discussion"` `"ai_overview"` `"ai_overview_sitelink"` `"organic_shopping"` `"image_th"` `"video_th"` `"ai_overview_found"` **serp\_target\_main\_positions\_count**: The number of target URLs ranking for a keyword excluding positions in Sitelinks, Top stories, Image packs, and posts on X (Twitter).   type: integer **serp\_target\_main\_positions\_count\_prev**: The number of target URLs ranking for a keyword excluding positions in Sitelinks, Top stories, Image packs, and posts on X (Twitter) on the comparison date.   type: integer nullable **serp\_target\_positions\_count**: The number of target URLs ranking for a keyword.   type: integer **serp\_target\_positions\_count\_prev**: The number of target URLs ranking for a keyword on the comparison date.   type: integer nullable **status**: The status of a page: the new page that just started to rank ("left"), the lost page that disappeared from search results ("right"), or no change ("both").   type: string   enum: `"left"` `"right"` `"both"` **sum\_paid\_traffic** (10 units): An estimation of the number of monthly visits that your target gets from paid search for a keyword.   type: integer nullable **sum\_traffic** (10 units): An estimation of the number of monthly visitors that your target gets from organic search for a keyword.   type: integer nullable **sum\_traffic\_merged** (10 units): The traffic field optimized for sorting.   type: integer **sum\_traffic\_prev** (10 units): The traffic on the comparison date.   type: integer nullable **title**: The title displayed for the page in a keyword"s SERP.   type: string **title\_prev**: The title displayed for the page in a keyword"s SERP on the comparison date.   type: string **volume** (10 units): An estimation of the number of searches for a keyword over the latest month.   type: integer nullable **volume\_desktop\_pct**: The percentage of the total search volume that comes from desktop devices.   type: float nullable **volume\_merged** (10 units): The search volume field optimized for sorting.   type: integer nullable **volume\_mobile\_pct**: The percentage of the total search volume that comes from mobile devices.   type: float nullable **volume\_prev** (10 units): The search volume on the comparison date.   type: integer nullable **words**: The number of words in a keyword.   type: integer **words\_merged**: The number of words in a keyword optimized for sorting.   type: integer **words\_prev**: The number of words in a keyword on the comparison date.   type: integer
>
> **offset** `integer`
>
> \[Deprecated on 31 May 2024].
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **select** `string` *required*
>
> A comma-separated list of columns to return. See response schema for valid column identifiers.
>
> **target** `string` *required*
>
> The target of the search: a domain or a URL.
>
> **country** `string ("ad" | "ae" | "af" | "ag" | "ai" | "al" | "am" | "ao" | "ar" | "as" | "at" | "au" | "aw" | "az" | "ba" | "bb" | "bd" | "be" | "bf" | "bg" | "bh" | "bi" | "bj" | "bn" | "bo" | "br" | "bs" | "bt" | "bw" | "by" | "bz" | "ca" | "cd" | "cf" | "cg" | "ch" | "ci" | "ck" | "cl" | "cm" | "cn" | "co" | "cr" | "cu" | "cv" | "cy" | "cz" | "de" | "dj" | "dk" | "dm" | "do" | "dz" | "ec" | "ee" | "eg" | "es" | "et" | "fi" | "fj" | "fm" | "fo" | "fr" | "ga" | "gb" | "gd" | "ge" | "gf" | "gg" | "gh" | "gi" | "gl" | "gm" | "gn" | "gp" | "gq" | "gr" | "gt" | "gu" | "gy" | "hk" | "hn" | "hr" | "ht" | "hu" | "id" | "ie" | "il" | "im" | "in" | "iq" | "is" | "it" | "je" | "jm" | "jo" | "jp" | "ke" | "kg" | "kh" | "ki" | "kn" | "kr" | "kw" | "ky" | "kz" | "la" | "lb" | "lc" | "li" | "lk" | "ls" | "lt" | "lu" | "lv" | "ly" | "ma" | "mc" | "md" | "me" | "mg" | "mk" | "ml" | "mm" | "mn" | "mq" | "mr" | "ms" | "mt" | "mu" | "mv" | "mw" | "mx" | "my" | "mz" | "na" | "nc" | "ne" | "ng" | "ni" | "nl" | "no" | "np" | "nr" | "nu" | "nz" | "om" | "pa" | "pe" | "pf" | "pg" | "ph" | "pk" | "pl" | "pn" | "pr" | "ps" | "pt" | "py" | "qa" | "re" | "ro" | "rs" | "ru" | "rw" | "sa" | "sb" | "sc" | "se" | "sg" | "sh" | "si" | "sk" | "sl" | "sm" | "sn" | "so" | "sr" | "st" | "sv" | "td" | "tg" | "th" | "tj" | "tk" | "tl" | "tm" | "tn" | "to" | "tr" | "tt" | "tw" | "tz" | "ua" | "ug" | "us" | "uy" | "uz" | "vc" | "ve" | "vg" | "vi" | "vn" | "vu" | "ws" | "ye" | "yt" | "za" | "zm" | "zw")` *required*
>
> A two-letter country code (ISO 3166-1 alpha-2).
>
> **timeout** `integer`
>
> A manual timeout duration in seconds.
>
> **order\_by** `string`
>
> A column to order results by. See response schema for valid column identifiers.
>
> **protocol** `string ("both" | "http" | "https")`
>
> The protocol of your target.
>
> **volume\_mode** `string ("monthly" | "average")`
>
> The search volume calculation mode: monthly or average. It affects volume, traffic, and traffic value.
>
> **date\_compared** `string`
>
> A date to compare metrics with in YYYY-MM-DD format.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Retrieve outlinks stats
>
> **Slug:** `AHREFS_RETRIEVE_OUTLINKS_STATS`
>
> Retrieves outgoing-link statistics for a specified website or URL using Ahrefs Site Explorer. The response schema includes internal and external link counts for crawled pages.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **mode** `string ("exact" | "prefix" | "domain" | "subdomains")`
>
> The scope of the search based on the target you entered.
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **target** `string` *required*
>
> The target of the search: a domain or a URL.
>
> **protocol** `string ("both" | "http" | "https")`
>
> The protocol of your target.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Retrieve paid pages data
>
> **Slug:** `AHREFS_RETRIEVE_PAID_PAGES_DATA`
>
> Retrieves information about paid pages (PPC advertising) for a specified website using Ahrefs' Site Explorer tool. This endpoint provides valuable insights into a website's paid search strategy, including the keywords they're targeting, ad copies, and potentially performance metrics. It's particularly useful for competitive analysis in digital marketing, allowing users to understand their competitors' paid search efforts. The tool should be used when analyzing a website's PPC strategy or researching potential keywords for paid campaigns. It does not provide information about organic search performance or other SEO metrics.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **date** `string` *required*
>
> A date to report metrics on in YYYY-MM-DD format.
>
> **mode** `string ("exact" | "prefix" | "domain" | "subdomains")`
>
> The scope of the search based on the target you entered.
>
> **limit** `integer`
>
> The number of results to return.
>
> **where** `string`
>
> The filter expression. The following column identifiers are recognized (this differs from the identifiers recognized by the `select` parameter). **ads\_count**: The number of unique ads with a page.   type: integer **ads\_count\_diff**: The change in ads between your selected dates.   type: integer **ads\_count\_prev**: The number of ads on the comparison date.   type: integer **cpc**   type: integer nullable **cpc\_prev**: The CPC metric on the comparison date.   type: integer nullable **description**: The description of an ad as seen in search results.   type: string **description\_prev**: The description of an ad on the comparison date.   type: string **has\_thumbnail**: The position has a thumbnail.   type: boolean **has\_thumbnail\_prev**: The position has a thumbnail on the comparison date.   type: boolean **has\_video**: The position has a video.   type: boolean **has\_video\_prev**: The position has a video on the comparison date.   type: boolean **keyword**: The keyword your target ranks for.   type: string **keyword\_difficulty** (10 units): An estimation of how hard it is to rank in the top 10 organic search results for a keyword on a 100-point scale.   type: integer nullable **keyword\_difficulty\_prev** (10 units): The keyword difficulty on the comparison date.   type: integer nullable **keyword\_prev**: The keyword your target ranks for on the comparison date.   type: string **keywords**: The total number of keywords that your target ranks for in paid search results.   type: integer **keywords\_diff**: The change in keywords between your selected dates.   type: integer **keywords\_diff\_percent**: The change in keywords between your selected dates, in percents.   type: integer **keywords\_merged**: The total number of keywords optimized for sorting.   type: integer **keywords\_prev**: The keyword your target ranks for on the comparison date.   type: integer **position**: The position your target ranks for in the paid search results for a keyword.   type: integer **position\_kind**: The kind of a position: organic, paid or a SERP feature. This applies to all positions for a given keyword and URL before picking the top position.   type: string   enum: `"paid_top"` `"paid_bottom"` `"paid_right"` `"paid_sitelink"` `"organic"` `"sitelink"` `"snippet"` `"image"` `"article"` `"knowledge_card"` `"knowledge_panel"` `"local_pack"` `"local_teaser"` `"news"` `"question"` `"review"` `"shopping"` `"tweet"` `"spelling"` `"video"` `"discussion"` `"ai_overview"` `"ai_overview_sitelink"` `"organic_shopping"` **position\_kind\_prev**: The kind of a position on the comparison date.   type: string   enum: `"paid_top"` `"paid_bottom"` `"paid_right"` `"paid_sitelink"` `"organic"` `"sitelink"` `"snippet"` `"image"` `"article"` `"knowledge_card"` `"knowledge_panel"` `"local_pack"` `"local_teaser"` `"news"` `"question"` `"review"` `"shopping"` `"tweet"` `"spelling"` `"video"` `"discussion"` `"ai_overview"` `"ai_overview_sitelink"` `"organic_shopping"` **position\_prev**: The position of your target for a given keyword on the comparison date.   type: integer **raw\_url**: The ranking page URL in encoded format.   type: string **raw\_url\_prev**: The ranking page URL on the comparison date in encoded format.   type: string **serp\_features**   type: array(string)   enum: `"paid_top"` `"paid_bottom"` `"paid_right"` `"paid_sitelink"` `"organic"` `"sitelink"` `"snippet"` `"image"` `"article"` `"knowledge_card"` `"knowledge_panel"` `"local_pack"` `"local_teaser"` `"news"` `"question"` `"review"` `"shopping"` `"tweet"` `"spelling"` `"video"` `"discussion"` `"ai_overview"` `"ai_overview_sitelink"` `"organic_shopping"` `"image_th"` `"video_th"` `"ai_overview_found"` **serp\_features\_prev**: The SERP features on the comparison date.   type: array(string)   enum: `"paid_top"` `"paid_bottom"` `"paid_right"` `"paid_sitelink"` `"organic"` `"sitelink"` `"snippet"` `"image"` `"article"` `"knowledge_card"` `"knowledge_panel"` `"local_pack"` `"local_teaser"` `"news"` `"question"` `"review"` `"shopping"` `"tweet"` `"spelling"` `"video"` `"discussion"` `"ai_overview"` `"ai_overview_sitelink"` `"organic_shopping"` `"image_th"` `"video_th"` `"ai_overview_found"` **status**: The status of a page: the new page that just started to rank in paid results ("left"), the lost page that disappeared from paid results ("right"), or no change ("both").   type: string   enum: `"left"` `"right"` `"both"` **sum\_traffic** (10 units): An estimation of the monthly paid search traffic that a page gets from all the keywords that it ranks for.   type: integer nullable **sum\_traffic\_merged** (10 units): The paid traffic field optimized for sorting.   type: integer **sum\_traffic\_prev** (10 units): The paid traffic on the comparison date.   type: integer nullable **title**: The title of an ad as seen in search results.   type: string **title\_prev**: The title of an ad on the comparison date.   type: string **top\_keyword**: The keyword that brings the most paid traffic to a page.   type: string nullable **top\_keyword\_best\_position**: The ranking position that a page holds for its top keyword.   type: integer nullable **top\_keyword\_best\_position\_diff**: The change in the top position between your selected dates.   type: integer nullable **top\_keyword\_best\_position\_kind**: The kind of the top position: organic, paid or a SERP feature.   type: string nullable   enum: `"paid_top"` `"paid_bottom"` `"paid_right"` `"paid_sitelink"` `"organic"` `"sitelink"` `"snippet"` `"image"` `"article"` `"knowledge_card"` `"knowledge_panel"` `"local_pack"` `"local_teaser"` `"news"` `"question"` `"review"` `"shopping"` `"tweet"` `"spelling"` `"video"` `"discussion"` `"ai_overview"` `"ai_overview_sitelink"` `"organic_shopping"` **top\_keyword\_best\_position\_kind\_prev**: The kind of the top position on the comparison date.   type: string nullable   enum: `"paid_top"` `"paid_bottom"` `"paid_right"` `"paid_sitelink"` `"organic"` `"sitelink"` `"snippet"` `"image"` `"article"` `"knowledge_card"` `"knowledge_panel"` `"local_pack"` `"local_teaser"` `"news"` `"question"` `"review"` `"shopping"` `"tweet"` `"spelling"` `"video"` `"discussion"` `"ai_overview"` `"ai_overview_sitelink"` `"organic_shopping"` **top\_keyword\_best\_position\_prev**: The top position on the comparison date.   type: integer nullable **top\_keyword\_best\_position\_title**: The title displayed for the page in its top keyword"s SERP.   type: string nullable **top\_keyword\_best\_position\_title\_prev**: The title displayed for the page in its top keyword"s SERP on the comparison date.   type: string nullable **top\_keyword\_country**: The country in which a page ranks for its top keyword.   type: string nullable   enum: `"AD"` `"AE"` `"AF"` `"AG"` `"AI"` `"AL"` `"AM"` `"AO"` `"AQ"` `"AR"` `"AS"` `"AT"` `"AU"` `"AW"` `"AX"` `"AZ"` `"BA"` `"BB"` `"BD"` `"BE"` `"BF"` `"BG"` `"BH"` `"BI"` `"BJ"` `"BL"` `"BM"` `"BN"` `"BO"` `"BQ"` `"BR"` `"BS"` `"BT"` `"BV"` `"BW"` `"BY"` `"BZ"` `"CA"` `"CC"` `"CD"` `"CF"` `"CG"` `"CH"` `"CI"` `"CK"` `"CL"` `"CM"` `"CN"` `"CO"` `"CR"` `"CU"` `"CV"` `"CW"` `"CX"` `"CY"` `"CZ"` `"DE"` `"DJ"` `"DK"` `"DM"` `"DO"` `"DZ"` `"EC"` `"EE"` `"EG"` `"EH"` `"ER"` `"ES"` `"ET"` `"FI"` `"FJ"` `"FK"` `"FM"` `"FO"` `"FR"` `"GA"` `"GB"` `"GD"` `"GE"` `"GF"` `"GG"` `"GH"` `"GI"` `"GL"` `"GM"` `"GN"` `"GP"` `"GQ"` `"GR"` `"GS"` `"GT"` `"GU"` `"GW"` `"GY"` `"HK"` `"HM"` `"HN"` `"HR"` `"HT"` `"HU"` `"ID"` `"IE"` `"IL"` `"IM"` `"IN"` `"IO"` `"IQ"` `"IR"` `"IS"` `"IT"` `"JE"` `"JM"` `"JO"` `"JP"` `"KE"` `"KG"` `"KH"` `"KI"` `"KM"` `"KN"` `"KP"` `"KR"` `"KW"` `"KY"` `"KZ"` `"LA"` `"LB"` `"LC"` `"LI"` `"LK"` `"LR"` `"LS"` `"LT"` `"LU"` `"LV"` `"LY"` `"MA"` `"MC"` `"MD"` `"ME"` `"MF"` `"MG"` `"MH"` `"MK"` `"ML"` `"MM"` `"MN"` `"MO"` `"MP"` `"MQ"` `"MR"` `"MS"` `"MT"` `"MU"` `"MV"` `"MW"` `"MX"` `"MY"` `"MZ"` `"NA"` `"NC"` `"NE"` `"NF"` `"NG"` `"NI"` `"NL"` `"NO"` `"NP"` `"NR"` `"NU"` `"NZ"` `"OM"` `"OTHER"` `"PA"` `"PE"` `"PF"` `"PG"` `"PH"` `"PK"` `"PL"` `"PM"` `"PN"` `"PR"` `"PS"` `"PT"` `"PW"` `"PY"` `"QA"` `"RE"` `"RO"` `"RS"` `"RU"` `"RW"` `"SA"` `"SB"` `"SC"` `"SD"` `"SE"` `"SG"` `"SH"` `"SI"` `"SJ"` `"SK"` `"SL"` `"SM"` `"SN"` `"SO"` `"SR"` `"SS"` `"ST"` `"SV"` `"SX"` `"SY"` `"SZ"` `"TC"` `"TD"` `"TF"` `"TG"` `"TH"` `"TJ"` `"TK"` `"TL"` `"TM"` `"TN"` `"TO"` `"TR"` `"TT"` `"TV"` `"TW"` `"TZ"` `"UA"` `"UG"` `"UM"` `"US"` `"UY"` `"UZ"` `"VA"` `"VC"` `"VE"` `"VG"` `"VI"` `"VN"` `"VU"` `"WF"` `"WS"` `"YE"` `"YT"` `"ZA"` `"ZM"` `"ZW"` **top\_keyword\_country\_prev**: The country in which a page ranks for its top keyword on the comparison date.   type: string nullable   enum: `"AD"` `"AE"` `"AF"` `"AG"` `"AI"` `"AL"` `"AM"` `"AO"` `"AQ"` `"AR"` `"AS"` `"AT"` `"AU"` `"AW"` `"AX"` `"AZ"` `"BA"` `"BB"` `"BD"` `"BE"` `"BF"` `"BG"` `"BH"` `"BI"` `"BJ"` `"BL"` `"BM"` `"BN"` `"BO"` `"BQ"` `"BR"` `"BS"` `"BT"` `"BV"` `"BW"` `"BY"` `"BZ"` `"CA"` `"CC"` `"CD"` `"CF"` `"CG"` `"CH"` `"CI"` `"CK"` `"CL"` `"CM"` `"CN"` `"CO"` `"CR"` `"CU"` `"CV"` `"CW"` `"CX"` `"CY"` `"CZ"` `"DE"` `"DJ"` `"DK"` `"DM"` `"DO"` `"DZ"` `"EC"` `"EE"` `"EG"` `"EH"` `"ER"` `"ES"` `"ET"` `"FI"` `"FJ"` `"FK"` `"FM"` `"FO"` `"FR"` `"GA"` `"GB"` `"GD"` `"GE"` `"GF"` `"GG"` `"GH"` `"GI"` `"GL"` `"GM"` `"GN"` `"GP"` `"GQ"` `"GR"` `"GS"` `"GT"` `"GU"` `"GW"` `"GY"` `"HK"` `"HM"` `"HN"` `"HR"` `"HT"` `"HU"` `"ID"` `"IE"` `"IL"` `"IM"` `"IN"` `"IO"` `"IQ"` `"IR"` `"IS"` `"IT"` `"JE"` `"JM"` `"JO"` `"JP"` `"KE"` `"KG"` `"KH"` `"KI"` `"KM"` `"KN"` `"KP"` `"KR"` `"KW"` `"KY"` `"KZ"` `"LA"` `"LB"` `"LC"` `"LI"` `"LK"` `"LR"` `"LS"` `"LT"` `"LU"` `"LV"` `"LY"` `"MA"` `"MC"` `"MD"` `"ME"` `"MF"` `"MG"` `"MH"` `"MK"` `"ML"` `"MM"` `"MN"` `"MO"` `"MP"` `"MQ"` `"MR"` `"MS"` `"MT"` `"MU"` `"MV"` `"MW"` `"MX"` `"MY"` `"MZ"` `"NA"` `"NC"` `"NE"` `"NF"` `"NG"` `"NI"` `"NL"` `"NO"` `"NP"` `"NR"` `"NU"` `"NZ"` `"OM"` `"OTHER"` `"PA"` `"PE"` `"PF"` `"PG"` `"PH"` `"PK"` `"PL"` `"PM"` `"PN"` `"PR"` `"PS"` `"PT"` `"PW"` `"PY"` `"QA"` `"RE"` `"RO"` `"RS"` `"RU"` `"RW"` `"SA"` `"SB"` `"SC"` `"SD"` `"SE"` `"SG"` `"SH"` `"SI"` `"SJ"` `"SK"` `"SL"` `"SM"` `"SN"` `"SO"` `"SR"` `"SS"` `"ST"` `"SV"` `"SX"` `"SY"` `"SZ"` `"TC"` `"TD"` `"TF"` `"TG"` `"TH"` `"TJ"` `"TK"` `"TL"` `"TM"` `"TN"` `"TO"` `"TR"` `"TT"` `"TV"` `"TW"` `"TZ"` `"UA"` `"UG"` `"UM"` `"US"` `"UY"` `"UZ"` `"VA"` `"VC"` `"VE"` `"VG"` `"VI"` `"VN"` `"VU"` `"WF"` `"WS"` `"YE"` `"YT"` `"ZA"` `"ZM"` `"ZW"` **top\_keyword\_prev**: The keyword that brings the most paid traffic to a page on the comparison date.   type: string nullable **top\_keyword\_volume** (10 units): An estimation of the average monthly number of searches for the top keyword over the latest month or over the latest known 12 months of data depending on the "volume\_mode" parameter.   type: integer nullable **top\_keyword\_volume\_prev** (10 units): The search volume on the comparison date.   type: integer nullable **traffic** (10 units): An estimation of the number of monthly visitors that your target gets from paid search for a keyword.   type: integer **traffic\_diff**: The change in traffic between your selected dates.   type: integer **traffic\_diff\_percent**: The change in traffic between your selected dates, in percents.   type: integer **traffic\_prev** (10 units): The traffic from a keyword on the comparison date.   type: integer **url**: The ranking page URL.   type: url nullable **url\_prev**: The ranking page URL on the comparison date.   type: url nullable **url\_visual**: The URL of an ad as seen in search results.   type: string **url\_visual\_prev**: The URL of an ad on the comparison date.   type: string **value** (10 units): The estimated cost of a page"s monthly paid search traffic, in USD cents.   type: integer nullable **value\_diff**: The change in traffic value between your selected dates.   type: integer **value\_diff\_percent**: The change in traffic value between your selected dates, in percents.   type: integer **value\_merged** (10 units): The traffic value field optimized for sorting.   type: integer nullable **value\_prev** (10 units): The traffic value on the comparison date.   type: integer nullable **volume** (10 units): An estimation of the number of searches for a keyword over the latest month.   type: integer nullable **volume\_prev** (10 units): The search volume on the comparison date.   type: integer nullable **words**: The number of words in a keyword.   type: integer **words\_prev**: The number of words in a keyword on the comparison date.   type: integer
>
> **offset** `integer`
>
> \[Deprecated on 31 May 2024].
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **select** `string` *required*
>
> A comma-separated list of columns to return. See response schema for valid column identifiers.
>
> **target** `string` *required*
>
> The target of the search: a domain or a URL.
>
> **country** `string ("ad" | "ae" | "af" | "ag" | "ai" | "al" | "am" | "ao" | "ar" | "as" | "at" | "au" | "aw" | "az" | "ba" | "bb" | "bd" | "be" | "bf" | "bg" | "bh" | "bi" | "bj" | "bn" | "bo" | "br" | "bs" | "bt" | "bw" | "by" | "bz" | "ca" | "cd" | "cf" | "cg" | "ch" | "ci" | "ck" | "cl" | "cm" | "cn" | "co" | "cr" | "cu" | "cv" | "cy" | "cz" | "de" | "dj" | "dk" | "dm" | "do" | "dz" | "ec" | "ee" | "eg" | "es" | "et" | "fi" | "fj" | "fm" | "fo" | "fr" | "ga" | "gb" | "gd" | "ge" | "gf" | "gg" | "gh" | "gi" | "gl" | "gm" | "gn" | "gp" | "gq" | "gr" | "gt" | "gu" | "gy" | "hk" | "hn" | "hr" | "ht" | "hu" | "id" | "ie" | "il" | "im" | "in" | "iq" | "is" | "it" | "je" | "jm" | "jo" | "jp" | "ke" | "kg" | "kh" | "ki" | "kn" | "kr" | "kw" | "ky" | "kz" | "la" | "lb" | "lc" | "li" | "lk" | "ls" | "lt" | "lu" | "lv" | "ly" | "ma" | "mc" | "md" | "me" | "mg" | "mk" | "ml" | "mm" | "mn" | "mq" | "mr" | "ms" | "mt" | "mu" | "mv" | "mw" | "mx" | "my" | "mz" | "na" | "nc" | "ne" | "ng" | "ni" | "nl" | "no" | "np" | "nr" | "nu" | "nz" | "om" | "pa" | "pe" | "pf" | "pg" | "ph" | "pk" | "pl" | "pn" | "pr" | "ps" | "pt" | "py" | "qa" | "re" | "ro" | "rs" | "ru" | "rw" | "sa" | "sb" | "sc" | "se" | "sg" | "sh" | "si" | "sk" | "sl" | "sm" | "sn" | "so" | "sr" | "st" | "sv" | "td" | "tg" | "th" | "tj" | "tk" | "tl" | "tm" | "tn" | "to" | "tr" | "tt" | "tw" | "tz" | "ua" | "ug" | "us" | "uy" | "uz" | "vc" | "ve" | "vg" | "vi" | "vn" | "vu" | "ws" | "ye" | "yt" | "za" | "zm" | "zw")`
>
> A two-letter country code (ISO 3166-1 alpha-2).
>
> **timeout** `integer`
>
> A manual timeout duration in seconds.
>
> **order\_by** `string`
>
> A column to order results by. See response schema for valid column identifiers.
>
> **protocol** `string ("both" | "http" | "https")`
>
> The protocol of your target.
>
> **volume\_mode** `string ("monthly" | "average")`
>
> The search volume calculation mode: monthly or average. It affects volume, traffic, and traffic value.
>
> **date\_compared** `string`
>
> A date to compare metrics with in YYYY-MM-DD format.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Retrieve public crawler ips
>
> **Slug:** `AHREFS_RETRIEVE_PUBLIC_CRAWLER_IPS`
>
> Retrieves a list of IP addresses currently used by AhrefsBot, Ahrefs' web crawler. This endpoint provides essential information for webmasters and SEO professionals who want to verify the authenticity of requests coming from Ahrefs or manage their server's access rules. The returned list includes all active IP addresses utilized by AhrefsBot for crawling websites. This tool should be used when you need to confirm if a particular IP belongs to Ahrefs or when updating your website's firewall rules to allow Ahrefs' crawler. It's important to note that this list may change over time, so it's recommended to check it periodically for the most up-to-date information.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0 per request
>
> #### Input Parameters
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Retrieve related terms
>
> **Slug:** `AHREFS_RETRIEVE_RELATED_TERMS`
>
> Retrieves related keyword ideas for a given keyword or keyword list in a specified country. Related terms may include metrics such as search volume and keyword difficulty.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **limit** `integer`
>
> The number of results to return.
>
> **terms** `string ("also_rank_for" | "also_talk_about" | "all")`
>
> Related keywords which top-ranking pages also rank for (`also_rank_for`), additional keywords frequently mentioned in top-ranking pages (`also_talk_about`), or combination of both (`all`).
>
> **where** `string`
>
> The filter expression. The following column identifiers are recognized (this differs from the identifiers recognized by the `select` parameter). **cpc**: Cost Per Click shows the average price that advertisers pay for each ad click in paid search results for a keyword, in USD cents.   type: integer nullable **cps**: Clicks Per Search (or CPS) is the ratio of Clicks to Keyword Search volume. It shows how many different search results get clicked, on average, when people search for the target keyword in a given country.   type: float nullable **difficulty** (10 units): An estimation of how hard it is to rank in the top 10 organic search results for a keyword on a 100-point scale.   type: integer nullable **first\_seen**: The date when we first checked search engine results for a keyword.   type: datetime nullable **global\_volume** (10 units): How many times per month, on average, people search for the target keyword across all countries in our database.   type: integer nullable **intents** (10 units): Indicates the purpose behind the user"s search query. Object fields: `informational`, `navigational`, `commercial`, `transactional`, `branded` or `local`. All the fields are of type `bool`, with posible values `true` or `false`.   type: object nullable **keyword**:    type: string **parent\_topic**: Parent Topic determines if you can rank for your target keyword while targeting a more general topic on your page instead. To identify the Parent Topic, we take the #1 ranking page for your keyword and find the keyword responsible for sending the most traffic to that page.   type: string nullable **serp\_domain\_rating\_top10\_min**: The keyword must have at least one ranking position in the top 10 results with a DR of up to this value.   type: float nullable **serp\_domain\_rating\_top5\_min**: The keyword must have at least one ranking position in the top 5 results with a DR of up to this value.   type: float nullable **serp\_features**: The enriched results on a search engine results page (SERP) that are not traditional organic results.   type: array(string)   enum: `"ai_overview_sitelink"` `"snippet"` `"ai_overview"` `"local_pack"` `"sitelink"` `"news"` `"image"` `"video"` `"discussion"` `"tweet"` `"paid_top"` `"paid_bottom"` `"paid_sitelink"` `"shopping"` `"knowledge_card"` `"knowledge_panel"` `"question"` `"image_th"` `"video_th"` `"organic_shopping"` **serp\_last\_update**: The date when we last checked search engine results for a keyword.   type: datetime nullable **traffic\_potential** (10 units): The sum of organic traffic that the #1 ranking page for your target keyword receives from all the keywords that it ranks for.   type: integer nullable **volume** (10 units): An estimation of the average monthly number of searches for a keyword over the latest known 12 months of data.   type: integer nullable **volume\_desktop\_pct**: The percentage of searches for a keyword performed on desktop devices.   type: float nullable **volume\_mobile\_pct**: The percentage of searches for a keyword performed on mobile devices.   type: float nullable **word\_count**:    type: integer
>
> **offset** `integer`
>
> \[Deprecated on 31 May 2024].
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **select** `string` *required*
>
> A comma-separated list of columns to return. See response schema for valid column identifiers.
>
> **country** `string ("ad" | "ae" | "af" | "ag" | "ai" | "al" | "am" | "ao" | "ar" | "as" | "at" | "au" | "aw" | "az" | "ba" | "bb" | "bd" | "be" | "bf" | "bg" | "bh" | "bi" | "bj" | "bn" | "bo" | "br" | "bs" | "bt" | "bw" | "by" | "bz" | "ca" | "cd" | "cf" | "cg" | "ch" | "ci" | "ck" | "cl" | "cm" | "cn" | "co" | "cr" | "cu" | "cv" | "cy" | "cz" | "de" | "dj" | "dk" | "dm" | "do" | "dz" | "ec" | "ee" | "eg" | "es" | "et" | "fi" | "fj" | "fm" | "fo" | "fr" | "ga" | "gb" | "gd" | "ge" | "gf" | "gg" | "gh" | "gi" | "gl" | "gm" | "gn" | "gp" | "gq" | "gr" | "gt" | "gu" | "gy" | "hk" | "hn" | "hr" | "ht" | "hu" | "id" | "ie" | "il" | "im" | "in" | "iq" | "is" | "it" | "je" | "jm" | "jo" | "jp" | "ke" | "kg" | "kh" | "ki" | "kn" | "kr" | "kw" | "ky" | "kz" | "la" | "lb" | "lc" | "li" | "lk" | "ls" | "lt" | "lu" | "lv" | "ly" | "ma" | "mc" | "md" | "me" | "mg" | "mk" | "ml" | "mm" | "mn" | "mq" | "mr" | "ms" | "mt" | "mu" | "mv" | "mw" | "mx" | "my" | "mz" | "na" | "nc" | "ne" | "ng" | "ni" | "nl" | "no" | "np" | "nr" | "nu" | "nz" | "om" | "pa" | "pe" | "pf" | "pg" | "ph" | "pk" | "pl" | "pn" | "pr" | "ps" | "pt" | "py" | "qa" | "re" | "ro" | "rs" | "ru" | "rw" | "sa" | "sb" | "sc" | "se" | "sg" | "sh" | "si" | "sk" | "sl" | "sm" | "sn" | "so" | "sr" | "st" | "sv" | "td" | "tg" | "th" | "tj" | "tk" | "tl" | "tm" | "tn" | "to" | "tr" | "tt" | "tw" | "tz" | "ua" | "ug" | "us" | "uy" | "uz" | "vc" | "ve" | "vg" | "vi" | "vn" | "vu" | "ws" | "ye" | "yt" | "za" | "zm" | "zw")` *required*
>
> A two-letter country code (ISO 3166-1 alpha-2).
>
> **timeout** `integer`
>
> A manual timeout duration in seconds.
>
> **keywords** `string`
>
> A comma-separated list of keywords to show metrics for.
>
> **order\_by** `string`
>
> A column to order results by. See response schema for valid column identifiers.
>
> **view\_for** `string ("top_10" | "top_100")`
>
> View keywords for the top 10 or top 100 ranking pages.
>
> **keyword\_list\_id** `integer`
>
> The id of an existing keyword list to show metrics for.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Retrieve site explorer keywords history
>
> **Slug:** `AHREFS_RETRIEVE_SITE_EXPLORER_KEYWORDS_HISTORY`
>
> Retrieves historical keyword performance data for a specified website or domain using Ahrefs' Site Explorer. This endpoint provides insights into how keywords have performed over time, including changes in rankings, search volume, and potential traffic. It's particularly useful for analyzing SEO trends, understanding the impact of optimization efforts, and identifying seasonal patterns in keyword performance. The tool should be used when you need a comprehensive view of a website's keyword history to inform SEO strategies and content planning. It does not provide real-time data and may have limitations on the historical range available.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **mode** `string ("exact" | "prefix" | "domain" | "subdomains")`
>
> The scope of the search based on the target you entered.
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **select** `string`
>
> A comma-separated list of columns to return. See response schema for valid column identifiers.
>
> **target** `string` *required*
>
> The target of the search: a domain or a URL.
>
> **country** `string ("ad" | "ae" | "af" | "ag" | "ai" | "al" | "am" | "ao" | "ar" | "as" | "at" | "au" | "aw" | "az" | "ba" | "bb" | "bd" | "be" | "bf" | "bg" | "bh" | "bi" | "bj" | "bn" | "bo" | "br" | "bs" | "bt" | "bw" | "by" | "bz" | "ca" | "cd" | "cf" | "cg" | "ch" | "ci" | "ck" | "cl" | "cm" | "cn" | "co" | "cr" | "cu" | "cv" | "cy" | "cz" | "de" | "dj" | "dk" | "dm" | "do" | "dz" | "ec" | "ee" | "eg" | "es" | "et" | "fi" | "fj" | "fm" | "fo" | "fr" | "ga" | "gb" | "gd" | "ge" | "gf" | "gg" | "gh" | "gi" | "gl" | "gm" | "gn" | "gp" | "gq" | "gr" | "gt" | "gu" | "gy" | "hk" | "hn" | "hr" | "ht" | "hu" | "id" | "ie" | "il" | "im" | "in" | "iq" | "is" | "it" | "je" | "jm" | "jo" | "jp" | "ke" | "kg" | "kh" | "ki" | "kn" | "kr" | "kw" | "ky" | "kz" | "la" | "lb" | "lc" | "li" | "lk" | "ls" | "lt" | "lu" | "lv" | "ly" | "ma" | "mc" | "md" | "me" | "mg" | "mk" | "ml" | "mm" | "mn" | "mq" | "mr" | "ms" | "mt" | "mu" | "mv" | "mw" | "mx" | "my" | "mz" | "na" | "nc" | "ne" | "ng" | "ni" | "nl" | "no" | "np" | "nr" | "nu" | "nz" | "om" | "pa" | "pe" | "pf" | "pg" | "ph" | "pk" | "pl" | "pn" | "pr" | "ps" | "pt" | "py" | "qa" | "re" | "ro" | "rs" | "ru" | "rw" | "sa" | "sb" | "sc" | "se" | "sg" | "sh" | "si" | "sk" | "sl" | "sm" | "sn" | "so" | "sr" | "st" | "sv" | "td" | "tg" | "th" | "tj" | "tk" | "tl" | "tm" | "tn" | "to" | "tr" | "tt" | "tw" | "tz" | "ua" | "ug" | "us" | "uy" | "uz" | "vc" | "ve" | "vg" | "vi" | "vn" | "vu" | "ws" | "ye" | "yt" | "za" | "zm" | "zw")`
>
> A two-letter country code (ISO 3166-1 alpha-2).
>
> **date\_to** `string`
>
> The end date of the historical period in YYYY-MM-DD format.
>
> **protocol** `string ("both" | "http" | "https")`
>
> The protocol of your target.
>
> **date\_from** `string` *required*
>
> The start date of the historical period in YYYY-MM-DD format.
>
> **history\_grouping** `string ("daily" | "weekly" | "monthly")`
>
> The time interval used to group historical data.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Retrieve site explorer metrics
>
> **Slug:** `AHREFS_RETRIEVE_SITE_EXPLORER_METRICS`
>
> Retrieves Site Explorer SEO metrics for a target domain or URL on a specified date, including backlink, referring-page and crawled-page counts. The analysis scope can be adjusted for the target.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **date** `string` *required*
>
> A date to report metrics on in YYYY-MM-DD format.
>
> **mode** `string ("exact" | "prefix" | "domain" | "subdomains")`
>
> The scope of the search based on the target you entered.
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **target** `string` *required*
>
> The target of the search: a domain or a URL.
>
> **country** `string ("ad" | "ae" | "af" | "ag" | "ai" | "al" | "am" | "ao" | "ar" | "as" | "at" | "au" | "aw" | "az" | "ba" | "bb" | "bd" | "be" | "bf" | "bg" | "bh" | "bi" | "bj" | "bn" | "bo" | "br" | "bs" | "bt" | "bw" | "by" | "bz" | "ca" | "cd" | "cf" | "cg" | "ch" | "ci" | "ck" | "cl" | "cm" | "cn" | "co" | "cr" | "cu" | "cv" | "cy" | "cz" | "de" | "dj" | "dk" | "dm" | "do" | "dz" | "ec" | "ee" | "eg" | "es" | "et" | "fi" | "fj" | "fm" | "fo" | "fr" | "ga" | "gb" | "gd" | "ge" | "gf" | "gg" | "gh" | "gi" | "gl" | "gm" | "gn" | "gp" | "gq" | "gr" | "gt" | "gu" | "gy" | "hk" | "hn" | "hr" | "ht" | "hu" | "id" | "ie" | "il" | "im" | "in" | "iq" | "is" | "it" | "je" | "jm" | "jo" | "jp" | "ke" | "kg" | "kh" | "ki" | "kn" | "kr" | "kw" | "ky" | "kz" | "la" | "lb" | "lc" | "li" | "lk" | "ls" | "lt" | "lu" | "lv" | "ly" | "ma" | "mc" | "md" | "me" | "mg" | "mk" | "ml" | "mm" | "mn" | "mq" | "mr" | "ms" | "mt" | "mu" | "mv" | "mw" | "mx" | "my" | "mz" | "na" | "nc" | "ne" | "ng" | "ni" | "nl" | "no" | "np" | "nr" | "nu" | "nz" | "om" | "pa" | "pe" | "pf" | "pg" | "ph" | "pk" | "pl" | "pn" | "pr" | "ps" | "pt" | "py" | "qa" | "re" | "ro" | "rs" | "ru" | "rw" | "sa" | "sb" | "sc" | "se" | "sg" | "sh" | "si" | "sk" | "sl" | "sm" | "sn" | "so" | "sr" | "st" | "sv" | "td" | "tg" | "th" | "tj" | "tk" | "tl" | "tm" | "tn" | "to" | "tr" | "tt" | "tw" | "tz" | "ua" | "ug" | "us" | "uy" | "uz" | "vc" | "ve" | "vg" | "vi" | "vn" | "vu" | "ws" | "ye" | "yt" | "za" | "zm" | "zw")`
>
> A two-letter country code (ISO 3166-1 alpha-2).
>
> **protocol** `string ("both" | "http" | "https")`
>
> The protocol of your target.
>
> **volume\_mode** `string ("monthly" | "average")`
>
> The search volume calculation mode: monthly or average. It affects volume, traffic, and traffic value.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Retrieve site explorer metrics history
>
> **Slug:** `AHREFS_RETRIEVE_SITE_EXPLORER_METRICS_HISTORY`
>
> Retrieves historical Site Explorer traffic metrics for a target website or URL over a specified period, including estimated organic and paid traffic and cost. Results can be grouped by time interval for trend analysis.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **mode** `string ("exact" | "prefix" | "domain" | "subdomains")`
>
> The scope of the search based on the target you entered.
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **select** `string`
>
> A comma-separated list of columns to return. See response schema for valid column identifiers.
>
> **target** `string` *required*
>
> The target of the search: a domain or a URL.
>
> **country** `string ("ad" | "ae" | "af" | "ag" | "ai" | "al" | "am" | "ao" | "ar" | "as" | "at" | "au" | "aw" | "az" | "ba" | "bb" | "bd" | "be" | "bf" | "bg" | "bh" | "bi" | "bj" | "bn" | "bo" | "br" | "bs" | "bt" | "bw" | "by" | "bz" | "ca" | "cd" | "cf" | "cg" | "ch" | "ci" | "ck" | "cl" | "cm" | "cn" | "co" | "cr" | "cu" | "cv" | "cy" | "cz" | "de" | "dj" | "dk" | "dm" | "do" | "dz" | "ec" | "ee" | "eg" | "es" | "et" | "fi" | "fj" | "fm" | "fo" | "fr" | "ga" | "gb" | "gd" | "ge" | "gf" | "gg" | "gh" | "gi" | "gl" | "gm" | "gn" | "gp" | "gq" | "gr" | "gt" | "gu" | "gy" | "hk" | "hn" | "hr" | "ht" | "hu" | "id" | "ie" | "il" | "im" | "in" | "iq" | "is" | "it" | "je" | "jm" | "jo" | "jp" | "ke" | "kg" | "kh" | "ki" | "kn" | "kr" | "kw" | "ky" | "kz" | "la" | "lb" | "lc" | "li" | "lk" | "ls" | "lt" | "lu" | "lv" | "ly" | "ma" | "mc" | "md" | "me" | "mg" | "mk" | "ml" | "mm" | "mn" | "mq" | "mr" | "ms" | "mt" | "mu" | "mv" | "mw" | "mx" | "my" | "mz" | "na" | "nc" | "ne" | "ng" | "ni" | "nl" | "no" | "np" | "nr" | "nu" | "nz" | "om" | "pa" | "pe" | "pf" | "pg" | "ph" | "pk" | "pl" | "pn" | "pr" | "ps" | "pt" | "py" | "qa" | "re" | "ro" | "rs" | "ru" | "rw" | "sa" | "sb" | "sc" | "se" | "sg" | "sh" | "si" | "sk" | "sl" | "sm" | "sn" | "so" | "sr" | "st" | "sv" | "td" | "tg" | "th" | "tj" | "tk" | "tl" | "tm" | "tn" | "to" | "tr" | "tt" | "tw" | "tz" | "ua" | "ug" | "us" | "uy" | "uz" | "vc" | "ve" | "vg" | "vi" | "vn" | "vu" | "ws" | "ye" | "yt" | "za" | "zm" | "zw")`
>
> A two-letter country code (ISO 3166-1 alpha-2).
>
> **date\_to** `string`
>
> The end date of the historical period in YYYY-MM-DD format.
>
> **protocol** `string ("both" | "http" | "https")`
>
> The protocol of your target.
>
> **date\_from** `string` *required*
>
> The start date of the historical period in YYYY-MM-DD format.
>
> **volume\_mode** `string ("monthly" | "average")`
>
> The search volume calculation mode: monthly or average. It affects volume, traffic, and traffic value.
>
> **history\_grouping** `string ("daily" | "weekly" | "monthly")`
>
> The time interval used to group historical data.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Retrieve site explorer pages history
>
> **Slug:** `AHREFS_RETRIEVE_SITE_EXPLORER_PAGES_HISTORY`
>
> Retrieves historical page counts for a target domain or URL from Ahrefs Site Explorer over a specified period. Use it to analyze page-count trends over time.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **mode** `string ("exact" | "prefix" | "domain" | "subdomains")`
>
> The scope of the search based on the target you entered.
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **target** `string` *required*
>
> The target of the search: a domain or a URL.
>
> **country** `string ("ad" | "ae" | "af" | "ag" | "ai" | "al" | "am" | "ao" | "ar" | "as" | "at" | "au" | "aw" | "az" | "ba" | "bb" | "bd" | "be" | "bf" | "bg" | "bh" | "bi" | "bj" | "bn" | "bo" | "br" | "bs" | "bt" | "bw" | "by" | "bz" | "ca" | "cd" | "cf" | "cg" | "ch" | "ci" | "ck" | "cl" | "cm" | "cn" | "co" | "cr" | "cu" | "cv" | "cy" | "cz" | "de" | "dj" | "dk" | "dm" | "do" | "dz" | "ec" | "ee" | "eg" | "es" | "et" | "fi" | "fj" | "fm" | "fo" | "fr" | "ga" | "gb" | "gd" | "ge" | "gf" | "gg" | "gh" | "gi" | "gl" | "gm" | "gn" | "gp" | "gq" | "gr" | "gt" | "gu" | "gy" | "hk" | "hn" | "hr" | "ht" | "hu" | "id" | "ie" | "il" | "im" | "in" | "iq" | "is" | "it" | "je" | "jm" | "jo" | "jp" | "ke" | "kg" | "kh" | "ki" | "kn" | "kr" | "kw" | "ky" | "kz" | "la" | "lb" | "lc" | "li" | "lk" | "ls" | "lt" | "lu" | "lv" | "ly" | "ma" | "mc" | "md" | "me" | "mg" | "mk" | "ml" | "mm" | "mn" | "mq" | "mr" | "ms" | "mt" | "mu" | "mv" | "mw" | "mx" | "my" | "mz" | "na" | "nc" | "ne" | "ng" | "ni" | "nl" | "no" | "np" | "nr" | "nu" | "nz" | "om" | "pa" | "pe" | "pf" | "pg" | "ph" | "pk" | "pl" | "pn" | "pr" | "ps" | "pt" | "py" | "qa" | "re" | "ro" | "rs" | "ru" | "rw" | "sa" | "sb" | "sc" | "se" | "sg" | "sh" | "si" | "sk" | "sl" | "sm" | "sn" | "so" | "sr" | "st" | "sv" | "td" | "tg" | "th" | "tj" | "tk" | "tl" | "tm" | "tn" | "to" | "tr" | "tt" | "tw" | "tz" | "ua" | "ug" | "us" | "uy" | "uz" | "vc" | "ve" | "vg" | "vi" | "vn" | "vu" | "ws" | "ye" | "yt" | "za" | "zm" | "zw")`
>
> A two-letter country code (ISO 3166-1 alpha-2).
>
> **date\_to** `string`
>
> The end date of the historical period in YYYY-MM-DD format.
>
> **protocol** `string ("both" | "http" | "https")`
>
> The protocol of your target.
>
> **date\_from** `string` *required*
>
> The start date of the historical period in YYYY-MM-DD format.
>
> **history\_grouping** `string ("daily" | "weekly" | "monthly")`
>
> The time interval used to group historical data.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Retrieve site explorer referring domains history
>
> **Slug:** `AHREFS_RETRIEVE_SITE_EXPLORER_REFERRING_DOMAINS_HISTORY`
>
> Retrieves the historical data of referring domains for a specified website or URL over time. This endpoint is part of Ahrefs' Site Explorer tool and provides valuable insights into the growth or decline of a website's backlink profile. It should be used when analyzing the long-term SEO performance of a website, identifying trends in link building efforts, or comparing the backlink acquisition rates of different domains. The data returned includes the number of referring domains at various points in time, allowing users to track changes and potentially correlate them with specific events or marketing efforts. This endpoint is particularly useful for SEO professionals, digital marketers, and website owners who need to monitor their site's authority growth over time or analyze competitors' link building strategies.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **mode** `string ("exact" | "prefix" | "domain" | "subdomains")`
>
> The scope of the search based on the target you entered.
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **target** `string` *required*
>
> The target of the search: a domain or a URL.
>
> **date\_to** `string`
>
> The end date of the historical period in YYYY-MM-DD format.
>
> **protocol** `string ("both" | "http" | "https")`
>
> The protocol of your target.
>
> **date\_from** `string` *required*
>
> The start date of the historical period in YYYY-MM-DD format.
>
> **history\_grouping** `string ("daily" | "weekly" | "monthly")`
>
> The time interval used to group historical data.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Retrieve subscription limits and usage
>
> **Slug:** `AHREFS_RETRIEVE_SUBSCRIPTION_LIMITS_AND_USAGE`
>
> Retrieves an Ahrefs account's subscription limits and remaining API usage allowance. This account-scoped action requires connecting your own Ahrefs account.
>
> #### Input Parameters
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Retrieve top pages from site explorer
>
> **Slug:** `AHREFS_RETRIEVE_TOP_PAGES_FROM_SITE_EXPLORER`
>
> Retrieves data about the top-performing pages of a specified website using Ahrefs' Site Explorer tool. This endpoint provides valuable insights into a site's most successful content based on various SEO metrics. It's particularly useful for content analysis, competitive research, and identifying opportunities for optimization. The data returned includes details such as page URLs, organic traffic estimates, ranking keywords, and other relevant SEO metrics for each top page. Use this endpoint when you need to analyze the best-performing content of a website or compare top pages across different domains. Note that the results are based on Ahrefs' data and estimates, which may not always reflect real-time traffic or exact Google rankings.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **date** `string` *required*
>
> A date to report metrics on in YYYY-MM-DD format.
>
> **mode** `string ("exact" | "prefix" | "domain" | "subdomains")`
>
> The scope of the search based on the target you entered.
>
> **limit** `integer`
>
> The number of results to return.
>
> **where** `string`
>
> The filter expression. The following column identifiers are recognized (this differs from the identifiers recognized by the `select` parameter). **cpc**   type: integer nullable **cpc\_prev**: The CPC metric on the comparison date.   type: integer nullable **has\_thumbnail**: The position has a thumbnail.   type: boolean **has\_thumbnail\_prev**: The position has a thumbnail on the comparison date.   type: boolean **has\_video**: The position has a video.   type: boolean **has\_video\_prev**: The position has a video on the comparison date.   type: boolean **keyword**: The keyword your target ranks for.   type: string **keyword\_difficulty** (10 units): An estimation of how hard it is to rank in the top 10 organic search results for a keyword on a 100-point scale.   type: integer nullable **keyword\_difficulty\_prev** (10 units): The keyword difficulty on the comparison date.   type: integer nullable **keyword\_prev**: The keyword your target ranks for on the comparison date.   type: string **keywords**: The total number of keywords that your target ranks for in the top 100 organic search results.   type: integer **keywords\_diff**: The change in keywords between your selected dates.   type: integer **keywords\_diff\_percent**: The change in keywords between your selected dates, in percents.   type: integer **keywords\_merged**: The total number of keywords optimized for sorting.   type: integer **keywords\_prev**: The keyword your target ranks for on the comparison date.   type: integer **position**: The position your target ranks for in the organic search results for a keyword.   type: integer **position\_kind**: The kind of a position: organic, paid or a SERP feature. This applies to all positions for a given keyword and URL before picking the top position.   type: string   enum: `"paid_top"` `"paid_bottom"` `"paid_right"` `"paid_sitelink"` `"organic"` `"sitelink"` `"snippet"` `"image"` `"article"` `"knowledge_card"` `"knowledge_panel"` `"local_pack"` `"local_teaser"` `"news"` `"question"` `"review"` `"shopping"` `"tweet"` `"spelling"` `"video"` `"discussion"` `"ai_overview"` `"ai_overview_sitelink"` `"organic_shopping"` **position\_kind\_prev**: The kind of a position on the comparison date.   type: string   enum: `"paid_top"` `"paid_bottom"` `"paid_right"` `"paid_sitelink"` `"organic"` `"sitelink"` `"snippet"` `"image"` `"article"` `"knowledge_card"` `"knowledge_panel"` `"local_pack"` `"local_teaser"` `"news"` `"question"` `"review"` `"shopping"` `"tweet"` `"spelling"` `"video"` `"discussion"` `"ai_overview"` `"ai_overview_sitelink"` `"organic_shopping"` **position\_prev**: The position of your target for a given keyword on the comparison date.   type: integer **raw\_url**: The ranking page URL in encoded format.   type: string **raw\_url\_prev**: The ranking page URL on the comparison date in encoded format.   type: string **serp\_features**   type: array(string)   enum: `"paid_top"` `"paid_bottom"` `"paid_right"` `"paid_sitelink"` `"organic"` `"sitelink"` `"snippet"` `"image"` `"article"` `"knowledge_card"` `"knowledge_panel"` `"local_pack"` `"local_teaser"` `"news"` `"question"` `"review"` `"shopping"` `"tweet"` `"spelling"` `"video"` `"discussion"` `"ai_overview"` `"ai_overview_sitelink"` `"organic_shopping"` `"image_th"` `"video_th"` `"ai_overview_found"` **serp\_features\_prev**: The SERP features on the comparison date.   type: array(string)   enum: `"paid_top"` `"paid_bottom"` `"paid_right"` `"paid_sitelink"` `"organic"` `"sitelink"` `"snippet"` `"image"` `"article"` `"knowledge_card"` `"knowledge_panel"` `"local_pack"` `"local_teaser"` `"news"` `"question"` `"review"` `"shopping"` `"tweet"` `"spelling"` `"video"` `"discussion"` `"ai_overview"` `"ai_overview_sitelink"` `"organic_shopping"` `"image_th"` `"video_th"` `"ai_overview_found"` **status**: The status of a page: the new page that just started to rank ("left"), the lost page that disappeared from search results ("right"), or no change ("both").   type: string   enum: `"left"` `"right"` `"both"` **sum\_traffic** (10 units): An estimation of the monthly organic search traffic that a page gets from all the keywords that it ranks for.   type: integer nullable **sum\_traffic\_merged** (10 units): The traffic field optimized for sorting.   type: integer **sum\_traffic\_prev** (10 units): The traffic on the comparison date.   type: integer nullable **top\_keyword**: The keyword that brings the most organic traffic to a page.   type: string nullable **top\_keyword\_best\_position**: The ranking position that a page holds for its top keyword.   type: integer nullable **top\_keyword\_best\_position\_diff**: The change in the top position between your selected dates.   type: integer nullable **top\_keyword\_best\_position\_kind**: The kind of the top position: organic, paid or a SERP feature.   type: string nullable   enum: `"paid_top"` `"paid_bottom"` `"paid_right"` `"paid_sitelink"` `"organic"` `"sitelink"` `"snippet"` `"image"` `"article"` `"knowledge_card"` `"knowledge_panel"` `"local_pack"` `"local_teaser"` `"news"` `"question"` `"review"` `"shopping"` `"tweet"` `"spelling"` `"video"` `"discussion"` `"ai_overview"` `"ai_overview_sitelink"` `"organic_shopping"` **top\_keyword\_best\_position\_kind\_prev**: The kind of the top position on the comparison date.   type: string nullable   enum: `"paid_top"` `"paid_bottom"` `"paid_right"` `"paid_sitelink"` `"organic"` `"sitelink"` `"snippet"` `"image"` `"article"` `"knowledge_card"` `"knowledge_panel"` `"local_pack"` `"local_teaser"` `"news"` `"question"` `"review"` `"shopping"` `"tweet"` `"spelling"` `"video"` `"discussion"` `"ai_overview"` `"ai_overview_sitelink"` `"organic_shopping"` **top\_keyword\_best\_position\_prev**: The top position on the comparison date.   type: integer nullable **top\_keyword\_best\_position\_title**: The title displayed for the page in its top keyword"s SERP.   type: string nullable **top\_keyword\_best\_position\_title\_prev**: The title displayed for the page in its top keyword"s SERP on the comparison date.   type: string nullable **top\_keyword\_country**: The country in which a page ranks for its top keyword.   type: string nullable   enum: `"AD"` `"AE"` `"AF"` `"AG"` `"AI"` `"AL"` `"AM"` `"AO"` `"AQ"` `"AR"` `"AS"` `"AT"` `"AU"` `"AW"` `"AX"` `"AZ"` `"BA"` `"BB"` `"BD"` `"BE"` `"BF"` `"BG"` `"BH"` `"BI"` `"BJ"` `"BL"` `"BM"` `"BN"` `"BO"` `"BQ"` `"BR"` `"BS"` `"BT"` `"BV"` `"BW"` `"BY"` `"BZ"` `"CA"` `"CC"` `"CD"` `"CF"` `"CG"` `"CH"` `"CI"` `"CK"` `"CL"` `"CM"` `"CN"` `"CO"` `"CR"` `"CU"` `"CV"` `"CW"` `"CX"` `"CY"` `"CZ"` `"DE"` `"DJ"` `"DK"` `"DM"` `"DO"` `"DZ"` `"EC"` `"EE"` `"EG"` `"EH"` `"ER"` `"ES"` `"ET"` `"FI"` `"FJ"` `"FK"` `"FM"` `"FO"` `"FR"` `"GA"` `"GB"` `"GD"` `"GE"` `"GF"` `"GG"` `"GH"` `"GI"` `"GL"` `"GM"` `"GN"` `"GP"` `"GQ"` `"GR"` `"GS"` `"GT"` `"GU"` `"GW"` `"GY"` `"HK"` `"HM"` `"HN"` `"HR"` `"HT"` `"HU"` `"ID"` `"IE"` `"IL"` `"IM"` `"IN"` `"IO"` `"IQ"` `"IR"` `"IS"` `"IT"` `"JE"` `"JM"` `"JO"` `"JP"` `"KE"` `"KG"` `"KH"` `"KI"` `"KM"` `"KN"` `"KP"` `"KR"` `"KW"` `"KY"` `"KZ"` `"LA"` `"LB"` `"LC"` `"LI"` `"LK"` `"LR"` `"LS"` `"LT"` `"LU"` `"LV"` `"LY"` `"MA"` `"MC"` `"MD"` `"ME"` `"MF"` `"MG"` `"MH"` `"MK"` `"ML"` `"MM"` `"MN"` `"MO"` `"MP"` `"MQ"` `"MR"` `"MS"` `"MT"` `"MU"` `"MV"` `"MW"` `"MX"` `"MY"` `"MZ"` `"NA"` `"NC"` `"NE"` `"NF"` `"NG"` `"NI"` `"NL"` `"NO"` `"NP"` `"NR"` `"NU"` `"NZ"` `"OM"` `"OTHER"` `"PA"` `"PE"` `"PF"` `"PG"` `"PH"` `"PK"` `"PL"` `"PM"` `"PN"` `"PR"` `"PS"` `"PT"` `"PW"` `"PY"` `"QA"` `"RE"` `"RO"` `"RS"` `"RU"` `"RW"` `"SA"` `"SB"` `"SC"` `"SD"` `"SE"` `"SG"` `"SH"` `"SI"` `"SJ"` `"SK"` `"SL"` `"SM"` `"SN"` `"SO"` `"SR"` `"SS"` `"ST"` `"SV"` `"SX"` `"SY"` `"SZ"` `"TC"` `"TD"` `"TF"` `"TG"` `"TH"` `"TJ"` `"TK"` `"TL"` `"TM"` `"TN"` `"TO"` `"TR"` `"TT"` `"TV"` `"TW"` `"TZ"` `"UA"` `"UG"` `"UM"` `"US"` `"UY"` `"UZ"` `"VA"` `"VC"` `"VE"` `"VG"` `"VI"` `"VN"` `"VU"` `"WF"` `"WS"` `"YE"` `"YT"` `"ZA"` `"ZM"` `"ZW"` **top\_keyword\_country\_prev**: The country in which a page ranks for its top keyword on the comparison date.   type: string nullable   enum: `"AD"` `"AE"` `"AF"` `"AG"` `"AI"` `"AL"` `"AM"` `"AO"` `"AQ"` `"AR"` `"AS"` `"AT"` `"AU"` `"AW"` `"AX"` `"AZ"` `"BA"` `"BB"` `"BD"` `"BE"` `"BF"` `"BG"` `"BH"` `"BI"` `"BJ"` `"BL"` `"BM"` `"BN"` `"BO"` `"BQ"` `"BR"` `"BS"` `"BT"` `"BV"` `"BW"` `"BY"` `"BZ"` `"CA"` `"CC"` `"CD"` `"CF"` `"CG"` `"CH"` `"CI"` `"CK"` `"CL"` `"CM"` `"CN"` `"CO"` `"CR"` `"CU"` `"CV"` `"CW"` `"CX"` `"CY"` `"CZ"` `"DE"` `"DJ"` `"DK"` `"DM"` `"DO"` `"DZ"` `"EC"` `"EE"` `"EG"` `"EH"` `"ER"` `"ES"` `"ET"` `"FI"` `"FJ"` `"FK"` `"FM"` `"FO"` `"FR"` `"GA"` `"GB"` `"GD"` `"GE"` `"GF"` `"GG"` `"GH"` `"GI"` `"GL"` `"GM"` `"GN"` `"GP"` `"GQ"` `"GR"` `"GS"` `"GT"` `"GU"` `"GW"` `"GY"` `"HK"` `"HM"` `"HN"` `"HR"` `"HT"` `"HU"` `"ID"` `"IE"` `"IL"` `"IM"` `"IN"` `"IO"` `"IQ"` `"IR"` `"IS"` `"IT"` `"JE"` `"JM"` `"JO"` `"JP"` `"KE"` `"KG"` `"KH"` `"KI"` `"KM"` `"KN"` `"KP"` `"KR"` `"KW"` `"KY"` `"KZ"` `"LA"` `"LB"` `"LC"` `"LI"` `"LK"` `"LR"` `"LS"` `"LT"` `"LU"` `"LV"` `"LY"` `"MA"` `"MC"` `"MD"` `"ME"` `"MF"` `"MG"` `"MH"` `"MK"` `"ML"` `"MM"` `"MN"` `"MO"` `"MP"` `"MQ"` `"MR"` `"MS"` `"MT"` `"MU"` `"MV"` `"MW"` `"MX"` `"MY"` `"MZ"` `"NA"` `"NC"` `"NE"` `"NF"` `"NG"` `"NI"` `"NL"` `"NO"` `"NP"` `"NR"` `"NU"` `"NZ"` `"OM"` `"OTHER"` `"PA"` `"PE"` `"PF"` `"PG"` `"PH"` `"PK"` `"PL"` `"PM"` `"PN"` `"PR"` `"PS"` `"PT"` `"PW"` `"PY"` `"QA"` `"RE"` `"RO"` `"RS"` `"RU"` `"RW"` `"SA"` `"SB"` `"SC"` `"SD"` `"SE"` `"SG"` `"SH"` `"SI"` `"SJ"` `"SK"` `"SL"` `"SM"` `"SN"` `"SO"` `"SR"` `"SS"` `"ST"` `"SV"` `"SX"` `"SY"` `"SZ"` `"TC"` `"TD"` `"TF"` `"TG"` `"TH"` `"TJ"` `"TK"` `"TL"` `"TM"` `"TN"` `"TO"` `"TR"` `"TT"` `"TV"` `"TW"` `"TZ"` `"UA"` `"UG"` `"UM"` `"US"` `"UY"` `"UZ"` `"VA"` `"VC"` `"VE"` `"VG"` `"VI"` `"VN"` `"VU"` `"WF"` `"WS"` `"YE"` `"YT"` `"ZA"` `"ZM"` `"ZW"` **top\_keyword\_prev**: The keyword that brings the most organic traffic to a page on the comparison date.   type: string nullable **top\_keyword\_volume** (10 units): An estimation of the average monthly number of searches for the top keyword over the latest month or over the latest known 12 months of data depending on the "volume\_mode" parameter.   type: integer nullable **top\_keyword\_volume\_prev** (10 units): The search volume on the comparison date.   type: integer nullable **traffic** (10 units): An estimation of the number of monthly visitors that your target gets from organic search for a keyword.   type: integer **traffic\_diff**: The change in traffic between your selected dates.   type: integer **traffic\_diff\_percent**: The change in traffic between your selected dates, in percents.   type: integer **traffic\_prev** (10 units): The traffic from a keyword on the comparison date.   type: integer **url**: The ranking page URL.   type: url nullable **url\_prev**: The ranking page URL on the comparison date.   type: url nullable **value** (10 units): The estimated value of a page"s monthly organic search traffic, in USD cents.   type: integer nullable **value\_diff**: The change in traffic value between your selected dates.   type: integer **value\_diff\_percent**: The change in traffic value between your selected dates, in percents.   type: integer **value\_merged** (10 units): The traffic value field optimized for sorting.   type: integer nullable **value\_prev** (10 units): The traffic value on the comparison date.   type: integer nullable **volume** (10 units): An estimation of the number of searches for a keyword over the latest month.   type: integer nullable **volume\_prev** (10 units): The search volume on the comparison date.   type: integer nullable **words**: The number of words in a keyword.   type: integer **words\_prev**: The number of words in a keyword on the comparison date.   type: integer
>
> **offset** `integer`
>
> \[Deprecated on 31 May 2024].
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **select** `string` *required*
>
> A comma-separated list of columns to return. See response schema for valid column identifiers.
>
> **target** `string` *required*
>
> The target of the search: a domain or a URL.
>
> **country** `string ("ad" | "ae" | "af" | "ag" | "ai" | "al" | "am" | "ao" | "ar" | "as" | "at" | "au" | "aw" | "az" | "ba" | "bb" | "bd" | "be" | "bf" | "bg" | "bh" | "bi" | "bj" | "bn" | "bo" | "br" | "bs" | "bt" | "bw" | "by" | "bz" | "ca" | "cd" | "cf" | "cg" | "ch" | "ci" | "ck" | "cl" | "cm" | "cn" | "co" | "cr" | "cu" | "cv" | "cy" | "cz" | "de" | "dj" | "dk" | "dm" | "do" | "dz" | "ec" | "ee" | "eg" | "es" | "et" | "fi" | "fj" | "fm" | "fo" | "fr" | "ga" | "gb" | "gd" | "ge" | "gf" | "gg" | "gh" | "gi" | "gl" | "gm" | "gn" | "gp" | "gq" | "gr" | "gt" | "gu" | "gy" | "hk" | "hn" | "hr" | "ht" | "hu" | "id" | "ie" | "il" | "im" | "in" | "iq" | "is" | "it" | "je" | "jm" | "jo" | "jp" | "ke" | "kg" | "kh" | "ki" | "kn" | "kr" | "kw" | "ky" | "kz" | "la" | "lb" | "lc" | "li" | "lk" | "ls" | "lt" | "lu" | "lv" | "ly" | "ma" | "mc" | "md" | "me" | "mg" | "mk" | "ml" | "mm" | "mn" | "mq" | "mr" | "ms" | "mt" | "mu" | "mv" | "mw" | "mx" | "my" | "mz" | "na" | "nc" | "ne" | "ng" | "ni" | "nl" | "no" | "np" | "nr" | "nu" | "nz" | "om" | "pa" | "pe" | "pf" | "pg" | "ph" | "pk" | "pl" | "pn" | "pr" | "ps" | "pt" | "py" | "qa" | "re" | "ro" | "rs" | "ru" | "rw" | "sa" | "sb" | "sc" | "se" | "sg" | "sh" | "si" | "sk" | "sl" | "sm" | "sn" | "so" | "sr" | "st" | "sv" | "td" | "tg" | "th" | "tj" | "tk" | "tl" | "tm" | "tn" | "to" | "tr" | "tt" | "tw" | "tz" | "ua" | "ug" | "us" | "uy" | "uz" | "vc" | "ve" | "vg" | "vi" | "vn" | "vu" | "ws" | "ye" | "yt" | "za" | "zm" | "zw")`
>
> A two-letter country code (ISO 3166-1 alpha-2).
>
> **timeout** `integer`
>
> A manual timeout duration in seconds.
>
> **order\_by** `string`
>
> A column to order results by. See response schema for valid column identifiers.
>
> **protocol** `string ("both" | "http" | "https")`
>
> The protocol of your target.
>
> **volume\_mode** `string ("monthly" | "average")`
>
> The search volume calculation mode: monthly or average. It affects volume, traffic, and traffic value.
>
> **date\_compared** `string`
>
> A date to compare metrics with in YYYY-MM-DD format.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Retrieve volume history
>
> **Slug:** `AHREFS_RETRIEVE_VOLUME_HISTORY`
>
> Retrieves the historical search volume data for a specified keyword using Ahrefs' Keywords Explorer tool. This endpoint provides valuable insights into how the popularity of a keyword has changed over time, allowing users to analyze trends, seasonality, and long-term shifts in search behavior. The data returned can be crucial for planning SEO strategies, content calendars, and understanding market dynamics. It's particularly useful when you need to assess the historical performance of keywords, identify seasonal patterns, or evaluate the potential of trending topics. The tool does not provide future predictions or real-time data, focusing instead on historical trends based on Ahrefs' comprehensive database of search information.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **country** `string ("ad" | "ae" | "af" | "ag" | "ai" | "al" | "am" | "ao" | "ar" | "as" | "at" | "au" | "aw" | "az" | "ba" | "bb" | "bd" | "be" | "bf" | "bg" | "bh" | "bi" | "bj" | "bn" | "bo" | "br" | "bs" | "bt" | "bw" | "by" | "bz" | "ca" | "cd" | "cf" | "cg" | "ch" | "ci" | "ck" | "cl" | "cm" | "cn" | "co" | "cr" | "cu" | "cv" | "cy" | "cz" | "de" | "dj" | "dk" | "dm" | "do" | "dz" | "ec" | "ee" | "eg" | "es" | "et" | "fi" | "fj" | "fm" | "fo" | "fr" | "ga" | "gb" | "gd" | "ge" | "gf" | "gg" | "gh" | "gi" | "gl" | "gm" | "gn" | "gp" | "gq" | "gr" | "gt" | "gu" | "gy" | "hk" | "hn" | "hr" | "ht" | "hu" | "id" | "ie" | "il" | "im" | "in" | "iq" | "is" | "it" | "je" | "jm" | "jo" | "jp" | "ke" | "kg" | "kh" | "ki" | "kn" | "kr" | "kw" | "ky" | "kz" | "la" | "lb" | "lc" | "li" | "lk" | "ls" | "lt" | "lu" | "lv" | "ly" | "ma" | "mc" | "md" | "me" | "mg" | "mk" | "ml" | "mm" | "mn" | "mq" | "mr" | "ms" | "mt" | "mu" | "mv" | "mw" | "mx" | "my" | "mz" | "na" | "nc" | "ne" | "ng" | "ni" | "nl" | "no" | "np" | "nr" | "nu" | "nz" | "om" | "pa" | "pe" | "pf" | "pg" | "ph" | "pk" | "pl" | "pn" | "pr" | "ps" | "pt" | "py" | "qa" | "re" | "ro" | "rs" | "ru" | "rw" | "sa" | "sb" | "sc" | "se" | "sg" | "sh" | "si" | "sk" | "sl" | "sm" | "sn" | "so" | "sr" | "st" | "sv" | "td" | "tg" | "th" | "tj" | "tk" | "tl" | "tm" | "tn" | "to" | "tr" | "tt" | "tw" | "tz" | "ua" | "ug" | "us" | "uy" | "uz" | "vc" | "ve" | "vg" | "vi" | "vn" | "vu" | "ws" | "ye" | "yt" | "za" | "zm" | "zw")` *required*
>
> A two-letter country code (ISO 3166-1 alpha-2).
>
> **keyword** `string` *required*
>
> The keyword to show metrics for.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not

> [accordion] Search suggestions explorer
>
> **Slug:** `AHREFS_SEARCH_SUGGESTIONS_EXPLORER`
>
> Retrieves search suggestions for keywords or an existing keyword list using Ahrefs Keywords Explorer. Suggestions may include associated metrics such as search volume, keyword difficulty and traffic potential for keyword research.
>
> **Instant:** Supported on the latest version.
>
> **Instant pricing:** \$0.006 per 10 API units used
>
> **Discount:** 65
>
> #### Input Parameters
>
> **limit** `integer`
>
> The number of results to return.
>
> **where** `string`
>
> The filter expression. The following column identifiers are recognized (this differs from the identifiers recognized by the `select` parameter). **cpc**: Cost Per Click shows the average price that advertisers pay for each ad click in paid search results for a keyword, in USD cents.   type: integer nullable **cps**: Clicks Per Search (or CPS) is the ratio of Clicks to Keyword Search volume. It shows how many different search results get clicked, on average, when people search for the target keyword in a given country.   type: float nullable **difficulty** (10 units): An estimation of how hard it is to rank in the top 10 organic search results for a keyword on a 100-point scale.   type: integer nullable **first\_seen**: The date when we first checked search engine results for a keyword.   type: datetime nullable **global\_volume** (10 units): How many times per month, on average, people search for the target keyword across all countries in our database.   type: integer nullable **intents** (10 units): Indicates the purpose behind the user"s search query. Object fields: `informational`, `navigational`, `commercial`, `transactional`, `branded` or `local`. All the fields are of type `bool`, with posible values `true` or `false`.   type: object nullable **keyword**:    type: string **parent\_topic**: Parent Topic determines if you can rank for your target keyword while targeting a more general topic on your page instead. To identify the Parent Topic, we take the #1 ranking page for your keyword and find the keyword responsible for sending the most traffic to that page.   type: string nullable **serp\_domain\_rating\_top10\_min**: The keyword must have at least one ranking position in the top 10 results with a DR of up to this value.   type: float nullable **serp\_domain\_rating\_top5\_min**: The keyword must have at least one ranking position in the top 5 results with a DR of up to this value.   type: float nullable **serp\_features**: The enriched results on a search engine results page (SERP) that are not traditional organic results.   type: array(string)   enum: `"ai_overview_sitelink"` `"snippet"` `"ai_overview"` `"local_pack"` `"sitelink"` `"news"` `"image"` `"video"` `"discussion"` `"tweet"` `"paid_top"` `"paid_bottom"` `"paid_sitelink"` `"shopping"` `"knowledge_card"` `"knowledge_panel"` `"question"` `"image_th"` `"video_th"` `"organic_shopping"` **serp\_last\_update**: The date when we last checked search engine results for a keyword.   type: datetime nullable **traffic\_potential** (10 units): The sum of organic traffic that the #1 ranking page for your target keyword receives from all the keywords that it ranks for.   type: integer nullable **volume** (10 units): An estimation of the average monthly number of searches for a keyword over the latest known 12 months of data.   type: integer nullable **volume\_desktop\_pct**: The percentage of searches for a keyword performed on desktop devices.   type: float nullable **volume\_mobile\_pct**: The percentage of searches for a keyword performed on mobile devices.   type: float nullable **word\_count**:    type: integer
>
> **offset** `integer`
>
> \[Deprecated on 31 May 2024].
>
> **output** `string ("json" | "csv" | "xml" | "php")`
>
> The output format.
>
> **select** `string` *required*
>
> A comma-separated list of columns to return. See response schema for valid column identifiers.
>
> **country** `string ("ad" | "ae" | "af" | "ag" | "ai" | "al" | "am" | "ao" | "ar" | "as" | "at" | "au" | "aw" | "az" | "ba" | "bb" | "bd" | "be" | "bf" | "bg" | "bh" | "bi" | "bj" | "bn" | "bo" | "br" | "bs" | "bt" | "bw" | "by" | "bz" | "ca" | "cd" | "cf" | "cg" | "ch" | "ci" | "ck" | "cl" | "cm" | "cn" | "co" | "cr" | "cu" | "cv" | "cy" | "cz" | "de" | "dj" | "dk" | "dm" | "do" | "dz" | "ec" | "ee" | "eg" | "es" | "et" | "fi" | "fj" | "fm" | "fo" | "fr" | "ga" | "gb" | "gd" | "ge" | "gf" | "gg" | "gh" | "gi" | "gl" | "gm" | "gn" | "gp" | "gq" | "gr" | "gt" | "gu" | "gy" | "hk" | "hn" | "hr" | "ht" | "hu" | "id" | "ie" | "il" | "im" | "in" | "iq" | "is" | "it" | "je" | "jm" | "jo" | "jp" | "ke" | "kg" | "kh" | "ki" | "kn" | "kr" | "kw" | "ky" | "kz" | "la" | "lb" | "lc" | "li" | "lk" | "ls" | "lt" | "lu" | "lv" | "ly" | "ma" | "mc" | "md" | "me" | "mg" | "mk" | "ml" | "mm" | "mn" | "mq" | "mr" | "ms" | "mt" | "mu" | "mv" | "mw" | "mx" | "my" | "mz" | "na" | "nc" | "ne" | "ng" | "ni" | "nl" | "no" | "np" | "nr" | "nu" | "nz" | "om" | "pa" | "pe" | "pf" | "pg" | "ph" | "pk" | "pl" | "pn" | "pr" | "ps" | "pt" | "py" | "qa" | "re" | "ro" | "rs" | "ru" | "rw" | "sa" | "sb" | "sc" | "se" | "sg" | "sh" | "si" | "sk" | "sl" | "sm" | "sn" | "so" | "sr" | "st" | "sv" | "td" | "tg" | "th" | "tj" | "tk" | "tl" | "tm" | "tn" | "to" | "tr" | "tt" | "tw" | "tz" | "ua" | "ug" | "us" | "uy" | "uz" | "vc" | "ve" | "vg" | "vi" | "vn" | "vu" | "ws" | "ye" | "yt" | "za" | "zm" | "zw")` *required*
>
> A two-letter country code (ISO 3166-1 alpha-2).
>
> **timeout** `integer`
>
> A manual timeout duration in seconds.
>
> **keywords** `string`
>
> A comma-separated list of keywords to show metrics for.
>
> **order\_by** `string`
>
> A column to order results by. See response schema for valid column identifiers.
>
> **search\_engine** `string ("google")`
>
> \[Deprecated on 5 Aug 2024].
>
> **keyword\_list\_id** `integer`
>
> The id of an existing keyword list to show metrics for.
>
> #### Output
>
> **data** `string` *required*
>
> Data from the action execution
>
> **error** `string`
>
> Error if any occurred during the execution of the action
>
> **successful** `boolean` *required*
>
> Whether or not the action execution was successful or not
