# Reddit Search Scraper Pro (`red.cars/reddit-search-scraper-pro`) Actor

Search Reddit by keyword or subreddit. Clean JSON rows for posts and comments with IDs, titles, bodies, authors, scores and timestamps.

- **URL**: https://apify.com/red.cars/reddit-search-scraper-pro.md
- **Developed by:** [AutomateLab](https://apify.com/red.cars) (community)
- **Categories:** Social media, Developer tools, Other
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.50 / 1,000 result saveds

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 Search Scraper Pro

Search Reddit by keyword or list a subreddit's posts, and get clean structured JSON rows: title, body, score, upvote ratio, comment count, author, exact timestamps, flair and permalinks. Optional top-comment threads per post. No browser needed, runs in seconds.

### Why this one

The Reddit search segment's leading fast scraper, fatihtahta/reddit-scraper-search-fast, holds 2,645 monthly users at a **4.2 rating from 21 reviews** and charges from $1.19 per 1,000 results. SolidCode's reddit-scraper charges $1.80 per 1,000. Users in this segment keep hitting the same wall: big promises, then censored or missing engagement fields, spotty comment support, and surprise charges for rows that arrive empty.

**Reddit Search Scraper Pro sits at $1.50 per 1,000 results, between them, with every engagement field on every row and a hard no-empty-rows guarantee: filtered results are dropped before they are saved, so you are never billed for a row you do not receive.**

### Input

| Field | Type | Default | Description |
|---|---|---|---|
| `queries` | array | `["cortijo"]` | Keyword searches to run on Reddit |
| `subreddits` | array | `[]` | Subreddit names (without `r/`) to list posts from |
| `maxItems` | number | `10` | Hard cap on results across all sources |
| `sort` | string | `relevance` | `relevance`, `hot`, `top`, `new` or `comments` |
| `timeRange` | string | `all` | `hour`, `day`, `week`, `month`, `year` or `all` |
| `includeComments` | boolean | `false` | Also fetch and save top comments per post |
| `commentLimit` | number | `10` | Top comments per post when comments are on |
| `minScore` | number | `0` | Drop posts/comments below this score before saving (never billed) |
| `includeSelftext` | boolean | `true` | Save full post body for text posts |
| `maxPagesPerSource` | number | `10` | Max result pages (100 each) per query/subreddit |

### Output

| Field | Description |
|---|---|
| `type` | `post` or `comment` |
| `id` | Reddit item ID (e.g. `t3` base36) |
| `title` / `body` | Post title, or comment body |
| `subreddit` | Subreddit the item is in |
| `author` | Reddit username |
| `score` | Net upvotes |
| `upvoteRatio` | Post upvote ratio (posts only) |
| `numComments` | Post comment count (posts only) |
| `createdUtc` | ISO 8601 timestamp |
| `permalink` | Full reddit.com link |
| `url` | Outbound link for link posts (posts only) |
| `selftext` | Full post body (posts only, when enabled) |
| `linkFlair` | Post flair |
| `isNSFW` | NSFW flag |
| `postId` / `postTitle` | Parent post reference (comments only) |
| `sourceQuery` | The query that surfaced the post (search mode) |

### Pricing

Pay per event:

| Event | Price | When |
|---|---|---|
| actor-start | $0.005 | Once per run |
| result | $0.0015 | Per post or comment row saved to the dataset |

**$1.50 per 1,000 results.** Filtered rows (below `minScore`, duplicates) are dropped before they are saved, so you are never billed for a row you do not receive.

### Use cases

- Social listening: track every mention of a brand, product or artist across Reddit
- Sentiment analysis: pull post bodies and top comments for LLM pipelines
- Trend research: watch a keyword's top and new posts over rolling time windows
- Community research: list a subreddit's hottest posts with engagement stats

### FAQ

**Do I need Reddit API credentials or a login?**
No. The actor fetches Reddit's public JSON endpoints through Apify's unblocking proxy.

**Can I mix search queries and subreddits in one run?**
Yes. Add both `queries` and `subreddits`; results carry `sourceQuery` so you can tell them apart.

**How do comments appear?**
Each comment is its own `comment` row with `postId` and `postTitle` linking it to the parent post.

**What counts as a billed result?**
Every row that reaches your dataset: posts and, when enabled, comments. Rows dropped by `minScore` or deduplication are never saved and never billed.

# Actor input Schema

## `queries` (type: `array`):

Keyword searches to run on Reddit. Posts matching these terms are returned as clean rows.

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

Subreddit names (without r/) to list posts from. Leave empty to use search queries only.

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

Hard cap on results saved across all queries and subreddits.

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

How to order results.

## `timeRange` (type: `string`):

Limit results to a posting window (applies to top/new sorting and search).

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

Fetch top comments for each collected post and save them as comment rows.

## `commentLimit` (type: `integer`):

Top comments to save per post when comment threads are enabled.

## `minScore` (type: `integer`):

Drop posts and comments with a score below this. Filtered results are never saved, so you are never billed for them.

## `includeSelftext` (type: `boolean`):

Save the full selftext body of text posts.

## `maxPagesPerSource` (type: `integer`):

Maximum result pages (100 results each) to walk per query or subreddit.

## Actor input object example

```json
{
  "queries": [
    "cortijo"
  ],
  "subreddits": [],
  "maxItems": 10,
  "sort": "relevance",
  "timeRange": "all",
  "includeComments": false,
  "commentLimit": 10,
  "minScore": 0,
  "includeSelftext": true,
  "maxPagesPerSource": 10
}
```

# Actor output Schema

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

URL to the dataset items: post rows and optional comment rows, one clean JSON object per result.

# 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 = {
    "queries": [
        "cortijo"
    ],
    "subreddits": []
};

// Run the Actor and wait for it to finish
const run = await client.actor("red.cars/reddit-search-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 = {
    "queries": ["cortijo"],
    "subreddits": [],
}

# Run the Actor and wait for it to finish
run = client.actor("red.cars/reddit-search-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 '{
  "queries": [
    "cortijo"
  ],
  "subreddits": []
}' |
apify call red.cars/reddit-search-scraper-pro --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,red.cars/reddit-search-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/kQZNK02OXuIEL6zNu/builds/OSXjFkvs8G8lOLLdm/openapi.json
