# Reddit Scraper — Subreddit Posts & Comments, No API Key (`blackfalcondata/reddit-scraper`) Actor

Reddit comments scraper and subreddit scraper in one: collect posts & comments with full nested threads — or search any subreddit or keyword across posts, comments and communities. JSON with text, HTML and Markdown. $1.25 per 1,000 results; no login or developer token needed.

- **URL**: https://apify.com/blackfalcondata/reddit-scraper.md
- **Developed by:** [Black Falcon Data](https://apify.com/blackfalcondata) (community)
- **Categories:** Social media, Lead generation, Automation
- **Features:** Limited permissions
- **Stats:** 122 total users, 45 monthly users, 95.3% runs succeeded, 3 bookmarks
- **User rating**: 5.00 out of 5 stars

## Pricing

from $1.25 / 1,000 results

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.

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

### What does Reddit Scraper do?

Reddit Scraper is a subreddit scraper and Reddit comments scraper in one actor. Collect posts & comments from any public reddit.com subreddit or thread with no API key. It also returns search results across posts, comments and communities. Point it at any subreddit, post, or search term and get structured records in clean, AI-ready formats. Each record carries text, HTML, and Markdown bodies, scores, vote ratios, awards, engagement analytics, authors, timestamps, and extracted links. No Reddit account, API key, or login required — and none of the official Reddit API's OAuth setup or 600-requests-per-10-minutes quota. Pricing is a flat $1.25 per 1,000 results plus a $0.005 start fee, with no volume tier to unlock. Every record is a post, a comment, a user, or a community. Multi-subreddit runs split the result budget across your inputs, so no start URL comes back empty.

> **Related Reddit actors** - same platform, one tool per job:
>
> - [Reddit Lead Scraper](https://apify.com/blackfalcondata/reddit-lead-scraper?fpr=1h3gvi) — B2B leads: only records with an email, social profile or website.
> - [Reddit Email Scraper](https://apify.com/blackfalcondata/reddit-email-scraper?fpr=1h3gvi) — email addresses and contact details from posts, comments and profiles.
> - [Reddit Mention Monitor](https://apify.com/blackfalcondata/reddit-mention-monitor?fpr=1h3gvi) — brand, product and keyword mention tracking.
> - [Reddit Sentiment Scraper](https://apify.com/blackfalcondata/reddit-sentiment-scraper?fpr=1h3gvi) — sentiment-scored posts and comments.
> - [Reddit RAG Dataset](https://apify.com/blackfalcondata/reddit-rag-dataset?fpr=1h3gvi) — chunk-ready LLM/RAG datasets from threads.

### How to use this actor

- 👉 **Register for a free Apify account** — no credit card required.
- 🎉 Just click **[Sign up free on Apify →](https://console.apify.com/sign-up?fpr=1h3gvi)** and complete a quick signup.
- 💰 A free Apify account includes $5 in monthly credits — enough to test this actor.
- ⏳ Scrape during the free trial, with no commitment or upfront payment required.

### Key features

- **🧵 Deep comment threads** — capture discussions beyond top-level replies: nested comments with parent/child IDs, depth, score, and awards, up to the comment and depth limits you set. Optionally expand collapsed and low-score branches for deeper coverage.
- **🤖 AI-ready output** — every post and comment body is emitted as clean text, HTML, and Markdown, so you can pipe threads straight into LLMs, RAG datasets, and MCP tools without extra cleanup.
- **🗂️ Structured multi-type output** — posts, comment threads, and community records come out of a single run, each tagged with `itemType` so downstream pipelines can split them cleanly.
- **🔎 Search and subreddit feeds** — pull a subreddit's feed, or run keyword searches with hot / top / new / relevance sorting — across all of Reddit or scoped to one subreddit with `searchCommunity`. Post search returns discovery records plus their comments; comment and community search return direct records. Subreddit feeds also support time windows from the past hour through all-time.
- **🚀 Maximize coverage mode** — Reddit shows only about 1,000 posts per listing. The `maximizeCoverage` toggle traverses several sort orders (hot, new, top) and de-duplicates by post ID to reach posts a single listing can't expose.
- **📊 Engagement analytics built in** — every post and comment ships with computed `ageHours`, `scorePerHour`, `engagementTotal`, `commentToScoreRatio` and word counts, so you can rank and threshold discussions without post-processing.
- **💭 Opt-in sentiment scoring** — a fast lexicon model labels every text-bearing record positive / negative / neutral with a confidence score; enable it with one toggle when you need it.
- **🔗 Link & social extraction** — outbound links, social handles, and email addresses mentioned in post and comment bodies are pulled into structured `extractedUrls`, `socialProfiles`, and `emails` fields automatically.
- **🔞 NSFW & date windows** — include or exclude 18+ content with one toggle, and keep posts and comments inside exact from/to date windows (`postDateFrom`/`postDateTo`, `commentDateFrom`/`commentDateTo`) so scheduled runs stay focused.
- **🧹 Lean, flexible output** — choose a single description format (text, HTML, or Markdown) and strip empty fields to keep datasets small for downstream pipelines.
- **🔑 No login or API key required** — point the actor at any public Reddit URL or search term and run; no Reddit account, OAuth app, or official-API rate limits involved.

### What data can you extract from reddit.com?

Every record carries a stable `itemType` (`post`, `comment`, or `community`), so you can tell the three content types apart inside a single dataset.

- **Posts** — `title`, body as text / HTML / Markdown, `score`, `upvoteRatio`, `numComments`, `awardCount`, award metadata, `author`, `community`, `domain`, `postType`, media previews and metadata (`thumbnail`, `thumbnailWidth`, `thumbnailHeight`, `previewImages`, `mediaSources`, `postHint`, `urlOverriddenByDest`, `mediaEmbed`, `secureMediaEmbed`, `media`, `secureMedia`, `isVideo`, `isRedditMediaDomain`, `mediaOnly`, `isGallery`, `galleryData`, `mediaMetadata`), engagement analytics computed at scrape time (`ageHours`, `scorePerHour`, `commentsPerHour`, `engagementTotal`, `commentToScoreRatio`, `titleLength`, `bodyLength`, `wordCount`), the post-type flags `isAma` (Ask-Me-Anything post) and `isGame` (interactive game post), `devvitAppName` / `devvitAppSlug` for interactive posts built with a Reddit app (e.g. `Pixelary` / `pixelary-game`), `language`, `createdAt`, and the canonical post `url`.
- **Comments** — threaded, with `postId`, `parentId`, `parentUrl`, `replyUrl`, `contentType`, and `depth` so you can rebuild the tree, plus `score`, `awardCount`, `author`, `createdAt`, the commenter's `authorAvatar`, `isOp` (comment by the post author), `aiDeclarations`, the comment-state flags `isCollapsed`, `isAuthorDeleted`, `isCommentDeleted`, `isModDistinguished`, the paid-award flags `hasPaidAward` and `isAwardHighlighted` (null on search and profile comments, which do not expose them), and the comment-side analytics (`ageHours`, `scorePerHour`, `bodyLength`, `wordCount`).
- **Communities** — `name`, display `title`, `url`, and `nsfw` flag, returned by community search. Subscriber counts, descriptions, and creation dates are not currently returned.

An optional lexicon **sentiment** score (label + confidence) can be switched on for every text-bearing record with the `sentiment` toggle.

The full post fields above come from subreddit-feed scraping. Media fields (`thumbnail`, `previewImages`, `mediaSources`, `isGallery`) and the post-state flags (`stickied`, `locked`, `archived`, `spoiler`, `isHighlighted`) are read from the post card; the remaining media and moderation fields (`postHint`, `mediaEmbed`, `isVideo`, `galleryData`, `pinned`, `edited`, and similar) are returned as `null` because the public post feed does not carry them. Posts surfaced by keyword **search** are discovery records with verified `id`, `url`, `title`, `subreddit`, `community`, `communityId`, `author`, `authorId`, `createdAt`, `score`, `numComments`, and `nsfw`, plus their comment threads unless you skip comments. Comment and community search return direct `comment` / `community` records. Full post bodies and media come from subreddit-feed scraping; a bare post URL returns that discussion's comment thread, not the post's own title/body.

Post and comment text is also mined for outbound links, social handles, and email addresses, exposed as structured `extractedUrls`, `socialProfiles`, and `emails` fields. Fields stay consistent across runs — unavailable values are returned as `null`, stable empty arrays, or stable empty objects rather than dropped, unless you enable `excludeEmptyFields` to slim the payload.

### Input

The main inputs are a search keyword and a result limit. Additional filters and options are available in the input schema.

Key parameters:

- **`startUrls`** — Reddit URLs to scrape — subreddits, post pages, or search result pages. Each URL determines what type of content is fetched: a subreddit URL scrapes its post feed, a post URL scrapes that discussion's comment thread. User profile and community "about" URLs are accepted but currently return limited or no data. Use the full link that includes the subreddit (reddit.com/r/<community>/... , any subdomain works). Links that do not name the community — redd.it short links, /r/<community>/s/... share links, and post links without the community (reddit.com/comments/...) — are now resolved to their post and scraped like any other post URL. A link that cannot be resolved is skipped, as are non-Reddit URLs; the run log and the final status message say how many were skipped.
- **`searchTerms`** — Search Reddit for these terms. Each entry becomes an independent search for the selected result type.
- **`searchCommunity`** — Restrict all Search Terms to one subreddit (e.g. "programming" or "r/programming"). Post results are strictly filtered to that community; comment and community searches follow Reddit's own scoping. Leave blank to search all of Reddit.
- **`searchType`** — Reddit search result type. Posts return discovery records plus their comment threads; comments and communities return their own records directly. User search is not exposed because Reddit does not currently provide a stable public result structure for it. (default: `"posts"`)
- **`sort`** — Sort order for results. Post and community search support every option; comment search supports Relevance, Top and New (Hot or Most Comments fall back to Relevance, and the run log says so). Subreddit feeds support Hot, New and Top — choosing Relevance or Most Comments for a subreddit falls back to Hot (the feed has no such order), and the run log says so. (default: `"hot"`)
- **`time`** — Restrict subreddit-feed results to a time window (applies to Top sort on feeds; search is not time-windowed). (default: `"all"`)
- **`includeNSFW`** — Include posts and communities marked as NSFW (18+). (default: `false`)
- **`postDateFrom`** — Keep only posts created at or after this ISO-8601 date (e.g. "2024-01-01"). Applies wherever the post carries a timestamp (feeds, post URLs, dated search results). Leave blank for no lower bound.
- **`postDateTo`** — Keep only posts created at or before this ISO-8601 date (e.g. "2024-06-30"). Combine with Posts From Date for an exact window. Leave blank for no upper bound.
- **`commentDateFrom`** — Keep only comments created at or after this ISO-8601 date. Blank means comments of any age are collected.
- **`commentDateTo`** — Keep only comments created at or before this ISO-8601 date. Blank disables the upper comment bound.
- **`postDateLimit`** — Legacy alias of Posts From Date — Posts From Date wins when both are set. Skip posts older than this ISO-8601 date (e.g. "2024-01-01").
- ...and 14 more parameters

### Input examples

**Scrape a subreddit feed** — Pull recent posts and their comment threads from any subreddit.

→ Posts from r/programming, each followed by its nested comments.

```json
{
  "startUrls": [
    {
      "url": "https://www.reddit.com/r/programming/"
    }
  ],
  "sort": "hot",
  "maxItems": 100,
  "maxComments": 200
}
```

**Search Reddit by keyword** — Run one or more keyword searches with sorting. Results are lightweight discovery records (plus their comments); scrape a result's URL for its full post fields.

→ Matching posts sorted by top score, each followed by its comments.

```json
{
  "searchTerms": [
    "mechanical keyboards",
    "ergonomic mice"
  ],
  "searchType": "posts",
  "sort": "top",
  "maxItems": 200
}
```

**Search Reddit comments** — Search matching comments directly when you need discussion snippets instead of full post threads.

→ Comment records with body text, thread URL, score, author, timestamp, and parent metadata when available.

```json
{
  "searchTerms": [
    "postgres"
  ],
  "searchType": "comments",
  "sort": "relevance",
  "maxItems": 25
}
```

**Search Reddit communities** — Find subreddits that match a topic or niche.

→ Community records with name, title, URL, and NSFW flag.

```json
{
  "searchTerms": [
    "programming"
  ],
  "searchType": "communities",
  "sort": "relevance",
  "maxItems": 25
}
```

**Get one post with its full thread** — Point at a single post URL to capture its comment tree (up to the limits you set), including collapsed replies.

→ The post's full comment thread, up to the configured limits, with parent/child IDs and depth.

```json
{
  "startUrls": [
    {
      "url": "https://www.reddit.com/r/programming/comments/1abc234/what_makes_a_codebase_pleasant_to_work_in/"
    }
  ],
  "includeCollapsed": true,
  "commentDepth": 10,
  "maxComments": 500
}
```

**Posts only — skip comments** — Collect just the posts from a subreddit without fetching comment threads.

→ Post records only — faster and cheaper when you don't need discussions.

```json
{
  "startUrls": [
    {
      "url": "https://www.reddit.com/r/technology/"
    }
  ],
  "skipComments": true,
  "maxItems": 250
}
```

### Output

Each run produces a dataset of structured Reddit records. Results can be downloaded as JSON, CSV, or Excel from the Dataset tab in Apify Console.

### Example Reddit record

```json
{
  "itemType": "post",
  "id": "t3_1usba50",
  "url": "https://www.reddit.com/r/EarthPorn/comments/1usba50/vancouver_island_british_columbia_canada/",
  "title": "Vancouver Island, British Columbia, Canada (7008x4672)(OC)",
  "contentHref": "https://i.redd.it/18mzqwtegbch1.jpeg",
  "domain": "i.redd.it",
  "postType": "image",
  "language": "en",
  "score": 952,
  "upvoteRatio": 0.9937565036420395,
  "numComments": 8,
  "awardCount": 0,
  "author": "northernhiker94",
  "authorId": "t2_asbqzjy",
  "community": "r/EarthPorn",
  "communityId": "t5_2sbq3",
  "createdAt": "2026-07-10T02:49:12.609000+0000",
  "icon": "https://www.redditstatic.com/avatars/defaults/v2/avatar_default_6.png",
  "isAwardable": true,
  "isEmbeddable": true,
  "isEmbed": false,
  "isLinkPost": false,
  "isNotBrandSafe": false,
  "thumbnail": "https://preview.redd.it/vancouver-island-british-columbia-canada-7008x4672-v0-18mzqwtegbch1.jpeg?width=640&crop=smart&auto=webp&s=5b0dda4169f0288bee8252c9099b5558b338853d",
  "previewImages": [
    {
      "url": "https://preview.redd.it/vancouver-island-british-columbia-canada-7008x4672-v0-18mzqwtegbch1.jpeg?width=640&crop=smart&auto=webp&s=5b0dda4169f0288bee8252c9099b5558b338853d",
      "width": 640,
      "height": 426
    },
    {
      "url": "https://preview.redd.it/vancouver-island-british-columbia-canada-7008x4672-v0-18mzqwtegbch1.jpeg?width=320&crop=smart&auto=webp&s=72ee055f734b0b68d9b48f4f36aac1a3d112d4c6",
      "width": 320,
      "height": 426
    },
    {
      "url": "https://preview.redd.it/vancouver-island-british-columbia-canada-7008x4672-v0-18mzqwtegbch1.jpeg?width=1080&crop=smart&auto=webp&s=2d983832b12d2c9b6af151a19b8b9dd514d6c04e",
      "width": 1080,
      "height": 426
    },
    {
      "url": "https://i.redd.it/18mzqwtegbch1.jpeg"
    }
  ],
  "isGallery": false,
  "nsfw": false
}
```

### Example comment record

```json
{
  "itemType": "comment",
  "id": "t1_ookwxid",
  "url": "https://www.reddit.com/r/programming/comments/1tqwksq/comment/ookwxid/",
  "postId": "t3_1tqwksq",
  "replyUrl": "https://www.reddit.com/r/programming/comments/1tqwksq/comment/ookwxid/",
  "depth": 0,
  "contentType": "text",
  "body": "When is everyone going to agree that the javascript ecosystem is complete garbage?",
  "bodyHtml": "\n        <div id=\"t1_ookwxid-post-rtjson-content\" class=\"py-0 xs:mx-xs mx-2xs max-w-full scalable-text [--emote-size:20px]\" dir=\"auto\">\n      <p dir=\"auto\">\n      When is everyone going to agree that...",
  "score": 27,
  "author": "wildjokers",
  "awardCount": 0,
  "createdAt": "2026-05-29T14:48:19.159000+0000",
  "description": "When is everyone going to agree that the javascript ecosystem is complete garbage?",
  "descriptionText": "When is everyone going to agree that the javascript ecosystem is complete garbage?",
  "descriptionHtml": "\n        <div id=\"t1_ookwxid-post-rtjson-content\" class=\"py-0 xs:mx-xs mx-2xs max-w-full scalable-text [--emote-size:20px]\" dir=\"auto\">\n      <p dir=\"auto\">\n      When is everyone going to agree that...",
  "descriptionMarkdown": "When is everyone going to agree that the javascript ecosystem is complete garbage?"
}
```

### Example community record

```json
{
  "itemType": "community",
  "id": "t5_2fwo",
  "name": "programming",
  "title": "programming",
  "url": "https://www.reddit.com/r/programming/",
  "nsfw": false
}
```

### How to scrape reddit.com

1. Go to [Reddit Scraper](https://apify.com/blackfalcondata/reddit-scraper?fpr=1h3gvi) in Apify Console.
2. Enter a search keyword.
3. Set `maxItems` to control how many results you need.
4. Click **Start** and wait for the run to finish.
5. Export the dataset as JSON, CSV, or Excel.

### Use cases

- Build training and RAG datasets from real Reddit discussions, with full comment context in Markdown.
- Monitor brand, product, or competitor mentions across subreddits and surface the threads driving them.
- Track sentiment and emerging topics in niche communities over time with scheduled runs.
- Power market and audience research with authentic user opinions, questions, and pain points.
- Feed structured Reddit threads into AI agents, MCP tools, and automation pipelines.
- Generate leads by extracting outbound links and social handles shared in relevant threads.
- Archive a subreddit or discussion thread for research or record-keeping.
- Export clean post and comment data to dashboards, spreadsheets, or data warehouses.

### How much does it cost to scrape reddit.com?

Reddit Scraper uses [pay-per-event](https://docs.apify.com/platform/actors/paid-actors/pay-per-event) pricing. You pay a small fee when the run starts and then for each result that is actually produced.

- **Run start:** $0.005 per run
- **Per result:** $0.00125 per Reddit record

Example costs:

- 10 results: **$0.018**
- 25 results: **$0.036**
- 100 results: **$0.13**
- 200 results: **$0.26**
- 500 results: **$0.63**

> **Platform usage is billed on top of these prices.** The figures above are Apify event fees only. Compute units and proxy traffic are billed separately by Apify at your actual consumption, and for proxy- or browser-heavy workloads they can exceed the event fees. What you actually pay depends on your own input — how many results you request and the run memory you choose — so it cannot be stated as a fixed figure here. Every run reports its exact platform usage on the run detail page.
>
> The **Actor Start** event is charged once per GB of run memory (minimum one), so a run configured with 2 GB is charged two start events rather than one.

### FAQ

#### How many results can I get from reddit.com?

The number of results depends on the search query and available Reddits on reddit.com. Use the `maxItems` parameter to control how many results are returned per run.

#### Can I integrate Reddit Scraper with other apps?

Yes. Reddit Scraper works with Apify's [integrations](https://apify.com/integrations?fpr=1h3gvi) to connect with tools like Zapier, Make, Google Sheets, Slack, and more. You can also use webhooks to trigger actions when a run completes.

#### Can I use Reddit Scraper with the Apify API?

Yes. You can start runs, manage inputs, and retrieve results programmatically through the [Apify API](https://docs.apify.com/api/v2). Client libraries are available for JavaScript, Python, and other languages.

#### Can I use Reddit Scraper through an MCP Server?

Yes. Apify provides an [MCP Server](https://apify.com/apify/actors-mcp-server?fpr=1h3gvi) that lets AI assistants and agents call this actor directly. Use a single `descriptionFormat` and `excludeEmptyFields` to keep payloads manageable for LLM context windows.

#### Is it legal to scrape reddit.com?

This actor extracts publicly available data from reddit.com. Web scraping of public information is generally considered legal, but you should always review the target site's terms of service and ensure your use case complies with applicable laws and regulations, including GDPR where relevant.

#### Your feedback

If you have questions, need a feature, or found a bug, please [open an issue](https://apify.com/blackfalcondata/reddit-scraper/issues?fpr=1h3gvi) on the actor's page in Apify Console. Your feedback helps us improve.

### You might also like

- [Bluesky Scraper - Posts, Search and Profile Feeds](https://apify.com/blackfalcondata/bsky-app-scraper?fpr=1h3gvi) — Scrape Bluesky posts by keyword search, @handle or profile URL. Each post includes its full text.
- [Douyin Hot Board Scraper — Trending Topics & Heat](https://apify.com/blackfalcondata/douyin-com-scraper?fpr=1h3gvi) — Scrape Douyin — the live hot board (抖音热榜) and rising topics as structured JSON: rank, heat score,.
- [Facebook Ad Library Scraper \[💰$0.05/1k\] — Ads & EU Reach](https://apify.com/blackfalcondata/facebook-ads-library-scraper?fpr=1h3gvi) — Scrape facebook.com/ads/library by keyword or advertiser: ad copy, image and video URLs, landing.
- [Facebook Group Scraper — Posts, Comments & Engagement](https://apify.com/blackfalcondata/facebook-group-post-scraper?fpr=1h3gvi) — Scrape facebook.com — post text & timestamps · reaction/comment/share counts · media & optional.
- [Instagram Profile Scraper 💰 $1/1K — Followers, Bio & Contact](https://apify.com/blackfalcondata/instagram-profile-scraper?fpr=1h3gvi) — 💰 $1 per 1,000 profile results. Look up public Instagram accounts by username or profile URL to.
- [Loom Video Scraper — Transcripts & Metadata](https://apify.com/blackfalcondata/loom-com-scraper?fpr=1h3gvi) — Scrape Loom videos from share or embed URLs or from 32-character video IDs. Every row carries the.
- [Maigret Username OSINT Scraper — cross-site handle search](https://apify.com/blackfalcondata/maigret-username-osint-scraper?fpr=1h3gvi) — Search usernames and get public profile URLs, confidence scores and per-username dossiers. Check.
- [Meta Ads Library Scraper \[💰$0.05/1k\]](https://apify.com/blackfalcondata/meta-ads-library-scraper?fpr=1h3gvi) — Scrape Meta's Ad Library across Facebook, Instagram, WhatsApp, Threads, Messenger and Audience.
- [Reddit Mention Monitor — Track Brand & Keyword Mentions](https://apify.com/blackfalcondata/reddit-mention-monitor?fpr=1h3gvi) — Monitor reddit.com for mentions of your brand, product or any keyword; returns only matching posts and comments with thread context.

### Getting started with Apify

New to Apify? [Create a free account with $5 credit](https://console.apify.com/sign-up?fpr=1h3gvi) — no credit card required.

1. Sign up — $5 platform credit included
2. Open this actor and configure your input
3. Click **Start** — export results as JSON, CSV, or Excel

Need more later? [See Apify pricing](https://apify.com/pricing?fpr=1h3gvi).

### Disclaimer

This actor accesses only publicly available data on reddit.com. You are responsible for how you use the extracted data — in particular any personal information such as names, phone numbers, or email addresses — and for complying with Reddit's terms of use, applicable data-protection law (including the GDPR where it applies), and the anti-spam rules of your jurisdiction.

This actor is an independent tool and is not affiliated with, endorsed by, or sponsored by Reddit or any of its subsidiaries. All trademarks mentioned are the property of their respective owners.

### Search keywords

reddit scraper, reddit api, apify reddit, reddit data extraction, reddit.com scraper, reddit.com data, reddit.com api, social media scraper, profile data.

# Changelog

This Actor's version history is a separate document: https://apify.com/blackfalcondata/reddit-scraper/changelog.md

# Actor input Schema

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

Reddit URLs to scrape — subreddits, post pages, or search result pages. Each URL determines what type of content is fetched: a subreddit URL scrapes its post feed, a post URL scrapes that discussion's comment thread. User profile and community "about" URLs are accepted but currently return limited or no data. Use the full link that includes the subreddit (reddit.com/r/<community>/... , any subdomain works). Links that do not name the community — redd.it short links, /r/<community>/s/... share links, and post links without the community (reddit.com/comments/...) — are now resolved to their post and scraped like any other post URL. A link that cannot be resolved is skipped, as are non-Reddit URLs; the run log and the final status message say how many were skipped.

## `searchTerms` (type: `array`):

Search Reddit for these terms. Each entry becomes an independent search for the selected result type.

## `searchCommunity` (type: `string`):

Restrict all Search Terms to one subreddit (e.g. "programming" or "r/programming"). Post results are strictly filtered to that community; comment and community searches follow Reddit's own scoping. Leave blank to search all of Reddit.

## `searchType` (type: `string`):

Reddit search result type. Posts return discovery records plus their comment threads; comments and communities return their own records directly. User search is not exposed because Reddit does not currently provide a stable public result structure for it.

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

Sort order for results. Post and community search support every option; comment search supports Relevance, Top and New (Hot or Most Comments fall back to Relevance, and the run log says so). Subreddit feeds support Hot, New and Top — choosing Relevance or Most Comments for a subreddit falls back to Hot (the feed has no such order), and the run log says so.

## `time` (type: `string`):

Restrict subreddit-feed results to a time window (applies to Top sort on feeds; search is not time-windowed).

## `includeNSFW` (type: `boolean`):

Include posts and communities marked as NSFW (18+).

## `postDateFrom` (type: `string`):

Keep only posts created at or after this ISO-8601 date (e.g. "2024-01-01"). Applies wherever the post carries a timestamp (feeds, post URLs, dated search results). Leave blank for no lower bound.

## `postDateTo` (type: `string`):

Keep only posts created at or before this ISO-8601 date (e.g. "2024-06-30"). Combine with Posts From Date for an exact window. Leave blank for no upper bound.

## `commentDateFrom` (type: `string`):

Keep only comments created at or after this ISO-8601 date. Blank means comments of any age are collected.

## `commentDateTo` (type: `string`):

Keep only comments created at or before this ISO-8601 date. Blank disables the upper comment bound.

## `postDateLimit` (type: `string`):

Legacy alias of Posts From Date — Posts From Date wins when both are set. Skip posts older than this ISO-8601 date (e.g. "2024-01-01").

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

Maximum total records to save across all sources (posts, comments, communities).

## `maxPosts` (type: `integer`):

Maximum number of post records across the whole run. Leave empty for no post cap. Max Items stays the hard total for all records, so a run that should return many posts with their comments needs Max Items (or Max Results) raised to make room: for example 50 posts with up to 20 comments each needs Max Items of at least 1,050.

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

Subreddit feeds only: traverse several sort orders (your selected sort, then hot, new and top) and de-duplicate by post ID, reaching posts a single listing cannot expose. Reddit shows roughly 1,000 posts per listing; this pushes past that window at the cost of extra page fetches. Set Max Items accordingly.

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

Maximum number of comments to collect from each post page.

## `includeCollapsed` (type: `boolean`):

Expand and include comments that are initially collapsed (controversial or low-score). Enables deeper thread coverage, up to the comment and depth limits you set.

## `commentDepth` (type: `integer`):

Maximum reply nesting depth to collect (1 = top-level only).

## `skipComments` (type: `boolean`):

Do not collect comments from post pages — output posts only.

## `descriptionFormat` (type: `string`):

Controls which body/description fields are included in output. "all" emits text + HTML + markdown variants.

## `sentiment` (type: `boolean`):

Score the body text of every post and comment with a fast lexicon sentiment model. Adds a "sentiment" object (score, label, confidence) to each record; off by default to keep records lean.

## `excludeEmptyFields` (type: `boolean`):

Strip null and empty fields from output records to reduce payload size.

## `includeRunMetadata` (type: `boolean`):

Append a single run-summary record at the end of the dataset (run ID, timing, item counts). It is marked itemType="runMetadata" and is added in addition to your matching records — filter on itemType to exclude it.

## `appConnector` (type: `string`):

Optional. Pick a connected app under Settings → API & Integrations to receive your scraped Reddit results. Notion is supported today (a run-summary page); other MCP connectors are best-effort as Apify expands its catalog.

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

Alias for Max Items: maximum total records to save across all sources. When both limits are supplied, this value takes precedence. Set to 0 for the actor's supported maximum.

## `query` (type: `string`):

Reddit search keywords. This is a single-term alias for Search Terms.

## Actor input object example

```json
{
  "startUrls": [
    {
      "url": "https://www.reddit.com/r/programming/"
    }
  ],
  "searchTerms": [],
  "searchType": "posts",
  "sort": "hot",
  "time": "all",
  "includeNSFW": false,
  "maxItems": 5,
  "maxPosts": 25,
  "maximizeCoverage": false,
  "maxComments": 200,
  "includeCollapsed": false,
  "commentDepth": 10,
  "skipComments": false,
  "descriptionFormat": "all",
  "sentiment": false,
  "excludeEmptyFields": false,
  "includeRunMetadata": false,
  "maxResults": 100
}
```

# Actor output Schema

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

No description

# 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 = {
    "startUrls": [
        {
            "url": "https://www.reddit.com/r/programming/"
        }
    ],
    "searchTerms": [],
    "maxItems": 5,
    "maxPosts": 25,
    "maximizeCoverage": false,
    "includeCollapsed": false,
    "descriptionFormat": "all",
    "sentiment": false,
    "excludeEmptyFields": false,
    "maxResults": 100
};

// Run the Actor and wait for it to finish
const run = await client.actor("blackfalcondata/reddit-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 = {
    "startUrls": [{ "url": "https://www.reddit.com/r/programming/" }],
    "searchTerms": [],
    "maxItems": 5,
    "maxPosts": 25,
    "maximizeCoverage": False,
    "includeCollapsed": False,
    "descriptionFormat": "all",
    "sentiment": False,
    "excludeEmptyFields": False,
    "maxResults": 100,
}

# Run the Actor and wait for it to finish
run = client.actor("blackfalcondata/reddit-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 '{
  "startUrls": [
    {
      "url": "https://www.reddit.com/r/programming/"
    }
  ],
  "searchTerms": [],
  "maxItems": 5,
  "maxPosts": 25,
  "maximizeCoverage": false,
  "includeCollapsed": false,
  "descriptionFormat": "all",
  "sentiment": false,
  "excludeEmptyFields": false,
  "maxResults": 100
}' |
apify call blackfalcondata/reddit-scraper --silent --output-dataset

```

## MCP server setup

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