# Reddit Scraper Pro | Sentiment + Analytics + Brand Detection (`b3264/reddit-scraper-pro`) Actor

Most feature-rich Reddit scraper on Apify. 6 modes: posts, comments, search, profiles, info, URL. Built-in sentiment scoring, engagement analytics, brand detection, influencer reports, toxic content flags, markdown bodies, AI-ready output. No API key needed. $0.75/1K results.

- **URL**: https://apify.com/b3264/reddit-scraper-pro.md
- **Developed by:** [Brandon Hamm](https://apify.com/b3264) (community)
- **Categories:** Social media, AI, Developer tools
- **Stats:** 2 total users, 1 monthly users, 80.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.75 / 1,000 results

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/platform/actors/running/actors-in-store#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 Scraper Pro | Sentiment + Engagement Analytics + Brand Detection + Influencer Reports

The most feature-rich Reddit scraper on Apify. Six modes in one actor, every result enriched with sentiment scoring, engagement analytics, brand detection, and AI-ready clean text. No API key or login required.

### Why this actor?

Reddit killed unauthenticated `.json` API access in May 2026. Scrapers that relied on the free JSON API broke overnight. This actor uses Playwright with residential proxies and parses Reddit's server-rendered HTML, so it keeps working where JSON-based scrapers fail.

### What makes this different

**Built-in sentiment scoring.** Every post and comment gets a sentiment label (positive/negative/neutral), confidence score, and toxic content flag. No need to pipe results through a separate NLP API.

**Engagement analytics on every result.** scorePerHour, commentsPerHour, engagementTotal, commentToScoreRatio, ageHours, titleLength, bodyWordCount. See which posts are gaining traction in real time, not just which ones have the highest all-time score.

**Automatic brand mention extraction.** 30+ tech companies auto-detected from post and comment text (Apple, Google, Meta, Amazon, OpenAI, Tesla, Nvidia, Microsoft, and more). Built for brand monitoring workflows without a second processing step.

**Influencer reports.** Every run ranks users by engagement impact and outputs an INFLUENCER\_REPORT to the key-value store. Identify high-impact accounts in any subreddit or search result.

**Toxic content detection.** Separate from sentiment scoring, a dedicated toxic word filter flags potentially problematic content. Useful for moderation and brand safety workflows.

**Lead generation fields.** Social handles (@usernames) and email addresses auto-extracted from every post and comment. Find prospects already talking about your problem space.

**Markdown bodies.** Post and comment bodies converted from HTML to clean markdown. Ready for LLM ingestion, RAG pipelines, or human reading without a conversion step.

**AI-ready clean text.** Normalized, whitespace-stripped text field designed for LLM fine-tuning, embeddings, or classification pipelines.

**Maximize coverage mode.** Traverses hot + new + top sort orders automatically for broader post collection when you need maximum data from a subreddit.

**Three output formats.** Full (all fields), lean (essential fields only for smaller datasets), or markdown\_only (just titles and markdown bodies for content analysis).

**Playwright with residential proxies.** Reddit blocks all datacenter IPs with 403. This actor uses Playwright headless browser with Apify's residential proxy pool and stealth settings (webdriver detection removed, custom plugins/languages) to bypass Reddit's blocking. It just works.

### 6 modes in 1 actor

| Mode | Description | Auth Required |
|---|---|---|
| `subreddit_posts` | Scrape posts from any subreddit (hot/new/top/rising/controversial) with pagination | No |
| `search` | Search Reddit for keywords by scraping r/all and filtering | No |
| `post_comments` | Get full nested comment trees from post URLs | No |
| `user_profile` | Get a user's post and comment history with pagination | No |
| `subreddit_info` | Get subreddit metadata (subscribers, active users, description, NSFW) | No |
| `url` | Get a single post by URL | No |

### What you get

#### Post output fields:

- `post_id` -- Reddit post ID
- `title` -- Post title
- `author` -- Username
- `subreddit` -- Subreddit name (without r/ prefix)
- `score` -- Upvote count
- `num_comments` -- Comment count
- `url` -- External link URL (for link posts)
- `permalink` -- Reddit permalink
- `selftext` -- Body text (for self/text posts)
- `selftextMarkdown` -- Body text converted to clean markdown
- `cleanText` -- AI-ready normalized text for LLM pipelines
- `domain` -- Link domain
- `flair` -- Post flair text
- `nsfw` -- NSFW flag (boolean)
- `stickied` -- Stickied flag (boolean)
- `gilded` -- Gilded flag (boolean)
- `timestamp` -- ISO 8601 timestamp
- `thumbnail` -- Thumbnail image URL
- `upvote_ratio` -- Upvote ratio (0-1)
- `postType` -- text, image, video, or link
- `comments` -- Array of comment objects (if `includeComments` is enabled)
- `sentiment` -- {label, score, confidence, toxic, toxicWordCount}
- `mentionedBrands` -- Array of detected brand names
- `extractedUrls` -- Array of URLs found in post text
- `socialHandles` -- Array of @handles found in post text
- `emails` -- Array of email addresses found in post text
- `ageHours` -- Hours since post creation
- `scorePerHour` -- Upvote velocity (score / age in hours)
- `commentsPerHour` -- Comment velocity
- `engagementTotal` -- Score + comment count combined
- `commentToScoreRatio` -- Comments relative to score
- `titleLength` -- Character count of title
- `bodyWordCount` -- Word count of body text

#### Comment output fields:

- `comment_id` -- Reddit comment ID
- `author` -- Username
- `body` -- Comment text
- `bodyMarkdown` -- Comment text as clean markdown
- `score` -- Upvote count
- `depth` -- Nesting depth (0 = top-level)
- `permalink` -- Comment permalink
- `timestamp` -- ISO 8601 timestamp
- `stickied` -- Stickied flag
- `gilded` -- Gilded flag
- `replies` -- Array of reply comment objects (recursive)
- `sentiment` -- {label, score, confidence, toxic, toxicWordCount}
- `mentionedBrands` -- Array of detected brand names
- `extractedUrls` -- Array of URLs found in comment text
- `ageHours` -- Hours since comment creation
- `scorePerHour` -- Upvote velocity
- `engagementTotal` -- Score + reply count

#### Influencer report (KVS output):

When users are tracked during a run, an `INFLUENCER_REPORT` is saved to the run's key-value store containing:

- `score` -- 0-100 influence score
- `tier` -- top influencer / high influence / moderate influence / low influence / minimal
- `totalPostScore` -- Sum of post scores
- `totalCommentScore` -- Sum of comment scores
- `postCount` -- Number of posts
- `commentCount` -- Number of comments
- `avgPostScore` -- Average score per post

### Use cases

**Brand monitoring.** Track mentions of your brand or competitors across all subreddits. Sentiment and brand detection are built in, so you see tone and context without a second processing step.

**AI training data.** Bulk export Reddit discussions for fine-tuning LLMs, building RAG pipelines, or creating sentiment classifiers. Clean text and markdown bodies are ready for ingestion.

**Market research.** Find what problems your target market describes in their own words. Filter by subreddit and keyword, export with sentiment to quantify frustration or enthusiasm.

**SEO.** Reddit threads dominate Google search results. Find which topics rank for your target keywords and mine title patterns for content ideas.

**Lead generation.** Find users actively asking questions your product solves. Social handles and emails are auto-extracted, ready for outreach.

**Community analysis.** Run influencer reports on any subreddit to identify high-impact accounts. Track engagement velocity to find trending discussions before they peak.

**Content moderation.** Toxic content detection flags potentially problematic posts and comments without a separate moderation API. Filter by toxicity for brand-safe curation.

**OSINT.** Investigate usernames, post histories, subreddit activity patterns. Pull full comment trees from key posts for narrative analysis.

### Input reference

| Field | Type | Required | Default | Description |
|---|---|---|---|---|
| mode | string | Yes | `subreddit_posts` | One of: `subreddit_posts`, `search`, `post_comments`, `user_profile`, `subreddit_info`, `url` |
| subreddits | array | No | `["technology"]` | Subreddit names without r/ prefix (for `subreddit_posts` and `subreddit_info`) |
| searchQueries | array | No | `[]` | Search terms (for `search` mode) |
| searchSubreddit | string | No | `""` | Restrict search to a specific subreddit |
| postUrls | array | No | `[]` | Full Reddit post URLs (for `post_comments` and `url` modes) |
| username | string | No | `""` | Reddit username without u/ prefix (for `user_profile` mode) |
| sort | string | No | `hot` | `hot`, `new`, `top`, `rising`, `controversial` |
| timeFilter | string | No | `all` | `hour`, `day`, `week`, `month`, `year`, `all` |
| maxResults | integer | No | `100` | Max posts per subreddit or search query (1-5000) |
| maxCommentsPerPost | integer | No | `50` | Max comments to extract per post (0-2000) |
| includeComments | boolean | No | `false` | Also scrape comments for each post (slower) |
| includeNsfw | boolean | No | `false` | Include NSFW posts in results |
| maximizeCoverage | boolean | No | `false` | Traverse hot + new + top sort orders for broader collection |
| includeSentiment | boolean | No | `true` | Add sentiment scoring to every post and comment |
| extractBrands | boolean | No | `true` | Auto-detect brand mentions, URLs, social handles, emails |
| outputFormat | string | No | `full` | `full`, `lean`, or `markdown_only` |
| useApifyProxy | boolean | No | `true` | Use Apify residential proxy pool (recommended, handles Reddit's IP blocking) |
| customProxyUrl | string | No | `""` | Custom HTTP proxy URL (overrides Apify proxy) |

### Example inputs

#### Scrape hot posts from r/technology with full enrichment:

```json
{
    "mode": "subreddit_posts",
    "subreddits": ["technology", "programming", "MachineLearning"],
    "sort": "hot",
    "maxResults": 50,
    "includeSentiment": true,
    "extractBrands": true
}
```

#### Search Reddit for brand mentions with comments:

```json
{
    "mode": "search",
    "searchQueries": ["openai chatgpt review", "anthropic claude experience"],
    "sort": "new",
    "timeFilter": "week",
    "maxResults": 200,
    "includeComments": true,
    "maxCommentsPerPost": 20
}
```

#### Get full comment tree from a post:

```json
{
    "mode": "post_comments",
    "postUrls": ["https://www.reddit.com/r/technology/comments/abc123/example/"],
    "maxCommentsPerPost": 500
}
```

#### Scrape a user's post history:

```json
{
    "mode": "user_profile",
    "username": "spez",
    "sort": "new",
    "maxResults": 100
}
```

#### Maximize coverage from a subreddit (hot + new + top):

```json
{
    "mode": "subreddit_posts",
    "subreddits": ["wallstreetbets"],
    "sort": "hot",
    "maxResults": 500,
    "maximizeCoverage": true,
    "includeComments": true,
    "maxCommentsPerPost": 10
}
```

#### Get subreddit info:

```json
{
    "mode": "subreddit_info",
    "subreddits": ["technology", "science", "askscience"]
}
```

### Technical details

- **Playwright headless browser** with stealth settings (webdriver detection removed, custom plugins/languages)
- **Apify residential proxy pool** handles Reddit's datacenter IP blocking automatically
- **Pagination** follows `after` tokens up to `maxResults`
- **Deduplication** post IDs tracked across pages and sort orders
- **Rate limiting** 0.5s delay between page requests, automatic backoff on 403/429
- **NSFW filtering** optionally exclude NSFW content
- **Recursive comment parsing** nested replies with depth tracking
- **Sentiment lexicon** 120+ positive words, 80+ negative words, 30+ toxic terms
- **Brand lexicon** 30+ tech companies with keyword variants (e.g., "iphone" -> "apple")

### Pricing

Pay per result: $0.75 per 1,000 results. No monthly rental fee. No minimum spend.

### Limitations

- Search mode uses r/all filtering (no OAuth needed, but less precise than Reddit's native search)
- Reddit may rate-limit high-volume scraping. Residential proxies handle this automatically.
- Reddit's HTML structure may change. Actor is maintained and updated when Reddit changes their markup.

# Actor input Schema

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

What to scrape: subreddit posts, search results, post comments, user profiles, subreddit metadata, or a single post by URL

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

List of subreddit names (without r/ prefix). Used by subreddit\_posts and subreddit\_info modes.

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

Keywords to search for on Reddit. Used by search mode.

## `searchSubreddit` (type: `string`):

Restrict search to a specific subreddit (optional). Leave empty to search all of Reddit.

## `postUrls` (type: `array`):

Full Reddit post URLs. Used by post\_comments and url modes.

## `username` (type: `string`):

Reddit username (without u/ prefix). Used by user\_profile mode.

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

Sort order for posts

## `timeFilter` (type: `string`):

Time range for top/controversial sorting

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

Maximum number of posts/items to extract

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

Maximum comments to extract per post (0 = no limit). Only used when includeComments is true or in post\_comments mode.

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

Fetch comment trees for each post (slower but richer data)

## `includeNsfw` (type: `boolean`):

Include NSFW/18+ content in results

## `maximizeCoverage` (type: `boolean`):

Traverse multiple sort orders (hot+new+top) to find posts a single listing can't expose. Reddit shows ~1000 posts per listing; this gets more. Only for subreddit\_posts mode.

## `includeSentiment` (type: `boolean`):

Score sentiment (positive/negative/neutral) and detect toxic content for every post and comment. Uses built-in lexicon model, no external API needed.

## `extractBrands` (type: `boolean`):

Auto-detect brand mentions (Apple, Google, Tesla, etc.), extract URLs, social handles, and email addresses from post and comment text.

## `outputFormat` (type: `string`):

Control output size: full = all fields + analytics, lean = key fields only, markdown\_only = bodies as markdown with minimal metadata

## `useApifyProxy` (type: `boolean`):

Use Apify's residential proxy pool (recommended). Reddit blocks datacenter IPs; residential proxies are required for reliable scraping.

## `customProxyUrl` (type: `string`):

Use your own proxy URL instead of Apify's. Format: http://user:pass@host:port. Leave empty to use Apify proxy.

## Actor input object example

```json
{
  "mode": "subreddit_posts",
  "subreddits": [
    "technology"
  ],
  "searchQueries": [],
  "searchSubreddit": "",
  "postUrls": [],
  "username": "",
  "sort": "hot",
  "timeFilter": "all",
  "maxResults": 100,
  "maxCommentsPerPost": 50,
  "includeComments": false,
  "includeNsfw": false,
  "maximizeCoverage": false,
  "includeSentiment": true,
  "extractBrands": true,
  "outputFormat": "full",
  "useApifyProxy": true,
  "customProxyUrl": ""
}
```

# Actor output Schema

## `posts` (type: `string`):

Dataset containing extracted Reddit posts with titles, scores, authors, comments, and metadata.

# 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 = {};

// Run the Actor and wait for it to finish
const run = await client.actor("b3264/reddit-scraper-pro").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 = {}

# Run the Actor and wait for it to finish
run = client.actor("b3264/reddit-scraper-pro").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 '{}' |
apify call b3264/reddit-scraper-pro --silent --output-dataset

```

## MCP server setup

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

```

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/q8y0kCWcIegzdvQTK/builds/XkQYEo0clbNDKHyhp/openapi.json
