# Substack Scraper - Posts, Engagement & Category Leaderboards (`bigdatadan/substack-newsletters`) Actor

Scrape posts from any Substack with likes, comments, restacks, word count and free/paid flag, plus the top newsletters in any Substack category with subscriber tiers and paid status. No login.

- **URL**: https://apify.com/bigdatadan/substack-newsletters.md
- **Developed by:** [Alexander Meggitt](https://apify.com/bigdatadan) (community)
- **Categories:** Social media, Marketing, News
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.00 / 1,000 posts

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

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

## Substack Scraper: posts, engagement and category leaderboards

Two jobs in one actor:

1. **Posts from any Substack:** give newsletter URLs or subdomains (custom domains work) and get every post with **likes, comments, restacks, word count, free/paid**, authors, tags, section, preview text and cover image. Filter by date and free/paid.
2. **Category leaderboards:** pick Substack categories (Technology, Finance, Crypto, Politics… 32 in total) and get the ranked top newsletters with **subscriber tier (e.g. "1.1M+")**, paid-subscriber band ("Tens of thousands of paid subscribers"), bestseller tier, author, language, launch date and URL. Optionally pull each one's latest N posts.

Public JSON only: no login, no cookies, no proxies, and runs finish in 2–3 s for 35–60 rows.

### Use cases

Newsletter sponsorship and partnership prospecting, creator and competitor tracking, content research (what topics get the most likes and comments), media monitoring, and building datasets of top newsletters per niche.

### Input

| Field | Description |
|---|---|
| `publications` | URLs or subdomains, e.g. `https://blog.bytebytego.com`, `pragmaticengineer` |
| `maxPostsPerPublication` | Default 50 |
| `postedAfter` | YYYY-MM-DD |
| `audience` | all / free / paid |
| `categories` | Leaderboards to pull (select list) |
| `maxPublicationsPerCategory` | Default 50 |
| `postsFromCategoryPublications` | Latest N posts per leaderboard newsletter (0 = none) |
| `maxResults` | Hard cap across the whole run |

### Output (real rows from test runs on Oct 31, 2026)

Post:

```json
{
  "record_type": "post",
  "publication_url": "https://blog.bytebytego.com",
  "publication_name": "ByteByteGo Newsletter",
  "post_id": 222752055,
  "title": "EP231: AI Terms You Need to Know",
  "subtitle": "What else should be on the list?",
  "url": "https://blog.bytebytego.com/p/ep231-ai-terms-you-need-to-know",
  "post_date": "2026-10-31T15:31:08.160Z",
  "type": "newsletter",
  "audience": "free",
  "authors": [
    "ByteByteGo"
  ],
  "likes": 185,
  "comments": 3,
  "restacks": 4,
  "wordcount": 1084,
  "section": null,
  "tags": [],
  "podcast_duration_sec": null,
  "preview_text": "The all-in-one intelligent cloud (Sponsored)",
  "scraped_at": "2026-11-01T06:02:24.783437+00:00"
}
```

Publication:

```json
{
  "record_type": "publication",
  "category": "Top in Technology",
  "category_rank": 2,
  "publication_name": "The Pragmatic Engineer",
  "url": "https://newsletter.pragmaticengineer.com",
  "subdomain": "pragmaticengineer",
  "author_name": "Gergely Orosz",
  "description": "Big Tech and startups, from the inside. Highly relevant for software engineers, AI engineers and engineering leaders, useful for those working in tech.",
  "language": "en",
  "subscribers_tier": "1.1M+",
  "subscribers_min": 1000000,
  "ranking_detail": "Tens of thousands of paid subscribers",
  "bestseller_tier": 10000,
  "paid_enabled": true,
  "first_post_date": "2021-08-30T11:24:02.082Z",
  "scraped_at": "2026-11-01T06:02:42.372648+00:00"
}
```

### Pricing (suggested)

Pay per event: **`post` at $0.001 ($1.00/1K)** and **`publication` at $0.003 ($3.00/1K)** (leaderboard rows are richer and rarer). No start fee.
Benchmarks in Apify Store on Oct 31, 2026: the leading Substack actor charges about $1.15/1K posts plus $5/1K run starts (175 monthly users, no reviews yet), others charge $15/1K entities, and one is rated 2.6★. Matching on post price and leading on leaderboards and engagement fields is the angle.

### Notes

Only publicly listed metadata and preview text are collected. Full paywalled content is never accessed.

# Actor input Schema

## `publications` (type: `array`):

Newsletter URLs or subdomains, e.g. https://www.lennysnewsletter.com, pragmaticengineer, https://blog.bytebytego.com. Returns their posts.

## `categories` (type: `array`):

Returns the top newsletters listed in each Substack category, with subscriber tier and paid status.

## `maxPublicationsPerCategory` (type: `integer`):

How many top newsletters to return from each category leaderboard.

## `postsFromCategoryPublications` (type: `integer`):

For each newsletter found in a category, also fetch this many of its latest posts. 0 = newsletters only.

## `maxPostsPerPublication` (type: `integer`):

Latest posts to fetch from each publication in the list above.

## `postedAfter` (type: `string`):

Only posts published on or after this date (YYYY-MM-DD).

## `audience` (type: `string`):

Filter posts by free or paid (paywalled) audience.

## `maxResults` (type: `integer`):

Hard cap on rows across the whole run (you are charged per row).

## Actor input object example

```json
{
  "publications": [
    "https://blog.bytebytego.com"
  ],
  "maxPublicationsPerCategory": 50,
  "postsFromCategoryPublications": 0,
  "maxPostsPerPublication": 50,
  "audience": "all",
  "maxResults": 500
}
```

# Actor output Schema

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

Post rows (likes, comments, restacks, word count, audience) and/or publication leaderboard rows (rank, subscriber tier, paid status).

# 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 = {
    "publications": [
        "https://blog.bytebytego.com"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("bigdatadan/substack-newsletters").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 = { "publications": ["https://blog.bytebytego.com"] }

# Run the Actor and wait for it to finish
run = client.actor("bigdatadan/substack-newsletters").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 '{
  "publications": [
    "https://blog.bytebytego.com"
  ]
}' |
apify call bigdatadan/substack-newsletters --silent --output-dataset

```

## MCP server setup

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

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/J7u6zWVTT50Ly5Ws5/builds/iQaqfGDsDd19kK3l1/openapi.json
