# Link Preview Scraper — TikTok, X, Instagram, Pinterest & More (`fetchwise/link-preview-scraper`) Actor

Get title, description, image, favicon and site name for any URL, with dedicated extractors for TikTok, X, Instagram, Threads, Pinterest, Facebook, Reddit, Etsy and YouTube. You only pay for previews that worked.

- **URL**: https://apify.com/fetchwise/link-preview-scraper.md
- **Developed by:** [kelvin lab](https://apify.com/fetchwise) (community)
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.20 / 1,000 preview extracteds

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

## Link Preview Scraper — TikTok, X, Instagram, Pinterest & more

Turn any list of URLs into link previews: **title, description, image, favicon and site name**, the same card a chat app shows when you paste a link. It works as a bulk Open Graph scraper and URL metadata extractor for any website, and it also reads the social links that generic scrapers get wrong.

Most Open Graph scrapers fail on social links. They get a login wall, an empty app shell or a generic "TikTok – Make Your Day". This Actor has **dedicated extractors for TikTok, X (Twitter), Instagram, Threads, Pinterest, Facebook, Reddit, Etsy and YouTube**, plus Wikipedia. It **only charges for previews that worked**.

### Why use this link preview scraper

- **Real previews for social links.** Each platform has its own extractor. For example, you get the TikTok caption and cover, the text of an X post, the real Pinterest pin title instead of a keyword list, and the Reddit post title instead of "From the r/... community".
- **Pay only for results.** Failed URLs, login walls, bot-challenge pages, title-only results, invalid URLs and duplicates are free. Each row says if it was charged and why not.
- **Fast and light.** No browser. 100 mixed URLs take about 15–25 seconds on the default 1 GB of memory.
- **Clear quality flags.** Every row has `quality` (full, partial, weak or fallback) and an `error` message when something went wrong, so you can filter before you show a card.

### What you can use it for

- Show rich link cards (link unfurling) in your app, CMS, newsletter or chat bot.
- Enrich a spreadsheet of links (bookmarks, social mentions, product links) with titles, descriptions and images.
- Get the og:image, og:title and og:description of many pages at once.
- Check which pages expose usable Open Graph and Twitter Card tags.

### Supported platforms

| Platform | What you get | Notes |
|---|---|---|
| Any website | Open Graph, Twitter Card, JSON-LD and HTML tags | Retried as the link-preview bots of Google, Facebook and LinkedIn when a site blocks normal browsers. App shells that show homepage tags on every page are detected and not charged. |
| YouTube | Videos, Shorts, playlists (including Mix/Radio) and channels | Official oEmbed |
| TikTok | Videos, photo posts and `vm.tiktok.com` short links: caption, cover image, author | Profiles return the creator name; the avatar is not always available. |
| X / Twitter | Posts (also long-form articles) with author and media image; profiles with name, bio and avatar | |
| Instagram | Profiles (name, avatar, follower counts), posts and reels with the caption kept intact | Instagram refuses many data-center IP addresses. A refused page is retried through up to six new Apify Proxy sessions, each from another IP, at no extra cost to you. Rows that still fail are free and say so in `error`. |
| Threads | Posts and profiles | Retried like Instagram when refused. Posts that are hidden from logged-out visitors are flagged `restricted` and not charged. |
| Pinterest | Pins and `pin.it` short links, with the real pin title; boards and profiles | |
| Facebook | Public pages, posts, videos and share links | Facebook often redirects data-center IP addresses to its login page. Results vary from run to run; failed rows are free. |
| Reddit | Posts and subreddits | |
| Etsy | Listings, shops, categories and `etsy.me` short links | Etsy sometimes shows a bot-challenge page; those rows are free. |
| Wikipedia | Articles in any language: lead paragraph and lead image | Wikipedia pages have no meta description; this Actor reads the article summary. |

### Input

| Field | Description |
|---|---|
| `urls` | The pages to preview. A bare domain like `github.com` gets `https://`. Duplicates are fetched and charged once. |
| `maxUrls` | Stop after this many unique URLs (default 1,000, maximum 10,000). |
| `maxConcurrency` | URLs fetched at the same time (default 5, maximum 20). |
| `timeoutSecs` | Time limit per URL (default 15 s, 5–30 s). A URL that times out is not charged. |
| `proxyConfiguration` | Optional Apify datacenter proxy or your own proxy URLs, used for every request. Residential proxy is not supported. Without it, only Instagram and Threads pages that refuse the run's IP go through Apify datacenter proxy. |
| `linkPreviewApiKey` | Optional key for [linkpreview.net](https://www.linkpreview.net), used as a last resort when a site blocks every direct request. LinkPreview bills its usage to your key. |

```json
{
    "urls": [
        "https://github.com/apify/crawlee",
        "https://www.youtube.com/watch?v=dQw4w9WgXcQ",
        "https://x.com/jack/status/20",
        "https://www.tiktok.com/@scout2015/video/6718335390845095173",
        "https://www.pinterest.com/pin/99360735500167749/",
        "https://en.wikipedia.org/wiki/Open_Graph_protocol"
    ]
}
```

### Output

One row per unique URL:

```json
{
    "inputUrl": "https://www.youtube.com/watch?v=dQw4w9WgXcQ",
    "url": "https://www.youtube.com/watch?v=dQw4w9WgXcQ",
    "title": "Rick Astley - Never Gonna Give You Up (Official Video) (4K Remaster)",
    "description": "By Rick Astley",
    "image": "https://i.ytimg.com/vi/dQw4w9WgXcQ/hqdefault.jpg",
    "favicon": "https://www.youtube.com/favicon.ico",
    "siteName": "YouTube",
    "platform": "youtube",
    "source": "youtube-oembed",
    "quality": "full",
    "billable": true,
    "notChargedReason": null,
    "error": null,
    "fetchedAt": "2026-10-19T13:32:47.915Z"
}
```

- `platform`: `web`, `youtube`, `tiktok`, `x`, `reddit`, `facebook`, `instagram`, `threads`, `whatsapp`, `pinterest` or `etsy`. Wikipedia articles are `web`.
- `source`: which extractor produced the row, for example `open-graph-scraper`, `tiktok-embed`, `fxtwitter` or `wikipedia-summary`.
- `quality`: `full` (image and description), `partial` (one of them), `weak` (title only) or `fallback` (nothing usable).
- `billable`: whether the row was charged. `notChargedReason` says why not: `fallback`, `restricted`, `challenge-page`, `title-only`, `site-shell`, `redirected-to-homepage` or `invalid-url`.
- `error`: why no preview could be extracted, e.g. `403 Forbidden` or `Instagram returned a login page (IP blocked)`.
- Image URLs from TikTok and Instagram are signed by their CDN and **expire** after some hours or days. Download them soon if you need to keep them.

You can download the dataset as JSON, CSV, Excel or HTML, or read it through the Apify API. The run's key-value store also has a `SUMMARY` record with counts per platform.

### Pricing

Pay per event. You pay only for previews with `billable: true`, plus Apify's standard start fee.

| Event | Free and Starter plans | Scale plan | Business plan |
|---|---|---|---|
| Preview extracted (rows with `billable: true`) | $0.002 ($2.00 per 1,000) | $0.0016 ($1.60 per 1,000) | $0.0012 ($1.20 per 1,000) |
| Actor start | $0.00005 per run | $0.00005 per run | $0.00005 per run |

The start fee is charged once per GB of memory, so a run at the default 1 GB pays it once. Failed URLs, login walls, bot-challenge pages, title-only results, invalid URLs and duplicates are free.

To cap your spending, set a maximum cost per run in the run options. The Actor stops cleanly when the cap is reached, and it never charges for a row you cannot see in the dataset.

### Memory and speed

- Default memory is 1 GB, which is the best value. 512 MB also works, but a run takes about twice as long; 2 GB is the maximum.
- `maxConcurrency` sets how many URLs are fetched in parallel. The default of 5 handles 100 URLs in about 15–25 seconds.
- Runs that migrate to another server continue where they stopped. No URL is charged twice.

### Limits

- Only public pages: private, logged-in or age-gated content is not available.
- Pages are fetched without a browser. A page that builds all of its tags with JavaScript can return a free `fallback` row.
- Local network and cloud metadata addresses are always blocked.
- Only the first 5 MB of a page is read. Preview tags are near the top, so very large pages still work.
- Platforms change their pages without notice. A temporary drop in success rate is fixed in the Actor, not in your input.

### FAQ

**How is this different from an Open Graph scraper?**
For normal websites it reads the same Open Graph and Twitter Card tags. For social platforms, those tags are often missing, generic or behind a login, so this Actor uses each platform's own public endpoints instead.

**Do I pay for URLs that fail?**
No. Only rows with `billable: true` are charged. The row still appears in the dataset with `error` and `notChargedReason`, so you know what happened.

**Why did an Instagram profile or a Facebook page fail?**
Both sites often block data-center IP addresses. Instagram pages are already retried through new proxy IPs; if all of them are refused, the row is free. You can run the failed URLs again later or pass your own proxy in `proxyConfiguration`.

**Can I call it from my app?**
Yes. Use the Apify API or one of the Apify clients to start a run with a list of URLs, then read the dataset. For one or a few URLs, the "run synchronously and get dataset items" endpoint returns the previews in a single request.

# Actor input Schema

## `urls` (type: `array`):

Pages to preview. Any public http(s) URL works; a bare domain such as github.com gets https://. Duplicates are fetched and charged once.

## `maxUrls` (type: `integer`):

Stop after this many unique URLs. Protects you from an oversized list.

## `maxConcurrency` (type: `integer`):

How many URLs are fetched at the same time.

## `timeoutSecs` (type: `integer`):

A URL that takes longer returns a row with an error and is not charged.

## `proxyConfiguration` (type: `object`):

Optional. Apify datacenter proxy or your own proxy URLs, used for every request. Residential proxy is not supported. Without it, only Instagram and Threads pages that refuse the run's IP are retried through Apify datacenter proxy.

## `linkPreviewApiKey` (type: `string`):

Optional. Your own linkpreview.net key, used as a last resort when a site blocks direct requests. Usage is billed by LinkPreview to your key.

## Actor input object example

```json
{
  "urls": [
    "https://github.com/apify/crawlee",
    "https://www.youtube.com/watch?v=dQw4w9WgXcQ",
    "https://x.com/jack/status/20",
    "https://www.tiktok.com/@scout2015/video/6718335390845095173",
    "https://www.pinterest.com/pin/99360735500167749/",
    "https://en.wikipedia.org/wiki/Open_Graph_protocol"
  ],
  "maxUrls": 1000,
  "maxConcurrency": 5,
  "timeoutSecs": 15,
  "proxyConfiguration": {
    "useApifyProxy": false
  }
}
```

# Actor output Schema

## `previews` (type: `string`):

One row per unique URL: title, description, image, favicon, site name, and whether the row was charged.

## `summary` (type: `string`):

Counts of charged previews, free rows and failures per platform.

# 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 = {
    "urls": [
        "https://github.com/apify/crawlee",
        "https://www.youtube.com/watch?v=dQw4w9WgXcQ",
        "https://x.com/jack/status/20",
        "https://www.tiktok.com/@scout2015/video/6718335390845095173",
        "https://www.pinterest.com/pin/99360735500167749/",
        "https://en.wikipedia.org/wiki/Open_Graph_protocol"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("fetchwise/link-preview-scraper").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 = { "urls": [
        "https://github.com/apify/crawlee",
        "https://www.youtube.com/watch?v=dQw4w9WgXcQ",
        "https://x.com/jack/status/20",
        "https://www.tiktok.com/@scout2015/video/6718335390845095173",
        "https://www.pinterest.com/pin/99360735500167749/",
        "https://en.wikipedia.org/wiki/Open_Graph_protocol",
    ] }

# Run the Actor and wait for it to finish
run = client.actor("fetchwise/link-preview-scraper").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 '{
  "urls": [
    "https://github.com/apify/crawlee",
    "https://www.youtube.com/watch?v=dQw4w9WgXcQ",
    "https://x.com/jack/status/20",
    "https://www.tiktok.com/@scout2015/video/6718335390845095173",
    "https://www.pinterest.com/pin/99360735500167749/",
    "https://en.wikipedia.org/wiki/Open_Graph_protocol"
  ]
}' |
apify call fetchwise/link-preview-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,fetchwise/link-preview-scraper"
        }
    }
}
```

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/qSvCR4jIc4axkwcab/builds/riRh4a6OGwWVOBj2R/openapi.json
