# Reddit Comments Search Scraper & API: Find Comments by Keyword (`quarra/reddit-comments-search-scraper`) Actor

Reddit comments search by keyword, on all of Reddit or inside one subreddit: comment text, score, author, date, parent, and the title and link of its post. Exact-word matching, date window, excluded words, new comments only on a schedule.

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

## Pricing

from $2.20 / 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?

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

Type keywords and get the Reddit comments that contain them, on all of Reddit or inside one subreddit: comment text,
score, author, date, the comment it replies to, and the title and link of its post. No login, no cookies, no API key.
Export as JSON, CSV or Excel, or read it through the Apify API.

- **Comments, not posts**: Reddit's own comment search, with a record per comment. Each one carries `postTitle`,
  `postUrl` and `parentId`, so you know where it was written and what it answers.
- **Exact words when you need them**: Reddit's search is loose. Turn on strict search and only comments with every
  word of your query, as whole words, are kept (the others are not charged). Quotes keep a phrase together, `-word`
  excludes, `OR` groups alternatives.
- **One subreddit or all of Reddit**: name a subreddit in **Search only inside this subreddit**, or leave it empty.
- **Newest first, in a date window**: with the New sort, the time range and the date fields cut the reading at the
  right moment, so a watch on a brand name stays cheap.
- **Only new comments on a schedule**: turn on **Only new since the last run** and each run returns and charges only
  the comments earlier runs did not return.

**$2.50 per 1,000 comments**, less on paid plans, plus $0.005 per run. Searches that fail, duplicates, and comments
removed by your filters are not charged.

Optional **AI analysis** of each comment (sentiment, intent, entities, summary, pain point, business signals, your
own labels): **$0.50 per 1,000** analyzed records.

### What people use it for

- Brand and product mentions: every comment that names your product, a competitor or a keyword, with the link to
  reply or to read the whole thread.
- Research on what people say: pain points, workarounds and wishes about a topic, in the words of the people who
  write them.
- Finding conversations to join: comments in a subreddit that ask for a tool or a recommendation.
- Feeding a spreadsheet, a CRM or an LLM with real comments instead of whole threads.

### How to search Reddit comments by keyword

1. Type keywords into **Comment search**, one search per line. Quotes keep a phrase together: `"home assistant"`.
2. Optionally name a subreddit, turn on strict search, and choose a sort (Relevance, Top or New).
3. Click **Start** and read the comments in the run's **Output** tab.

Through the API:

```json
{
  "commentSearchQueries": ["\"home assistant\""],
  "searchSubreddit": "homeassistant",
  "strictSearch": true,
  "searchSort": "new",
  "maxPostsPerSource": 100
}
```

A brand watch, each day, only the new comments, without the ones that mention a word you do not want:

```json
{
  "commentSearchQueries": ["\"vaultwarden\""],
  "searchSort": "new",
  "timeFilter": "day",
  "strictSearch": true,
  "excludeKeywords": ["bitwarden"],
  "onlyNew": true,
  "watchName": "vaultwarden-mentions"
}
```

Like any Actor on Apify, it can be scheduled, connected to webhooks, Make, Zapier, n8n, or called by AI agents
through Apify's MCP server.

### Output

One record per comment. A real result (October 21, 2026, author replaced, text shortened, some fields left out):

```json
{
  "type": "comment",
  "id": "19rfyxigm2blu",
  "url": "https://www.reddit.com/r/homeassistant/comments/1xbrwmv/letting_alexa_into_home_assistant/19rfyxigm2blu/",
  "postId": "1xbrwmv",
  "postTitle": "Letting Alexa into Home Assistant",
  "postUrl": "https://www.reddit.com/r/homeassistant/comments/1xbrwmv/letting_alexa_into_home_assistant/",
  "parentId": "t3_1xbrwmv",
  "parentType": "post",
  "subreddit": "homeassistant",
  "author": "example_user",
  "body": "You can convert old Echo Dots to Voice satellites via EchoMuse. I bought 3 from eBay for $15/ea. …",
  "createdAt": "2026-10-21T16:58:21Z",
  "score": 2,
  "isSubmitter": false,
  "source": "comment search: home assistant (r/homeassistant)"
}
```

| Field | What it holds |
|---|---|
| `body`, `score`, `createdAt`, `author` | the comment as written, its score, its date and its author |
| `url`, `permalink` | the link to the comment itself |
| `postId`, `postTitle`, `postUrl`, `postAuthor` | the post it was written under |
| `parentId`, `parentType` | what it replies to: the post (`t3_…`) or another comment (`t1_…`) |
| `isSubmitter`, `stickied`, `distinguished`, `isEdited` | whether the author wrote the post, and the comment's state |
| `source` | the search that found the comment |

`depth` and `rootCommentId` are `null` here: Reddit's comment search does not say where a comment sits in its thread.
To read a whole thread, use the [Reddit Comments Scraper](https://apify.com/quarra/reddit-comments-scraper) with
`postUrl`. Field names stay the same between runs: a value Reddit does not provide is `null`, not missing. The run
summary (what was found, what failed and why) is the `OUTPUT` record of the run's key-value store.

### AI analysis (optional)

Turn on **AI analysis** and every comment gets an `aiAnalysis` object next to its own fields: language, sentiment and
score, emotion, intent (question, seeking_recommendation, complaint, praise, purchase_intent, comparison…), category,
topics, named brands, products and people, a one-sentence English summary, the pain point, and business signals
(`wantsHelp`, `buyingSignal`, `mentionsPrice`, `featureRequest`, `isVendor`), plus a `relevance` score from 0 to 1
against your search and up to 5 yes/no labels of your own, as `{"label_name": "what makes it true"}`.

**$0.50 per 1,000 analyzed records, every field included.** Deleted, removed, bot (AutoModerator) and empty comments
are not analyzed and not charged. If an analysis fails, the comment is still delivered and charged as usual, its
`aiAnalysisStatus` is `failed` with the reason in `aiAnalysisError`, and the analysis is not charged. Any language in,
summaries in English; the first ~2,500 characters of a long comment are analyzed. It adds time: expect one to five
minutes per 100 comments.

### Inputs

- **Comment search**: keywords to find in comments, one search per line. **Search only inside this subreddit**.
- **Strict search (exact words only)**, and where the words must appear. **Excluded keywords**.
- **Max comments per search** and **Max results in total**.
- **Search sort** (Relevance, Top, New) and **Time range**. **Posted after / before** and **Comments posted after /
  before**: both date windows apply to a comment found.
- **Include NSFW** (off by default; the NSFW flag is the post's).
- **AI analysis** and **Your own labels**.
- **Only new since the last run** and **Watch name**, for scheduled runs.

### Pricing

Pay per event:

| Apify plan | Comments |
|---|---|
| Free | $2.50 / 1,000 |
| Starter | $2.40 / 1,000 |
| Scale | $2.30 / 1,000 |
| Business and above | $2.20 / 1,000 |

AI analysis (optional): $0.50 / 1,000 analyzed records on every plan.

Plus the start: $0.005 per GB of run memory. Not charged: searches that fail, error records, duplicates, comments
removed by strict search or by a filter, results already returned to a watch. Set **Maximum cost per run** in the run
options and the run stops before going over it.

### Limits

- Reddit lists a limited number of comments per search: "home assistant" with the New sort and a one-week range
  stopped at 230 comments (October 21, 2026), all from the last four hours. To go further back, cut the time into
  windows with the date fields and run one search per window.
- **Dates and time range only cut the reading with the New sort.** With Relevance or Top, Reddit ignores them: the
  date fields still filter the results, but the search does not go looking for older or newer ones.
- Reading is paced: about 10 comments per page, 230 comments in 4 minutes 40 seconds on Apify (October 21, 2026).
- Strict search checks words, not meaning; quotes around a phrase fix most false matches.
- Quarantined communities are visible to logged-in accounts only. The Actor reports them and does not log in.

### FAQ

**How is this different from the Reddit Search Scraper?** It only searches comments, and its form is built around
that. The [Reddit Search Scraper](https://apify.com/quarra/reddit-search-scraper) searches posts first, with the
comments of each post as an option.

**Can I search comments in one subreddit only?** Yes: **Search only inside this subreddit** takes `selfhosted`,
`r/selfhosted` or its link.

**How do I get only the comments that contain my exact phrase?** Turn on strict search and put the phrase in quotes.
Comments that do not contain it are dropped and never charged.

**Do I need a Reddit account or API key?** No account, no cookies, no API key. Platform costs are included in the
price.

**Is it legal?** It collects public comments any logged-out visitor can see. Reddit's terms and privacy law (GDPR in
the EU) apply to how you use the data.

**Does the Actor send anything to Quarra?** Only when a run fails or runs out of time: the Actor, its build, the error type, the line of our code where it happened, and the memory and time the run was given, so we can fix it fast. Never your input, your results, your account or the run ID.

### Related tools from Quarra

- [Reddit Scraper](https://apify.com/quarra/reddit-scraper): subreddits, searches, post URLs and users in one Actor.
- [Reddit Search Scraper](https://apify.com/quarra/reddit-search-scraper): posts and comments by keyword.
- [Reddit Comments Scraper](https://apify.com/quarra/reddit-comments-scraper): all the comments of posts from their
  links.
- [Reddit Lead Finder](https://apify.com/quarra/reddit-lead-finder): the posts and comments where people ask for a
  recommendation or show buying intent.
- [Reddit Subreddit Scraper](https://apify.com/quarra/reddit-subreddit-scraper): the posts of any subreddit.

# Actor input Schema

## `commentSearchQueries` (type: `array`):

Find COMMENTS containing your keywords, anywhere on Reddit (or in the subreddit above), one query per line: each comment with its text, score, date, parentId and its post's title and URL. Strict search and excluded keywords apply to the comment's text. Reddit's comment search ignores dates except with Search sort New: use New with a time range or date window to monitor.

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

Optional. Restrict every search query and comment search to one subreddit (selfhosted, r/selfhosted or its URL).

## `strictSearch` (type: `boolean`):

Reddit's search returns loosely related posts (for home assistant, 17 of the top 100 contain it). When on, a post is kept only if its title or text contains EVERY word of the query, as whole words (ai never matches said; case and accents ignored). "Quotes" require a phrase, -word excludes, OR and parentheses group alternatives. Other sorts of the same time range are read to reach your limit. Rejected posts are never charged (counted in OUTPUT as filteredOut).

## `strictMatchIn` (type: `string`):

Where the words of a strict search and the excluded keywords must (or must not) appear.

## `maxPostsPerSource` (type: `integer`):

Posts per subreddit or search query, comments per comment search, posts and comments per user history. Reddit lists ~1,000 posts per subreddit sort and ~250 per search; enable 'Go beyond Reddit's listing cap' for more. With 'Only new', this is the window watched.

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

Optional hard cap for the whole run, counted in charged results (posts + comments + profiles). Respected exactly. Empty = no global cap.

## `searchSort` (type: `string`):

How search results are ordered. Comment searches use Relevance, Top or New (Hot and Most comments fall back to Relevance).

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

Used by the Top and Controversial subreddit sorts and by searches (comment search: with the New sort only).

## `postedAfter` (type: `string`):

Only items created after this date (2026-09-01, or relative: 7 days). Applies to posts, user history and listing URLs.

## `postedBefore` (type: `string`):

Only items created before this date.

## `commentsPostedAfter` (type: `string`):

Only comments written after this date (2026-10-01, or 12 hours), in threads and user histories. The tree is still walked, so a new reply under an old comment is found (reading stops after 10,000 comments in a row outside your dates); only matching comments are saved and charged.

## `commentsPostedBefore` (type: `string`):

Only comments written before this date.

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

Include posts marked NSFW (18+). Off by default.

## `excludeKeywords` (type: `array`):

Drop every post whose title or text contains one of these words or phrases, one per line (whole words, case and accents ignored; a comma belongs to the phrase, as in 10,000 views). Dropped items are not charged. Comment trees are not filtered; comments found by comment search are.

## `aiAnalysis` (type: `boolean`):

Adds aiAnalysis to every post and comment: language, sentiment and score (-1 to 1), emotion, intent (question, recommendation request, complaint, praise, purchase intent, comparison…), category, topics, named brands, products and people, a one-sentence English summary, the pain point, and business signals (wants help, buying signal, mentions a price, feature request, vendor). Search results also get a relevance score (0 to 1) against your query. Charged once per post or comment analyzed in full; deleted, removed, bot or empty records and failed analyses are free. Works with the items output format.

## `aiLabels` (type: `object`):

Up to 5 yes/no labels of your own, as {"label_name": "what makes it true"}. Each analyzed record gets labels: {label_name: true or false}. Example: {"switching": "The author wants to switch from one product to another", "budget": "The author states a budget"}. Included in the analysis price.

## `onlyNew` (type: `boolean`):

Remember what earlier runs of the same watch returned and output only new posts and new comments (with Include comments, also comments that earlier runs did not return under posts already seen; with Max comments per post, each run adds up to that many of them per thread, oldest included). Nothing already delivered is charged again, even after a run that timed out, was aborted or overlapped another. One run per watch at a time: a second one does nothing and charges nothing. Memory: key-value store quarra-reddit-watch-\<this Actor's ID, lowercase> of your account (a watch already kept in quarra-reddit-watch stays there). Set a watch name, then schedule the Actor.

## `watchName` (type: `string`):

Name of this watch's memory for 'Only new'. Recommended: runs with the same name share it even when you add or remove sources. Empty: the memory belongs to this exact set of inputs and filters, so adding a source starts a new watch that returns everything again (limits, output format and proxy don't count).

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

Connection. Keep the default (automatic). Costs are included in the price.

## Actor input object example

```json
{
  "commentSearchQueries": [
    "home assistant"
  ],
  "strictSearch": false,
  "strictMatchIn": "titleOrText",
  "maxPostsPerSource": 20,
  "searchSort": "relevance",
  "timeFilter": "all",
  "includeNsfw": false,
  "aiAnalysis": false,
  "onlyNew": false,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}
```

# Actor output Schema

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

Every record: posts, comments, profiles, communities and Markdown threads, each with a type field.

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

Posts only (type post).

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

Comments with parentId, depth and rootCommentId (type comment).

## `threads` (type: `string`):

With outputFormat threadMarkdown: one record per post with its whole comment tree as Markdown.

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

Per-input status, errors, posts dropped by filters, per-thread completeness and watch statistics.

# 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 = {
    "commentSearchQueries": [
        "home assistant"
    ],
    "maxPostsPerSource": 20,
    "proxyConfiguration": {
        "useApifyProxy": true
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("quarra/reddit-comments-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 = {
    "commentSearchQueries": ["home assistant"],
    "maxPostsPerSource": 20,
    "proxyConfiguration": { "useApifyProxy": True },
}

# Run the Actor and wait for it to finish
run = client.actor("quarra/reddit-comments-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 '{
  "commentSearchQueries": [
    "home assistant"
  ],
  "maxPostsPerSource": 20,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}' |
apify call quarra/reddit-comments-search-scraper --silent --output-dataset

```

## MCP server setup

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