# Reddit Comment Scraper (`scraptivo/reddit-comment-scraper`) Actor

Collects public comments from Reddit post IDs or URLs. Returns comment text, author, score, reply depth, and post metadata.

- **URL**: https://apify.com/scraptivo/reddit-comment-scraper.md
- **Developed by:** [Scraptivo](https://apify.com/scraptivo) (community)
- **Categories:**
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.70 / 1,000 comments

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?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
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.
Actors are written with capital "A".

## 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.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

**Reddit Comment Scraper** collects public comments from [Reddit](https://www.reddit.com) posts and turns them into structured data for sentiment analysis, market research, and content monitoring. Provide post IDs or URLs, run the Actor, and export comment text, author, score, reply depth, and post metadata to JSON, CSV, Excel, or your preferred integration. Use it to analyze community sentiment, monitor brand mentions, and build comment datasets — no Reddit account required. Pricing starts at **$3.00 per 1,000 comments**, with post metadata included at no extra charge.

### What can you automate with Reddit Comment Scraper?

- **Collect full comment threads** — pull public comments and nested replies from any Reddit post, with `parentId` and `depth` preserved so you can rebuild the conversation.
- **Analyze sentiment and product feedback** — export comment text, scores, and timestamps to see what communities praise or criticize.
- **Monitor brand and topic mentions** — schedule recurring runs on the same posts and watch how discussions evolve.
- **Build research and training datasets** — gather structured comment corpora for analytics, journalism, or model work.
- **Sort and cap each thread** — choose Best, Top, New, Controversial, Old, Q\&A, or Live, and limit comments per post.
- **Feed downstream workflows** — send results to Google Sheets, a webhook, or your own API pipeline after each run.

### Who is this scraper for?

| Team | Workflow |
|---|---|
| Market researchers | Collect real opinions about products, brands, and topics from public Reddit threads. |
| Brand and reputation teams | Monitor mention threads and high-score replies without watching Reddit all day. |
| Content and social teams | Study which comments resonate and how original posters respond. |
| Data and research teams | Build structured comment datasets for sentiment analysis or model training. |

### What data can you collect from Reddit?

| Data group | Example fields | How it helps |
|---|---|---|
| Comment content | `body`, `id`, `name`, `createdAt`, `editedAt` | Read the text and order comments in time. |
| Author and role | `author`, `isSubmitter`, `distinguished` | See who wrote it and whether they are the original poster or a moderator. |
| Thread structure | `parentId`, `depth`, `postId` | Rebuild reply trees and keep comments attached to the right post. |
| Engagement | `score`, `ups`, `gilded`, `controversiality` | Rank comments by traction and controversy. |
| Post context | `postTitle`, `postUrl`, `subreddit`, `subredditNamePrefixed` | Know which community and thread each comment came from — included at no extra charge. |
| Links and state | `permalink`, `fullUrl`, `stickied`, `locked`, `archived`, `collapsed` | Open the comment on Reddit and filter locked or archived threads. |

Fields such as `editedAt`, `distinguished`, and `gilded` are only populated when Reddit provides a value. The Actor collects publicly visible comments only.

### How to use Reddit Comment Scraper

1. Open the [Reddit Comment Scraper](https://apify.com/scraptivo/reddit-comment-scraper) on Apify.
2. Enter Reddit post IDs or URLs in `searchQueries` — for example `1vcvjb9` or `https://www.reddit.com/r/AI_Agents/comments/1vcvjb9/`.
3. Set `maxComments` per post (prefill `100`; `0` means unlimited) and choose a `sortBy` order.
4. Run the Actor — it collects public comments from each post you provided.
5. Export the dataset or connect it to your workflow.

```json
{
    "searchQueries": [
        "1vcvjb9"
    ],
    "maxComments": 100,
    "sortBy": "confidence",
    "proxyConfiguration": {
        "useApifyProxy": true,
        "apifyProxyGroups": ["RESIDENTIAL"]
    }
}
```

### Example workflow

#### Monitor sentiment on a product-launch thread

1. Paste the launch-post URL or ID into `searchQueries` and set `sortBy` to `top` so high-score comments come first.
2. Keep `maxComments` at `100` for a weekly snapshot, or `0` when you need the full thread.
3. After each run, send new records to Google Sheets or a Slack channel through a webhook.
4. Deduplicate user-side against the stable comment `id` so you only review comments that appeared since the last run.

The Actor does not filter, score sentiment, or merge runs for you — those steps happen in your own workflow.

### Automate and integrate your results

- **Schedules** — Reddit threads grow quickly. Run **hourly or daily** on fast-moving posts, and **weekly** on evergreen discussions. Create a separate scheduled task per post or campaign so each job keeps its own `searchQueries` and dataset.
- **Webhooks** — Enable a webhook on run completion to push fresh comments into Google Sheets, Slack, a CRM, or a database.
- **Exports and API** — Download results as JSON, CSV, Excel, or HTML from the Apify Console, or call the Actor from the API. One cURL example:

```shell
curl "https://api.apify.com/v2/acts/scraptivo~reddit-comment-scraper/runs?token=YOUR-APIFY-TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "searchQueries": ["1vcvjb9"],
    "maxComments": 100,
    "sortBy": "confidence",
    "proxyConfiguration": {
      "useApifyProxy": true,
      "apifyProxyGroups": ["RESIDENTIAL"]
    }
  }'
```

- **Deduplication** — Within a single run, the same post supplied in `searchQueries`, `postIds`, and `startUrls` is collected once. Across runs, the Actor appends every comment again. Use `id` as the stable key when merging results.

### Input reference

| Field | Type | Required | Default | What it controls |
|---|---|---:|---|---|
| `searchQueries` | Array of strings | No\* | — | Reddit post IDs or post URLs (e.g. `1vcvjb9` or `https://www.reddit.com/r/AI_Agents/comments/1vcvjb9/`). Preferred input — both formats are resolved automatically. |
| `postIds` | Array of strings | No\* | — | Bare Reddit post IDs only (e.g. `1vcvjb9`). Post URLs are built automatically. |
| `startUrls` | Array of URLs | No\* | — | Full Reddit post URLs, including `redd.it` short links. |
| `maxComments` | Integer | No | `0` | Maximum comments **per post** (`0` = unlimited). Prefill is `100`. Three posts with `maxComments: 10` return up to 30 comments. |
| `maxItems` | Integer | No | `0` | Alias for `maxComments` (per post). Used only when `maxComments` is omitted. |
| `sortBy` | String | No | `confidence` | Comment order: `confidence` (Best), `top`, `new`, `controversial`, `old`, `qa`, `live`. |
| `proxyConfiguration` | Proxy object | No | Apify proxy, RESIDENTIAL | Proxy settings. Residential proxies are recommended because datacenter IPs are often blocked. |

\* Provide at least one of `searchQueries`, `postIds`, or `startUrls`. You can combine them; duplicate post IDs are ignored within the run.

#### What is the difference between searchQueries, postIds, and startUrls?

All three point at the same thing: a Reddit post. `searchQueries` accepts both bare IDs and full URLs. `postIds` accepts IDs only. `startUrls` accepts full URLs, including `https://redd.it/1vcvjb9`. Use whichever format you already have.

#### How do maxComments and maxItems work?

`maxComments` is a **per-post** cap, not a global run total. `0` means unlimited comments on each post. `maxItems` is an alias for agent compatibility and is applied only when `maxComments` is omitted from the input.

### Output example

Each dataset item is one comment. Post title, URL, and subreddit are included on every record at no extra charge:

```json
{
    "id": "l8c2m3",
    "name": "t1_l8c2m3",
    "author": "reddit_user_123",
    "body": "This is a really underrated workflow. I've been using agents like this for weeks and the difference is night and day.",
    "score": 214,
    "ups": 214,
    "depth": 0,
    "parentId": "t3_1vcvjb9",
    "postId": "1vcvjb9",
    "postTitle": "I think people seriously underestimate how easy...",
    "postUrl": "https://www.reddit.com/r/AI_Agents/comments/1vcvjb9/i_think_people_seriously_underestimate_how_easy/",
    "subreddit": "AI_Agents",
    "subredditNamePrefixed": "r/AI_Agents",
    "createdAt": "2026-08-07T14:32:10+00:00",
    "editedAt": null,
    "permalink": "/r/AI_Agents/comments/1vcvjb9/i_think_people_seriously_underestimate_how_easy/l8c2m3/",
    "fullUrl": "https://www.reddit.com/r/AI_Agents/comments/1vcvjb9/i_think_people_seriously_underestimate_how_easy/l8c2m3/",
    "isSubmitter": false,
    "stickied": false,
    "distinguished": "",
    "gilded": 0
}
```

### How much does it cost to scrape Reddit?

The Actor uses pay-per-event pricing with two chargeable events:

- **$3.00 / 1,000 comments** — a `dataset-item` event for every comment pushed to the dataset ($0.003 per comment).
- **$0.00005 per run** — an Actor-start event charged once when the run begins.

Post metadata (`postTitle`, `postUrl`, `subreddit`, and related fields) is included with each comment at no extra charge. A 100-comment snapshot costs about **$0.30**; 1,000 comments cost **$3.00**; 10,000 comments cost **$30.00**, plus the $0.00005 start fee. Paid Apify plans discount the per-1,000 comment rate to **$2.90 (Bronze)**, **$2.80 (Silver)**, and **$2.70 (Gold)**. Compute units consumed are deducted from your Apify plan, and residential proxy traffic is billed separately by Apify according to your plan. When your event spending limit is reached, the run stops — you will see that status in the run log.

### Reliability and responsible use

- **Proxy requirement** — The Actor defaults to the Apify proxy with the RESIDENTIAL group. Residential proxies are recommended because datacenter IPs are often blocked by Reddit.
- **Public comments only** — The Actor collects publicly visible comments. No Reddit account is required.
- **Per-post limits** — `maxComments` applies independently to each post. Nested replies are included and tagged with `depth` and `parentId`.
- **Conditional fields** — `editedAt` is null when a comment was never edited; `distinguished` is empty when the author is not a moderator or admin; other flags follow what Reddit exposes.
- **Responsible use** — Only use the data in ways that comply with Reddit's terms of service and applicable law.

### Frequently asked questions

#### Can I scrape comments from Reddit without an account?

Yes. Paste public post IDs or URLs and run the Actor — no Reddit login is required. Only publicly visible comments are collected.

#### Can I scrape nested replies and full threads?

Yes. Set `maxComments` to `0` to collect the full public thread on each post. Replies keep `parentId` and `depth`, so you can reconstruct the conversation tree instead of a flat list of top-level comments.

#### Can I schedule Reddit Comment Scraper to run automatically?

Yes. Open the **Scheduler** tab in Apify Console and set a recurring schedule. Hourly or daily suits fast-moving threads; weekly suits evergreen posts. Create a separate schedule per post or campaign so each job has its own `searchQueries`.

#### What counts as one result?

Each comment pushed to the dataset is one `dataset-item` event at **$3.00 per 1,000 comments** (Bronze $2.90, Silver $2.80, Gold $2.70). Post metadata on that comment is not billed separately. The Actor-start event is $0.00005 per run.

#### What is the difference between searchQueries, postIds, and startUrls?

`searchQueries` accepts post IDs or URLs. `postIds` accepts bare IDs only. `startUrls` accepts full post URLs, including `redd.it` links. Provide at least one source; if none contain a recognizable post, the run fails with "No valid Reddit posts found." A subreddit URL is not a post URL.

#### How do I avoid duplicate records?

The Actor appends comments on every run and does not deduplicate across runs. Use the stable `id` field as the key when merging a fresh run into existing data. Within one run, the same post listed in more than one input field is collected once. Setting `maxComments` caps the size of each post in a run.

#### Do I need a proxy?

Residential proxies are recommended because datacenter IPs are often blocked by Reddit. The default input already uses the Apify RESIDENTIAL group. If a run returns no comments, confirm that proxy configuration is still set to residential.

### Related Scraptivo automations

- [Reddit Scraper](https://apify.com/scraptivo/reddit-scraper) — posts and community listings from subreddits.
- [Twitter/X Profile Scraper](https://apify.com/scraptivo/twitter-x-profile-scraper) — profile and post data from X.
- [YouTube Comment Scraper](https://apify.com/scraptivo/youtube-comment-scraper) — comments from YouTube videos and playlists.
- [Instagram Comment Scraper](https://apify.com/scraptivo/instagram-comment-scraper) — comments from Instagram posts.
- [TikTok Profile Scraper](https://apify.com/scraptivo/tiktok-profile-scraper) — profile and video data from TikTok.

### Support and custom workflows

Need a different field, source, or delivery workflow? Contact Scraptivo at scraptivo@gmail.com. Include the Actor name, sample URL, required fields, and expected volume so we can assess the request.

# Actor input Schema

## `searchQueries` (type: `array`):

Reddit post IDs or post URLs to scrape comments from (e.g. 1vcvjb9 or https://www.reddit.com/r/AI\_Agents/comments/1vcvjb9/). Preferred for agents — post pages are resolved automatically.

## `postIds` (type: `array`):

Reddit post IDs to scrape comments from (e.g. 1vcvjb9). Alternative to searchQueries/startUrls — post URLs are built automatically.

## `startUrls` (type: `array`):

Reddit post URLs to scrape comments from, e.g. https://www.reddit.com/r/AI\_Agents/comments/1vcvjb9/... or https://redd.it/1vcvjb9. Optional when searchQueries or postIds is provided.

## `maxComments` (type: `integer`):

Maximum number of comments to scrape from each post (0 = unlimited per post). Example: 3 posts with maxComments=10 returns up to 30 comments total. Preferred over maxItems.

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

Alias for maxComments (per post) for agent compatibility. Used only when maxComments is omitted (0 = unlimited per post).

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

How to sort comments on each post

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

Apify proxy for the browser session. Residential proxies are strongly recommended — datacenter IPs are often blocked by Reddit.

## Actor input object example

```json
{
  "searchQueries": [
    "1vcvjb9"
  ],
  "postIds": [
    "1vcvjb9"
  ],
  "startUrls": [
    {
      "url": "https://www.reddit.com/r/AI_Agents/comments/1vcvjb9/i_think_people_seriously_underestimate_how_easy/"
    }
  ],
  "maxComments": 100,
  "maxItems": 0,
  "sortBy": "confidence",
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}
```

# Actor output Schema

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

Dataset containing scraped Reddit comments

## `kvsRecords` (type: `string`):

Key-value store run statistics produced by the Actor

# 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 = {
    "searchQueries": [
        "1vcvjb9"
    ],
    "postIds": [
        "1vcvjb9"
    ],
    "startUrls": [
        {
            "url": "https://www.reddit.com/r/AI_Agents/comments/1vcvjb9/i_think_people_seriously_underestimate_how_easy/"
        }
    ],
    "maxComments": 100,
    "proxyConfiguration": {
        "useApifyProxy": true,
        "apifyProxyGroups": [
            "RESIDENTIAL"
        ]
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("scraptivo/reddit-comment-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 = {
    "searchQueries": ["1vcvjb9"],
    "postIds": ["1vcvjb9"],
    "startUrls": [{ "url": "https://www.reddit.com/r/AI_Agents/comments/1vcvjb9/i_think_people_seriously_underestimate_how_easy/" }],
    "maxComments": 100,
    "proxyConfiguration": {
        "useApifyProxy": True,
        "apifyProxyGroups": ["RESIDENTIAL"],
    },
}

# Run the Actor and wait for it to finish
run = client.actor("scraptivo/reddit-comment-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 '{
  "searchQueries": [
    "1vcvjb9"
  ],
  "postIds": [
    "1vcvjb9"
  ],
  "startUrls": [
    {
      "url": "https://www.reddit.com/r/AI_Agents/comments/1vcvjb9/i_think_people_seriously_underestimate_how_easy/"
    }
  ],
  "maxComments": 100,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}' |
apify call scraptivo/reddit-comment-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,scraptivo/reddit-comment-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/WHm9Ux0iPtUj34fqG/builds/GVEEuu4aPfHnak1fM/openapi.json
