# Reddit Subreddit Scraper (`piotrv1001/reddit-subreddit-scraper`) Actor

Scrape the posts of any subreddit: title, text, author, score, upvote ratio, comment count, date, flair, link, images and video. Sort by hot, new, top, rising or controversial, up to about 1,000 posts per list, with optional comments. For Reddit monitoring, trends and research. No login.

- **URL**: https://apify.com/piotrv1001/reddit-subreddit-scraper.md
- **Developed by:** [FalconScrape](https://apify.com/piotrv1001) (community)
- **Categories:** Social media, Lead generation
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 1 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.50 / 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

### 🚀 Reddit Subreddit Scraper

Export the **posts of any subreddit**. The **Reddit Subreddit Scraper** saves each post's title, text, author, score, upvote ratio, comment count, date, flair, link, images and video, sorted by hot, new, top, rising or controversial. Turn on **comments** to get each post's discussion too. Use it for **Reddit monitoring**, **trend tracking**, **market research**, **subreddit analysis**, **lead generation** and sentiment analysis. No Reddit account, no API key.

### ✨ Features

- 📰 **Many subreddits per run**: names, `r/` names or links, each with its own limit.
- 🔀 **Sort and time range**: Hot, New, Top, Rising or Controversial; Top and Controversial by past hour, day, week, month, year or all time.
- 📈 **Up to ~1,000 posts per subreddit**: the Actor follows Reddit's own pages to the end of the list.
- 💬 **Comments (optional)**: each post followed by its comments, with depth and parent for the reply tree.
- 🖼️ **Media**: images, video link, outbound link and domain.
- 🧹 **No duplicates**: pinned posts and overlapping inputs are saved and charged once.

### 🛠️ How It Works

1. **Enter subreddits**, one per line.
2. **Pick a sort order** (and a time range for Top), and **Max posts per subreddit**.
3. **Run the Scraper** and download the posts as JSON, CSV or Excel, or pull them through the API.

### ⚙️ Input

| Field                                      | What it does                                                                        |
| ------------------------------------------ | ----------------------------------------------------------------------------------- |
| **Subreddits**                             | `technology`, `r/technology` or `https://www.reddit.com/r/technology/`, one per line. Default `technology`. |
| **Sort by**                                | Hot (default), New, Top, Rising or Controversial.                                   |
| **Time range (Top and Controversial)**     | Past hour, 24 hours (default), week, month, year or all time.                       |
| **Max posts per subreddit**                | Stop after this many posts for each subreddit. Default 50.                          |
| **Include comments**                       | Also save each post's comments. Default off.                          |
| **Max comments per post**                  | With comments on: limit per post. Default 20.                                       |
| **Proxy configuration**                    | Residential proxies are needed. The default works.                                  |

```json
{
    "subreddits": ["SaaS", "startups"],
    "sort": "top",
    "time": "week",
    "maxItems": 200,
    "includeComments": true,
    "maxCommentsPerPost": 30
}
```

#### How many posts can I get?

Reddit lists about **1,000 posts per subreddit and sort order** (a test on r/technology "Hot" returned exactly 1,000 unique posts). To go further back, run the same subreddit with other sorts (Top by year and all time, Controversial, New). "Rising" is short by nature: Reddit shows visitors who are not logged in only about 25 rising posts. When a subreddit runs out before your limit, or the 1,000 limit is reached, the status message says so.

With comments on, each post also gets up to "Max comments per post" comments. Reddit first shows about 25 comments per post and loads the rest in batches; a full 2,000-comment thread gives about two-thirds of its counted comments (removed comments and replies below depth 5 are not shown to visitors who are not logged in). For whole threads, use Reddit Comments Scraper.

### 💰 Pricing

Pay only for what you get. No monthly rental.

| Event           | Price                                    | What you get                                          |
| --------------- | ---------------------------------------- | ----------------------------------------------------- |
| **Post**        | $0.0015 per post ($1.50 per 1,000)       | One post with all fields below                        |
| **Comment**     | $0.0008 per comment ($0.80 per 1,000)    | Only with "Include comments" on                       |
| **Actor start** | $0.00005 per run                         | Charged once when the run starts.                     |

Examples: 1,000 posts = $1.50 · 100 posts with 20 comments each = $0.15 + $1.60 = $1.75. Deleted comments without text are not charged.

### 📊 Sample Output Data

Post:

```json
{
    "type": "post",
    "id": "1xb7op7",
    "url": "https://www.reddit.com/r/technology/comments/1xb7op7/anthropic_logged_net_loss_of_over_80_billion_in/",
    "title": "Anthropic logged net loss of over $80 billion in first half of 2026",
    "body": "",
    "author": "CarciaNerissa",
    "authorId": "t2_2el3ygu6p5",
    "subreddit": "technology",
    "subredditId": "t5_2qh16",
    "score": 21514,
    "upvoteRatio": 0.96,
    "numComments": 2064,
    "awards": 2,
    "createdAt": "2026-10-20T23:36:46.002Z",
    "flair": "Artificial Intelligence",
    "postType": "link",
    "language": "en",
    "isNsfw": false,
    "isSpoiler": false,
    "isPinned": false,
    "isArchived": false,
    "isCrosspost": false,
    "domain": "reuters.com",
    "linkUrl": "https://www.reuters.com/business/anthropic-recorded-net-loss-over-80-billion-first-half-this-year-wsj-reports-2026-10-20/",
    "thumbnail": null,
    "images": [],
    "videoUrl": null,
    "feedSort": "hot",
    "feedTime": null,
    "scrapedAt": "2026-10-21T10:29:36.224Z"
}
```

Comment (with "Include comments" on):

```json
{
    "type": "comment",
    "id": "phyihgq",
    "postId": "1xb7op7",
    "postTitle": "Anthropic logged net loss of over $80 billion in first half of 2026",
    "subreddit": "technology",
    "parentId": "t3_1xb7op7",
    "depth": 0,
    "author": "wembenbama",
    "body": "I mean this is actually insane.",
    "score": 9290,
    "awards": 6,
    "createdAt": "2026-10-20T23:43:08.013Z",
    "url": "https://www.reddit.com/r/technology/comments/1xb7op7/comment/phyihgq/",
    "isSubmitter": false,
    "scrapedAt": "2026-10-21T10:41:02.120Z"
}
```

### ❓ FAQ

**Do I need a Reddit account or API key?** No. This is a Reddit API alternative for public subreddits.

**What are `feedSort` and `feedTime`?** The sort order and time range of the list the post came from, handy when one run scrapes a subreddit in several orders.

**Why is `body` empty for some posts?** Link, image and video posts often have no text; `linkUrl`, `images` and `videoUrl` hold the content.

**Can I scrape private, banned or 18+ subreddits?** No. Private and banned communities are reported in the status message; 18+ communities need a login.

**Can I track a subreddit every day?** Yes. Schedule the Actor with sort "New"; each run returns the newest posts.

**How do I find posts about a keyword?** Use Reddit Search Scraper. For all comments of specific posts, use Reddit Comments Scraper.

# Actor input Schema

## `subreddits` (type: `array`):

Communities to scrape, one per line: a name (technology), r/technology or a link (https://www.reddit.com/r/technology/).

## `sort` (type: `string`):

Order of the subreddit's posts, as on Reddit.

## `time` (type: `string`):

Period for Top and Controversial sorting. Ignored for Hot, New and Rising.

## `maxItems` (type: `integer`):

Stop after this many posts for each subreddit. Reddit lists about 1,000 posts per subreddit and sort order.

## `includeComments` (type: `boolean`):

Also save the comments of each post (charged per comment).

## `maxCommentsPerPost` (type: `integer`):

With "Include comments" on: stop after this many comments for each post.

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

Residential proxies are needed for reliable results. The default works.

## Actor input object example

```json
{
  "subreddits": [
    "technology",
    "https://www.reddit.com/r/SaaS/"
  ],
  "sort": "hot",
  "time": "day",
  "maxItems": 50,
  "includeComments": false,
  "maxCommentsPerPost": 20,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}
```

# Actor output Schema

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

No description

# 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 = {
    "subreddits": [
        "technology"
    ],
    "maxItems": 50,
    "proxyConfiguration": {
        "useApifyProxy": true,
        "apifyProxyGroups": [
            "RESIDENTIAL"
        ]
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("piotrv1001/reddit-subreddit-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 = {
    "subreddits": ["technology"],
    "maxItems": 50,
    "proxyConfiguration": {
        "useApifyProxy": True,
        "apifyProxyGroups": ["RESIDENTIAL"],
    },
}

# Run the Actor and wait for it to finish
run = client.actor("piotrv1001/reddit-subreddit-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 '{
  "subreddits": [
    "technology"
  ],
  "maxItems": 50,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}' |
apify call piotrv1001/reddit-subreddit-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,piotrv1001/reddit-subreddit-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/6kVPfTLAohDrYOnPm/builds/GJtKaynX9XwExeO3W/openapi.json
