# Reddit Comment Search Scraper - Comments by Keyword (`studioxl/reddit-comment-search-scraper`) Actor

Search public Reddit comments by keyword and get one row per comment: text, author, score, date, link, post and subreddit. 10,000 comments for "chatgpt" in 11 minutes. Label each phrase, filter by subreddit, sort or dates, or get only new comments each run. $1.29 per 1,000 comments, no login.

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

## Pricing

from $0.99 / 1,000 comment saveds

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?

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 Comment Search Scraper - Comments by Keyword

Type a phrase like "notion alternative" and get the public Reddit comments that mention it, one row per comment: text, author, score, date, a direct link, and the post and community it was written in. Use it to hear what people say about a product in their own words, collect pain points and feature requests, track a brand or build a text dataset. Label each phrase with your own name for it, and turn on "Only new comments since the last run" to make a scheduled run a daily feed. No Reddit account or login needed.

### What you get

| Field | Example | Notes |
|---|---|---|
| `body` | That's 7h in a week. OP's Title is just straight up wrong. | Markdown |
| `bodyHtml` | `<div class="md"><p>That's 7h in a week...</p></div>` | The same comment as HTML, with formatting, links, lists and images |
| `author`, `authorId` | DnDVex, t2_aygj2l87 | `[deleted]` with an empty ID when the account no longer exists |
| `score` | 2696 | When collected |
| `createdAt`, `editedAt` | 2026-10-04T01:02:57.024Z | UTC, ISO 8601. `editedAt` is empty when the comment was never edited |
| `permalink` | https://www.reddit.com/r/mildlyinfuriating/comments/1wwz5cu/comment/pdpxujj/ | Direct link to the comment |
| `id`, `parentId`, `isTopLevel` | t1_pdpxujj, t1_pdoznsx, false | A top-level comment points to the post (`t3_...`) |
| `isPostAuthor` | false | True when the post's author wrote the comment |
| `postId`, `postTitle`, `postUrl` | t3_1wwz5cu, This is my friend's average daily screen time... | The post the comment belongs to |
| `postScore`, `postCommentCount`, `postCreatedAt` | 29448, 2080, 2026-10-03T21:57:31.591Z | The post's score and comment count when collected |
| `subreddit`, `subredditId` | mildlyinfuriating, t5_2ubgg | |
| `mediaUrls` | \["https://i.redd.it/yeg92dz405th1.jpeg"] | Images or GIFs placed in the comment |
| `isNsfw`, `isScoreHidden` | false, false | |
| `label` | Notion | Your label for the phrase (see Input); the phrase itself when you gave none |
| `query`, `capturedAt` | chatgpt, 2026-10-20T20:10:48.358Z | The phrase that found the comment, and when it was collected |

29 fields per comment, all flat, so CSV and Excel exports have one clean column per field. `id` (for example `t1_pdpxujj`) is stable, so you can merge runs on it. The column names match our [Reddit Comments Scraper](https://apify.com/studioxl/reddit-comments-replies-scraper), so the two datasets can be combined.

How often each field is filled, measured across 10,000 comments for "chatgpt": text, HTML, author name, score, dates, links and post details on every comment; `authorId` on 93.8% (the rest are deleted accounts); `editedAt` on 7.3%; `mediaUrls` on 2.0%.

### How to use it

1. Add one or more search phrases (up to 10).
2. Optional: pick subreddits, a sort order, a time range or exact dates.
3. Click **Start**, then download the results as CSV, Excel or JSON from the **Output** tab.

```json
{
  "queries": ["Notion: notion alternative", "CRM: best crm for startups"],
  "maxComments": 200
}
```

Measured run times: 1,000 comments for "chatgpt" in 59 seconds, 3,000 comments across three phrases in under 4 minutes, and 10,000 comments in 11 minutes. Several runs started at the same time take turns, so each one takes longer: five runs of 500 comments, started together, all finished within 2.5 minutes.

### Input

| Field | What it does | Example | Default |
|---|---|---|---|
| Search phrases (`queries`) | What to search for, one phrase per line, up to 10. Put your own label in front with a colon and a space (`Notion: notion alternative`); every row then has `Notion` in `label`. From code you can also send `{"label": "Notion", "query": "notion alternative"}`. A comment found by several phrases is saved once. | `["Notion: notion alternative", "linear app"]` | `["notion alternative"]` |
| Only these subreddits (`subreddits`) | Keep only comments from these communities, up to 10. Each phrase is searched in each subreddit, 20 searches per run at most. | `["startups", "r/SaaS"]` | empty (all of Reddit) |
| Sort by (`sort`) | `relevance`, `new` (newest first) or `top` (most upvoted). | `new` | `relevance` |
| Time range (`timeFilter`) | `all`, `hour`, `day`, `week`, `month` or `year`. | `week` | `all` |
| Max comments (`maxComments`) | 1 to 10,000 comments per run. With several phrases the limit is shared fairly: each phrase gets an equal part, and what one phrase can't use goes to the others. | `1000` | `50` |
| Max comments per phrase (`maxCommentsPerQuery`) | Optional hard limit for each phrase. 0 means no per-phrase limit. | `200` | `0` |
| Written after (`dateFrom`) | Keep comments written on or after this date. A date or a relative age. | `2026-10-01` or `7 days` | empty |
| Written before (`dateTo`) | Keep comments written on or before this date. | `2026-10-10` | empty |
| Include NSFW comments (`includeNsfw`) | Keep comments from posts or communities marked NSFW (18+). See the FAQ for what this changes in practice. | `true` | `false` |
| Only new comments since the last run (`onlyNewSinceLastRun`) | For scheduled runs: skip comments this feed already delivered. Skipped comments are not charged. | `true` | `false` |
| Feed name (`feedName`) | Runs with the same name share one memory of delivered comments. Use one name per feed. | `notion-mentions` | `my-comment-feed` |

Calling it from code or an AI agent? Common field names work too: `searchQueries`, `keywords`, `q` or `query` for the phrases, `maxItems`, `limit` or `maxResults` for the comment limit, and `subreddit` for one community. Fields the scraper doesn't know are ignored and listed in the run message. If none of the fields is a search phrase, the run stops and names the fields it expected, instead of searching the example phrase. A subreddit name that cannot exist (for example one longer than 21 characters) is skipped and named in the run message.

### Output example

One row from a live run for "chatgpt", trimmed to the main fields:

```json
{
  "id": "t1_pdpxujj",
  "postId": "t3_1wwz5cu",
  "postTitle": "This is my friend's average daily screen time for CHATGPT despite being against data centres",
  "postUrl": "https://www.reddit.com/comments/1wwz5cu/",
  "subreddit": "mildlyinfuriating",
  "parentId": "t1_pdoznsx",
  "isTopLevel": false,
  "body": "That's 7h in a week. OP's Title is just straight up wrong. So 1h of chatgpt each day.",
  "bodyHtml": "<div class=\"md\"><p>That's 7h in a week. OP's Title is just straight up wrong. So 1h of chatgpt each day.</p></div>",
  "author": "DnDVex",
  "authorId": "t2_aygj2l87",
  "score": 2696,
  "createdAt": "2026-10-04T01:02:57.024Z",
  "permalink": "https://www.reddit.com/r/mildlyinfuriating/comments/1wwz5cu/comment/pdpxujj/",
  "postScore": 29448,
  "postCommentCount": 2080,
  "query": "chatgpt",
  "capturedAt": "2026-10-20T20:10:48.358Z"
}
```

Each run also saves a summary (Output tab, "Run summary") with the number of comments per phrase, how many were skipped by your filters and why the run stopped.

### Pricing

You pay per comment saved: **$1.29 per 1,000 comments** on the Apify Free plan, going down to $0.99 per 1,000 on the Business plan and higher. There's no extra start fee.

| Apify plan | Discount tier | Per 1,000 comments |
|---|---|---|
| Free | No discount | $1.29 |
| Starter | Bronze | $1.19 |
| Scale | Silver | $1.09 |
| Business and higher | Gold | $0.99 |

- Example: 2,000 comments for a product name cost $2.58 on the Free plan and $1.98 on the Business plan.
- Duplicates, deleted and removed comments, comments dropped by your filters (dates, subreddits, NSFW) and comments a feed already delivered are free.
- Set "Maximum cost per run" in Run options for a hard cap. If that cap is too low to save even one comment, the run tells you so instead of returning an empty result.

### FAQ

**How fresh are the results?** Each run collects at the moment you start it. With Sort by set to Newest, the first comments in a "chatgpt" run were written less than two minutes before the run started. Scores and comment counts are a snapshot from that moment.

**Why did I get fewer comments than I asked for?** Reddit's comment search shows about 200 comments per search. When a phrase reaches that, the scraper searches again in the other sort orders and then inside the communities where the phrase came up most, and keeps only new comments. That is how a run for "chatgpt" reached 10,000. A niche phrase simply runs out sooner: "日本語 プログラミング" returned 1 comment. Date filters cut further: for "chatgpt" between 1 and 10 October 2026, 300 of 1,954 comments checked fell inside the range. The run message always says why a phrase stopped.

**Does Include NSFW comments do anything?** Very little. Reddit's comment search did not return NSFW comments in our tests: none of 27,823 comments were NSFW, including 350 collected with the setting on, one run of them for the phrase "nsfw". The setting is there so nothing is dropped if that changes.

**Which sort orders and time ranges are there?** Relevance, Newest and Top. Sorting by number of replies is not available for comment search. Newest returns comments strictly newest first. Top returns the most upvoted comments first, in the order Reddit ranks them, which is close to but not exactly by score. Every saved comment is checked against your range by the date it was written; across our test runs, no saved comment fell outside it. For a busy word and a short range, Newest finds the most: for "chatgpt", a Past-hour run saved 240 comments, all written in the last hour.

**Can I monitor a keyword every day?** Yes. Save the input as a task, set Sort by to Newest, turn on "Only new comments since the last run", give the feed a name, and add a schedule. Each run then delivers only comments the feed has not delivered before, and you pay only for those. Measured on "notion alternative" with 100 comments per run: the first run delivered 100, the second delivered 100 different ones and skipped the first 100 at no charge, and across four runs no comment was delivered twice. A feed with a different name keeps its own memory. Results can go to Google Sheets, Slack, Make, Zapier or n8n through Apify integrations.

**What is the label for?** It lets you name each phrase the way your report needs it, for example the competitor or product it belongs to. "Notion: notion alternative" searches for "notion alternative" and writes "Notion" in the `label` column of every comment it finds, so you can group or filter the export without matching phrases yourself. Only a colon followed by a space separates the label, so a phrase like `subreddit:SaaS crm` is left as it is.

**Can I search inside one post, or get the whole thread?** Not with this Actor. Reddit's comment search cannot be narrowed to a single post; in our tests, 2 of 100 results came from the chosen post. To read every comment on a post, paste its link into our [Reddit Comments Scraper](https://apify.com/studioxl/reddit-comments-replies-scraper). The `postUrl` values of a run can be pasted there in bulk. To search posts by keyword instead of comments, use our [Reddit Search Scraper](https://apify.com/studioxl/reddit-post-search-scraper).

### Limits

- Up to 10 phrases, 10 subreddits and 10,000 comments per run. About 200 comments per search, extended by extra searches as described above; a phrase can run out before your limit, and the run message says so.
- Public comments only. Deleted and removed comments have no text and are skipped. In our test runs none came back at all (0 of 27,823).
- NSFW comments are almost never returned, with or without the setting.
- Search inside a single post is not available.
- A feed remembers the most recent 300,000 comments it delivered.
- A past date range is filled by checking each comment's date, so it reads more comments per saved row: 300 comments for 1 to 10 October 2026 meant checking 1,954 (89 seconds). A narrow range on a rare phrase can run out.
- Scores and comment counts are a snapshot from the moment of collection.

Questions or a missing field? Open an issue in the **Issues** tab with your run ID.

# Actor input Schema

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

What to search Reddit comments for, one phrase per line (up to 10). Add your own label in front with a colon and a space, for example "Brand A: notion alternative"; every row then carries "Brand A" in the label column. A comment that matches several phrases is saved and charged once.

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

Leave empty to search all of Reddit. Add names like "startups" or "r/SaaS" to keep only comments from those communities. Each phrase is searched in each subreddit (20 searches at most).

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

Order of the search results. Pick Newest to monitor a keyword, Top for the most upvoted comments.

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

Only keep comments written within this period.

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

Most comments to save in this run, across all phrases (1 to 10,000). The limit is shared fairly between phrases. You pay only for saved comments.

## `maxCommentsPerQuery` (type: `integer`):

Optional. Stop each phrase after this many comments, for example 200. 0 means no per-phrase limit (the total is still shared fairly).

## `dateFrom` (type: `string`):

Optional. Keep comments written on or after this date, for example 2026-01-01 or "7 days".

## `dateTo` (type: `string`):

Optional. Keep comments written on or before this date, for example 2026-03-31.

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

Off by default. Turn on to keep comments from posts or communities marked NSFW (18+). In our tests none of 27,823 comments were NSFW, including 350 collected with this setting on, so it rarely changes the output.

## `onlyNewSinceLastRun` (type: `boolean`):

For scheduled runs: skip comments this feed already delivered in earlier runs. Skipped comments are not charged. The first run of a feed delivers everything it finds.

## `feedName` (type: `string`):

Runs with the same feed name share one memory of delivered comments. Use a different name per feed, for example "notion-mentions". Letters, digits and dashes.

## Actor input object example

```json
{
  "queries": [
    "Notion: notion alternative",
    "CRM: best crm for startups"
  ],
  "sort": "relevance",
  "timeFilter": "all",
  "maxComments": 50,
  "maxCommentsPerQuery": 0,
  "includeNsfw": false,
  "onlyNewSinceLastRun": false,
  "feedName": "my-comment-feed"
}
```

# Actor output Schema

## `comments` (type: `string`):

Saved comments. Switch views for post and thread details, or text and media.

## `completeJson` (type: `string`):

All fields for every saved row, without a view-specific field selection.

## `summary` (type: `string`):

Saved-comment counts per search phrase, filters applied and why the run stopped.

# 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": [
        "Notion: notion alternative",
        "CRM: best crm for startups"
    ],
    "maxComments": 50
};

// Run the Actor and wait for it to finish
const run = await client.actor("studioxl/reddit-comment-search-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 = {
    "queries": [
        "Notion: notion alternative",
        "CRM: best crm for startups",
    ],
    "maxComments": 50,
}

# Run the Actor and wait for it to finish
run = client.actor("studioxl/reddit-comment-search-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 '{
  "queries": [
    "Notion: notion alternative",
    "CRM: best crm for startups"
  ],
  "maxComments": 50
}' |
apify call studioxl/reddit-comment-search-scraper --silent --output-dataset

```

## MCP server setup

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