# Backlink Checker (`blueskyscraper/backlink-checker`) Actor

\[$7.20/1K on Bronze] Check backlinks of any domain or URL: linking page, anchor text, dofollow, domain rank, spam score, first and last seen, new and lost links. Also referring domains, anchor text profile and link gap (sites linking to competitors, not you). Errors free.

- **URL**: https://apify.com/blueskyscraper/backlink-checker.md
- **Developed by:** [BlueskyScraper](https://apify.com/blueskyscraper) (community)
- **Categories:** SEO tools, Lead generation
- **Stats:** 7 total users, 3 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $5.60 / 1,000 backlink rows

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

**Backlink Checker** returns the **backlinks of any domain, subdomain or page URL** as a flat table: one row per link with the **linking page URL**, **anchor text** and the text around it, **dofollow / nofollow**, the **domain rank and page rank** of the linking site (0–100), a **spam score**, **first seen and last seen dates**, and **new / lost / broken** flags. The same Actor also lists **referring domains**, the **anchor text profile**, and runs a **link gap analysis**: domains that link to your competitors but not to you.

The data comes from a licensed, continuously crawled backlink index read through its API — **no scraping of Ahrefs, Moz or Semrush**, so there is no login wall, no captcha and nothing that breaks when those sites change their pages. **$0.008 per row on the free plan, $0.0072 on Bronze and $0.0056 on Gold. Error rows are free, and there is no fee per run.**

### What is Backlink Checker?

It is a **backlinks API** and **Ahrefs alternative** for link builders, SEO agencies and anyone who needs a website's link profile in a spreadsheet or a pipeline. You enter a domain (`example.com`), a subdomain (`blog.example.com`) or a single page (`https://example.com/blog/post`), choose what you want back, and get rows you can sort, filter and export:

- 🔗 **Backlinks** — one row per link (or the best link of each linking domain), sorted strongest first.
- 🌍 **Referring domains** — one row per domain that links to the target, with its backlink count, dofollow/nofollow split and first-seen date.
- 🏷️ **Anchors** — one row per anchor text, with the number of linking domains and backlinks behind it and a computed **anchor type** (branded, URL, generic, keyword, empty).
- 🥊 **Link gap** — one row per domain that links to your competitors and **not** to you, flagged with which competitors it links to. These are your warmest outreach prospects.

What it is **not**: the ranks are **not** Moz Domain Authority or Ahrefs Domain Rating. They are a PageRank-style 0–100 score computed by the backlink index this Actor reads. They sort sites in a similar order (in our test run the strongest linking domains of `ahrefs.com` were `sites.google.com`, `iubenda.com` and `podcasts.apple.com` at 100), but the exact numbers differ from Moz or Ahrefs, as those also differ from each other.

### What data can Backlink Checker extract?

#### 🔗 Backlinks (mode `backlinks`, the default)

Real values from the default run on `ahrefs.com` (one link per referring domain, dofollow only):

| Field | Example | Meaning |
|---|---|---|
| `target` | `ahrefs.com` | The domain or page you checked |
| `urlFrom` | `https://www.adobe.com/express/learn/blog/target-audience` | Page that contains the link |
| `domainFrom` | `www.adobe.com` | Domain of the linking page |
| `urlTo` | `https://ahrefs.com/` | URL the link points to |
| `anchor` | `Ahrefs` | Anchor text (alt text for image links) |
| `anchorType` | `branded` | Computed: `branded`, `url`, `generic`, `keyword` or `empty` |
| `textPre` / `textPost` | `…tools you can use to check a competitor's website traffic, like` / `and Semrush…` | Text around the link |
| `dofollow` | `true` | `false` = nofollow |
| `linkType` | `anchor` | `anchor`, `image`, `redirect`, `canonical`, `alternate`, `meta` |
| `domainFromRank` | `79` | Domain rank of the linking site, 0–100 |
| `pageFromRank` | `33` | Page rank of the linking page, 0–100 |
| `linkRank` | `20` | Rank this link passes to the target, 0–100 |
| `spamScore` | `0` | Spam score of the link, 0–100 (higher = spammier) |
| `isNew` / `isLost` / `isBroken` | `false` / `false` / `false` | New on the last crawl / removed / points to a 4xx–5xx page |
| `firstSeen` / `lastSeen` | `2023-11-13T03:45:13.000Z` / `2026-09-01T22:03:58.000Z` | When the crawler first and last saw the link |
| `linksFromDomain` | `10` | All links from this domain to the target |
| `linksOnPage` | `1` | Identical links on the linking page |
| `pageFromTitle` | `How to identify your target audience in 5 steps` | Title of the linking page |
| `pageFromExternalLinks` | `7` | Outgoing links on the page (hundreds = link-farm signal) |
| `pageFromKeywordsTop10` | `179` | Google top-10 keywords of the linking page — a real-traffic signal |
| `domainFromCountry`, `domainFromIp`, `domainFromPlatform`, `pageFromLanguage` | `WW`, `23.76.204.156`, … | Where and on what platform the linking site runs |
| `semanticLocation` | `main` | HTML element the link sits in (`main`, `article`, `footer`, …) |
| `attributes` | `noopener` | `rel` attributes: nofollow, ugc, sponsored, … |
| `imageUrl`, `imageAlt`, `isIndirect`, `urlToStatusCode` | `null`, `null`, `false`, `200` | Image links, links through redirects, status of the linked page |

#### 🌍 Referring domains (mode `referring-domains`)

`domain`, `rankPassed` (rank the domain passes to the target, 0–100), `backlinks`, `dofollowBacklinks`, `nofollowBacklinks`, `referringPages`, `spamScore`, `brokenBacklinks`, `topLinkType`, `country`, `firstSeen`, `lostDate`, `isLost`.

#### 🏷️ Anchors (mode `anchors`)

`anchor`, `anchorType`, `referringDomains`, `referringMainDomains`, `backlinks`, `dofollowBacklinks`, `nofollowBacklinks`, `referringPages`, `rankPassed`, `spamScore`, `firstSeen`, `lostDate`, `isLost`. Sorted by the number of linking domains, so the first rows show what the anchor profile is made of — and whether it looks natural (mostly branded and URL anchors) or over-optimised (many exact-match keyword anchors).

#### 🥊 Link gap (mode `link-gap`)

Real values from a link gap of `scrapingbee.com` and `zenrows.com` against `apify.com`:

| Field | Example | Meaning |
|---|---|---|
| `domain` | `proxyplox.com` | Domain that links to competitors but not to your sites |
| `competitorsLinked` | `2` | How many competitors it links to |
| `linksToCompetitors` | `["scrapingbee.com","zenrows.com"]` | Which ones |
| `missingCompetitors` | `[]` | Competitors it does not link to (match = any) |
| `notLinkingTo` | `["apify.com"]` | Your sites it does not link to |
| `bestRankPassed` | `32` | Highest rank it passes to any competitor, 0–100 |
| `backlinksToCompetitors` | `286` | Its backlinks to all competitors combined |
| `dofollowBacklinksToCompetitors` | `286` | Dofollow part of them |
| `firstSeen` | `2026-07-15T…` | Earliest link to a competitor |
| `competitorDetails` | `[{competitor, backlinks, dofollowBacklinks, rankPassed, firstSeen, spamScore}]` | Per-competitor numbers |

### How much does it cost to check backlinks?

Backlink Checker uses **pay-per-event** pricing with one event, **`backlink`**: one charge per delivered row, in any mode — a backlink, a referring domain, an anchor or a link-gap domain. The free plan is 20% below the most-used backlink checker in Apify Store ($0.01 per backlink plus $0.015 per domain checked, Store price on 10 October 2026); paid plans are 28–44% below it.

| Apify plan | Price per row | 1,000 rows | Rows per $1 |
|---|---|---|---|
| Free | $0.008 | $8.00 | 125 |
| Bronze | $0.0072 | $7.20 | 138 |
| Silver | $0.0064 | $6.40 | 156 |
| Gold / Platinum / Diamond | $0.0056 | $5.60 | 178 |

- The default run (30 backlinks of one domain) costs **$0.24 on the free plan** and **$0.22 on Bronze**. Apify's free plan includes $5 of monthly credit.
- **Not charged:** invalid entries, targets the index has no links for, requests that fail, and anything over **Max rows**. These come back as free `type: "error"` rows that say why.
- **No fee per run.** Platform compute is tiny: a 30-row run uses well under a cent of compute, because the Actor sends one HTTP request per 1,000 rows and does no browsing.
- Set **Max rows per target** to cap a run, or set Apify's **maximum cost per run** — the Actor stops at that budget.

**Why 30 rows by default?** Each data request has a fixed cost on our side. Below roughly 30 rows per target that fixed part outweighs the row price on paid plans, so a built-in guard may stop very small multi-target runs early (with a free note that says so). One target with 30+ rows, or a few targets with 100 rows each, always runs in full.

### How to check backlinks with Backlink Checker

1. Open the Actor and click **Try for free** (or **Start**).
2. Pick **What to get**: Backlinks, Referring domains, Anchors or Link gap.
3. Enter one or more **Targets** — a domain like `example.com`, a subdomain, or a page URL.
4. For **Link gap**, put your own site in Targets and your competitors in **Competitors**.
5. Set **Max rows per target** and, if you like, the filters: dofollow only, minimum domain rank, only new in the last N days, live links only.
6. Click **Start**. A 30-row run finishes in seconds.
7. Download the table as **CSV, Excel, JSON or HTML**, or read it through the API.

### ⬇️ Input

The default input — the strongest dofollow link of each of the 30 strongest referring domains of `ahrefs.com`:

```json
{
  "mode": "backlinks",
  "targets": ["ahrefs.com"],
  "maxRows": 30,
  "grouping": "one_per_domain",
  "dofollowOnly": true
}
```

| Field | Default | What it does |
|---|---|---|
| `mode` | `backlinks` | `backlinks`, `referring-domains`, `anchors` or `link-gap` |
| `targets` | `["ahrefs.com"]` | Domains, subdomains or page URLs. In link gap: your own sites (up to 10) |
| `competitors` | — | Link gap only: competitor domains or URLs |
| `maxRows` | `30` | Rows per target (in link gap with match = any: per competitor), up to 10,000 |
| `grouping` | `one_per_domain` | Backlinks only: `one_per_domain`, `as_is` (every link) or `one_per_anchor` |
| `dofollowOnly` | `true` | Only dofollow links are returned or counted |
| `minDomainRank` | — | Only links from domains ranked at least this (0–100) |
| `onlyNewDays` | — | Only links first seen in the last N days |
| `excludeLost` | `true` | Only live links; switch off to include lost links |
| `linkGapMatch` | `any` | `any` = links to at least one competitor; `all` = links to every competitor |
| `sortBy` | `strongest` | `strongest` (rank) or `newest` (first seen) |
| `includeSubdomains` | `true` | Count links to every subdomain of a domain target |

#### Target formats

`example.com`, `www.example.com` and `https://example.com/` are all checked as the whole domain. `blog.example.com` is checked as that subdomain. `https://example.com/pricing` is checked as that exact page. Duplicates are checked once.

#### Link gap input

```json
{
  "mode": "link-gap",
  "targets": ["yoursite.com"],
  "competitors": ["competitor-one.com", "competitor-two.com", "competitor-three.com"],
  "linkGapMatch": "any",
  "maxRows": 100
}
```

With `any`, the Actor sends one data request per competitor (up to 10) and merges the results, so each donor domain gets flags for every competitor it links to; rows linking to the most competitors come first. With `all`, one request returns only the domains that link to every competitor (up to 20).

### ⬆️ Output

Each mode returns one row type, so every table view is clean. A backlink row from the default run:

```json
{
  "type": "backlink",
  "target": "ahrefs.com",
  "urlFrom": "https://www.adobe.com/express/learn/blog/target-audience",
  "domainFrom": "www.adobe.com",
  "urlTo": "https://ahrefs.com/",
  "anchor": "Ahrefs",
  "anchorType": "branded",
  "dofollow": true,
  "linkType": "anchor",
  "domainFromRank": 79,
  "pageFromRank": 33,
  "linkRank": 20,
  "spamScore": 0,
  "isNew": false,
  "isLost": false,
  "isBroken": false,
  "firstSeen": "2023-11-13T03:45:13.000Z",
  "lastSeen": "2026-09-01T22:03:58.000Z",
  "linksFromDomain": 10,
  "pageFromTitle": "How to identify your target audience in 5 steps",
  "pageFromKeywordsTop10": 179,
  "semanticLocation": "main",
  "urlToStatusCode": 200
}
```

The dataset has six views: **Backlinks**, **Backlinks in detail**, **Referring domains**, **Anchors**, **Link gap** and **Errors (free)**.

#### Error rows

```json
{ "type": "error", "target": null, "input": "not a domain", "error": "Target: \"not a domain\" is not a domain or URL (expected something like example.com). Not charged." }
```

An empty answer for a real site (brand-new domain, a page that redirects, or filters that are too strict) also comes back as a free error row explaining it, never as a silent empty run.

### Use cases for backlink data

#### Link building and outreach

Run **Link gap** with three to five competitors. Every row is a site that already links to businesses like yours, so it is likely to link to you too. Sort by `competitorsLinked` and `bestRankPassed`, drop rows with a high `spamScore`, and you have a prospect list.

#### Competitor backlink analysis

Check a competitor's **backlinks** with `sortBy: newest` and `onlyNewDays: 30` to see the links they won this month — the guest posts, round-ups and directories that are working right now in your niche.

#### Backlink audit and anchor text analysis

Run **Anchors** on your own domain. A natural profile is dominated by `branded` and `url` anchors; a high share of `keyword` anchors is an over-optimisation risk. Then run **Backlinks** with `excludeLost: false` to see lost and broken links worth reclaiming.

#### Monitoring

Schedule a weekly run with `onlyNewDays: 7` on your domain and send the new rows to Slack or a Google Sheet.

#### AI agents and SEO automation

Rows are flat, typed and consistent, so an agent can call the Actor with one target and read the table without post-processing.

### Integrations

- **Apify API**: start a run and read the dataset with `GET https://api.apify.com/v2/datasets/{datasetId}/items?format=csv`.
- **JavaScript / Python clients**: `apify-client` (npm, PyPI).
- **n8n, Make, Zapier, Google Sheets, Slack, Airbyte** via Apify's integrations.
- **MCP server**: AI assistants (Claude, ChatGPT, Cursor) can call this Actor as a tool through `https://mcp.apify.com`.
- **Webhooks** when a run finishes; **schedules** for weekly monitoring.

```python
from apify_client import ApifyClient
client = ApifyClient("<YOUR_APIFY_TOKEN>")
run = client.actor("lergassy/backlink-checker").call(run_input={
    "mode": "link-gap",
    "targets": ["yoursite.com"],
    "competitors": ["competitor-one.com", "competitor-two.com"],
    "maxRows": 100,
})
for row in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(row["domain"], row["competitorsLinked"], row["bestRankPassed"])
```

### 🤖 For AI Agents & LLM Apps

Compact reference for agents calling `lergassy/backlink-checker` through the Apify MCP server or API.

**Purpose:** backlinks, referring domains, anchor texts or link-gap prospects for a domain, subdomain or page URL, from a licensed backlink index.

**Minimal input:** `{"targets": ["example.com"]}` (backlinks, 30 rows). Link gap: `{"mode": "link-gap", "targets": ["mysite.com"], "competitors": ["rival.com"]}`.

**Output:** one row type per mode — `backlink`, `referring-domain`, `anchor` or `link-gap` — in the `type` column; errors are `type: "error"` with an `error` text.

**Behaviors an agent should know:**

- `maxRows` is per target (per competitor in link gap with match = any); default 30.
- Filters are applied by the data source, not after the fact: `dofollowOnly`, `minDomainRank`, `onlyNewDays`, `excludeLost`.
- Ranks are the index's own 0–100 scores, not Moz DA or Ahrefs DR.
- `competitorDetails` is the only nested field (array of objects); `linksToCompetitors`, `missingCompetitors`, `notLinkingTo` are string arrays.
- Billing: one `backlink` event per delivered row; error rows are free.

### ❓ FAQ

#### Is it legal to check backlinks?

Yes. Backlink data describes public links between public web pages, and this Actor reads it from a licensed data provider rather than scraping any SEO tool. How you use the results (for example cold outreach) is subject to the laws that apply to you, such as anti-spam and data protection rules — consult a lawyer if unsure.

#### Is this an Ahrefs alternative?

For the core backlink questions — who links to a site, with what anchor, how strong, since when, and who links to competitors but not to you — yes, without a monthly seat. It is not a copy of Ahrefs: the index and the rank scale are different, and the numbers will not match Ahrefs exactly.

#### How fresh is the data?

The index is crawled continuously; every row carries `lastSeen`, the date the crawler last saw the link. Results of identical requests are cached for up to 7 days (24 hours when "Only new in the last N days" is set), so repeating the same run the same week returns the same rows.

#### Why are some fields empty?

Not every link has every attribute: image links have no anchor text, redirects have no surrounding text, and the crawler does not detect a language or platform for every page. Empty values are `null`, never invented.

#### How many backlinks can I get?

Up to 10,000 rows per target per run (1,000 per data request, paged automatically). For very large sites, use `grouping: one_per_domain` and filters to get the links that matter.

#### Can I use Backlink Checker with the Apify API?

Yes — every run is an API call, and the dataset can be read as JSON, CSV, Excel or XML. See Integrations above.

#### Can I use it through an MCP server?

Yes. Add `https://mcp.apify.com` to your AI assistant and it can find and call `lergassy/backlink-checker` as a tool.

#### Can I integrate it with other apps?

Yes: n8n, Make, Zapier, Google Sheets, Slack, webhooks and schedules all work out of the box.

#### How much does a run cost?

$0.008 per row on the free plan, $0.0072 on Bronze, $0.0056 on Gold and above. The default 30-row run is $0.24 on the free plan. Errors and empty results are free.

### Your feedback

Found a bug, missing a field or need another mode? Open an issue on the **Issues** tab — we reply quickly. If the Actor saved you time, a short review helps other people find it.

### You might also like

| Actor | What it does |
|---|---|
| [Bulk Domain Authority Checker](https://apify.com/blueskyscraper/bulk-domain-authority-checker) | Domain rank 0–100, backlinks, referring domains and spam score for thousands of domains in one run — qualify the link-gap prospects you found here |
| [Competitor Keywords Finder](https://apify.com/blueskyscraper/competitor-keywords-finder) | Every keyword a competitor ranks for on Google, with position, volume and CPC |
| [Website Traffic Estimator](https://apify.com/blueskyscraper/website-traffic-estimator) | Organic and paid search traffic estimates for a list of domains |
| [Keyword Search Volume Checker](https://apify.com/blueskyscraper/keyword-search-volume-checker) | Monthly search volume, CPC and competition for thousands of keywords |

Also known as: backlinks checker, backlink analyzer, backlink API, link checker, referring domains checker, anchor text checker, link gap analysis, link intersect, backlink gap tool, free Ahrefs alternative, competitor backlinks.

# Actor input Schema

## `mode` (type: `string`):

Choose the table you need. <b>Backlinks</b>: one row per link with source URL, anchor, dofollow, domain rank and first/last seen. <b>Referring domains</b>: one row per domain linking to the target. <b>Anchors</b>: one row per anchor text. <b>Link gap</b>: one row per domain that links to your competitors but not to the sites in Targets.

## `targets` (type: `array`):

Enter one domain, subdomain or page URL per line. example.com and www.example.com are checked as the whole domain; https://example.com/blog/post is checked as that one page. In <b>Link gap</b> mode, enter your own site(s) here (up to 10): domains that already link to them are left out.

## `competitors` (type: `array`):

Link gap mode only: enter competitor domains or page URLs, one per line (up to 10 with match = any, up to 20 with match = all). The result lists domains linking to them, flagged with which competitors each one links to.

## `maxRows` (type: `integer`):

Set the most rows to return per target (up to 10,000). In link gap mode with match = any, the limit applies per competitor. Every row is billed, so start small; 30 or more rows per target keeps each data request efficient.

## `grouping` (type: `string`):

Backlinks mode only: choose how links are grouped. 'One link per referring domain' returns the strongest link of each linking domain and counts the rest in linksFromDomain.

## `dofollowOnly` (type: `boolean`):

Keep only dofollow links (the ones that pass ranking value). In referring domains, anchors and link gap mode, only dofollow links are counted. Switch off to include nofollow, ugc and sponsored links.

## `minDomainRank` (type: `integer`):

Keep only links from domains whose domain rank (0–100, the index's own PageRank-style score) is at least this number. Applies to links in every mode. Leave empty to keep all.

## `onlyNewDays` (type: `integer`):

Keep only links first seen in the last N days (for referring domains and anchors: domains or anchors first seen in that window). Leave empty for all dates.

## `excludeLost` (type: `boolean`):

Keep only links found on the last crawl. Switch off to also return lost links (removed links or pages), flagged with isLost / lostDate.

## `linkGapMatch` (type: `string`):

Link gap mode only. 'Any' finds every domain that links to at least one competitor and flags which ones. 'All' finds only the domains linking to every competitor — the warmest prospects.

## `sortBy` (type: `string`):

Choose which rows come first and are kept when Max rows cuts the list: the strongest links/domains (by rank; anchors by number of referring domains) or the most recently found.

## `includeSubdomains` (type: `boolean`):

Count links pointing to every subdomain of a domain target (blog., shop., …). Switch off to check only the exact host you entered. Ignored for page URLs.

## Actor input object example

```json
{
  "mode": "backlinks",
  "targets": [
    "ahrefs.com"
  ],
  "maxRows": 30,
  "grouping": "one_per_domain",
  "dofollowOnly": true,
  "excludeLost": true,
  "linkGapMatch": "any",
  "sortBy": "strongest",
  "includeSubdomains": true
}
```

# Actor output Schema

## `results` (type: `string`):

One row per backlink, referring domain, anchor text or link-gap domain, depending on the mode. Error rows (type = error) are free.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "mode": "backlinks",
    "targets": [
        "ahrefs.com"
    ],
    "maxRows": 30,
    "grouping": "one_per_domain"
};

// Run the Actor and wait for it to finish
const run = await client.actor("blueskyscraper/backlink-checker").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "mode": "backlinks",
    "targets": ["ahrefs.com"],
    "maxRows": 30,
    "grouping": "one_per_domain",
}

# Run the Actor and wait for it to finish
run = client.actor("blueskyscraper/backlink-checker").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "mode": "backlinks",
  "targets": [
    "ahrefs.com"
  ],
  "maxRows": 30,
  "grouping": "one_per_domain"
}' |
apify call blueskyscraper/backlink-checker --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,blueskyscraper/backlink-checker"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/EA30oplkQmr7ykYTd/builds/elNGvcI4mdxYf3DCv/openapi.json
