Reddit Stream API
EN
Conceptual illustration, not a screenshot or measured result.

REDDIT STREAM API · JSON · REST

Process Reddit archive data in controlled batches

Plan a datasets archive batch with Reddit Stream API: inspect page two, save the response and choose a local restart point before scheduling more reads.

  • GET
  • JSON
  • HTTPS
  • UTC

Make your first authenticated request

Create an account, copy the key shown at the top of the account page, and put it in a server environment variable. The three examples below request the same small page. Inspect the HTTP status before using the JSON; keep credentials out of browser bundles, shared notebooks and request logs.

curl --get --fail-with-body 'https://api.redditstreamapi.com/v1/posts' \
  -H "Authorization: Bearer ${REDDIT_API_KEY}" \
  --data-urlencode 'subreddit=datasets' \
  --data-urlencode 'limit=3' \
  --data-urlencode 'page=2'

Read the response before building a table

This is an illustrative empty successful response, not a live query result. An empty page still costs one credit. Read data, pagination and credits separately; a total must always be interpreted with relation. The balance shown is an example after one eligible trial request.

{
  "data": [],
  "pagination": {
    "page": 2,
    "limit": 3,
    "total": null,
    "relation": "unknown",
    "has_more": false,
    "window_exhausted": false,
    "truncated": false
  },
  "credits": {
    "cost": 1,
    "balance": 4999
  }
}

Begin with a rehearsal you can inspect

Before putting an archive read on a schedule, give the worker one small job: request page two of datasets posts and account for what happens to that response. Three requested records are enough to inspect the handoff from HTTP to local storage. The useful result of this rehearsal is a decision about your next step, even when the archive returns no records.

Reddit Stream API provides read access to an independent historical Reddit archive. It is not an official Reddit service and is not affiliated with Reddit. Stream in the name does not mean live event delivery: the API offers discrete GET responses, not an SSE connection, WebSocket subscription or notification feed. Repeating a request is another archive read, not a way to subscribe to new Reddit activity.

Conceptual illustration, not a screenshot or measured result.

What the second page actually tests

02 / 05

Use GET https://api.redditstreamapi.com/v1/posts?subreddit=datasets&limit=3&page=2. subreddit=datasets restricts the community, limit=3 asks for at most three post records and page=2 requests the second page under those parameters. It does not request two pages at once or promise the next three posts in time. Datasets records may be absent or incomplete. Send X-API-Key: <key> or Authorization: Bearer <key> from your server; both are supported alternatives.

Synthetic response excerpt for demonstration only: {"data":[],"pagination":{"page":2,"limit":3,"total":null,"relation":"unknown"},"credits":{"cost":1,"balance":99}}. No real request produced it and the balance is fictional. An empty second page cannot establish a total of zero or the exact size of the matching set. This successful empty response still costs one credit; it is different from a transport failure or rejected key.

Conceptual illustration, not a screenshot or measured result.

Six routes, one read-only API contract

Choose the route for the object you need. Search selects posts and comments; posts and comments constrain the record kind. Item looks up a known id. Subreddits returns matching community names rather than a complete community dataset. Status is an uncharged service-scope response and does not test search availability.

MethodAPIUse
GET/v1/searchSearch posts and comments
GET/v1/postsPosts only
GET/v1/commentsComments only
GET/v1/itemOne known record id
GET/v1/subredditsCommunity names by prefix
GET/v1/statusService scope; no charge

Set the boundaries of a collection job

Combine ordinary text with an exact community and a UTC date window. Keep the nonsecret query parameters with the saved response. Limit controls the page size, page selects a bounded offset, and min_score is a filter rather than a sorting option. A page order is not a chronological or relevance ranking.

ParameterMeaning
qText in title and text
subredditExact community spelling
authorExact author value
kindpost or comment
from / toYYYY-MM-DD, UTC; end day included
min_scoreMinimum score, not sorting
limit / pageBoth range from 1 to 100
prefix / idRoute-specific name prefix or known id

Map observed fields deliberately

Inspect the actual objects before assuming a column exists. Keep omitted values, null and empty strings distinct. Relationship fields, when returned, may help with local grouping; they do not establish a complete thread. Preserve the raw response so a revised mapping can be tested without paying to fetch it again.

ParameterMeaning
idKeep the source identifier
kindInspect the record kind
subredditPreserve the returned community name
title / textTreat missing, null and empty separately
created_utc / scoreCheck numeric values before conversion
parent_id / link_idOptional links; group locally if present

Where this archive API fits

Use this service when your task starts with reading available historical records. A live feed, posting, editing, voting or a server-built thread requires a different integration. Direct page scraping and official Reddit access have their own behaviour and requirements; this endpoint does not impersonate either interface or promise their coverage.

UseResponse
Available historical recordsSupported read-only routes
Live feed and new activityNot provided
Publishing, editing and votingNot provided
Complete conversation treesNot provided; optional local grouping

Request costs you can account for

$5

Eligible new accounts, once across the network

$1

Per 1,000 successful requests, including empty results

$50

Minimum top-up for 50,000 credits

A successful retrieval costs one credit, including an empty result: $1 per 1,000 successes. Eligible new accounts receive $5 = 5,000 credits once across the network. The minimum paid top-up is $50 = 50,000 credits. Invalid requests are not charged; upstream failures refund the reservation, sometimes after reconciliation. A successful retry is a new paid retrieval, so rerun local transformations from saved inputs first.

Conceptual illustration, not a screenshot or measured result.

About the service and its limits

Reddit Stream API is an independent historical archive service, not an official Reddit product or a live mirror. Availability of a record, time range or optional field is not guaranteed. Record the scope and retrieval time of your own batch, review the terms and privacy information, and avoid presenting a bounded archive sample as all activity on Reddit. The account exposes request costs, statuses and available client details; older requests may lack IP or latency fields.

Continue with the reference and implementation guide

Questions before your first request

What is Reddit Stream API?

Reddit Stream API is an independent read-only service for retrieving available archived Reddit posts and comments as JSON. Authenticate with the key for this site and choose a documented search or lookup route. It is not official Reddit, live access or a complete export of a community.

How much does Reddit Stream API cost?

The price is $1 per 1,000 successful requests. The minimum top-up is $50 for 50,000 credits. Each successful request uses one credit, even when it returns no matching records. Invalid requests are not charged; upstream failures trigger a refund, which can require reconciliation. A timeout alone does not establish the final billing outcome.

How do I get an API key?

Create an account with email and password, or continue with Google in a popup. Eligible new accounts receive $5 (5,000 credits) once across this site network. Your API key is available at the top of the account after sign-in and is stored encrypted. Keep it on your server.

What should the batch job record before it starts?

Treat a run as a local work record with a purpose, filters and a request budget. For example, you want to inspect archived datasets posts created during a chosen calendar week. Write down that source period separately from the time the worker runs. Incremental processing here means advancing your own work in manageable steps; the archive supplies neither a live event subscription nor a durable offset.

What should the final handover explain?

At the end, report the filters used, pages attempted, responses retained, local failures and why the run stopped. Keep an empty response distinct from a missing response. Another engineer should be able to choose between repairing saved output, changing the next date window or making a new remote request without mistaking the log for a complete inventory of Reddit.

Which filters can I use to search Reddit records?

Use q for analyzed text search and combine it with subreddit, author, kind, from, to or min_score. Multiple search words use AND semantics; this is not a semantic-search or arbitrary-query-DSL endpoint. Dates use YYYY-MM-DD in UTC, with the to date including the whole day. Start with documented parameters in the reference.

Does Reddit Stream API provide live Reddit access?

No. This service reads a historical archive, not a live Reddit feed. It cannot publish posts, vote, send private messages or perform Reddit OAuth actions. The public /v1/status route describes the service scope; it does not prove archive health, complete coverage or current availability of an original Reddit page.

Can I export every record that matches a search?

Not necessarily. A request returns up to 100 records, and page ranges from 1 to 100. Read total together with pagination.relation: exact, lower bound or unknown. Results follow archive order rather than guaranteed chronological or relevance order. Reaching the last accessible page does not prove that a saved sample is exhaustive.

Can I reuse the same key on another domain?

No. Accounts, API keys and credit balances are separated by site. Use the key issued for this domain with its own HTTPS API hostname. Keep that key in server-side configuration, not in browser JavaScript, public repositories or shared logs. A key from another site is not a substitute for a local account. Google sign-in is shared across the network; API keys and balances remain separate for each site.

Which request should I try first?

Start with /v1/posts, q=pipeline, subreddit=dataengineering, limit=3 and page=1. This small request lets you inspect available fields before writing import or interface logic. It still costs one credit when successful, including an empty result. Adjust the topic and community for your task; the example is not a promise of a fixed record count.

When is another page worth requesting?

Use the homepage request as a rehearsal, not as an instruction to skip page one in a real collection. Page two is useful because it exposes an easy mistake: a request for the second page does not prove the first page was obtained. Record exactly which page you asked for. If you later change the filters, treat the result as a separate local task rather than extending the old page counter.

When can a local checkpoint move forward?

Consider a worker that received page two, saved the body, and then failed while producing local rows. On restart, inspect the saved body first and rerun the local transformation if appropriate. Do not advance solely because the HTTP call succeeded. If the body never reached storage, mark the outcome uncertain and decide explicitly whether to spend another request; reconstructing a response from a page number is not possible.

What can the inspected page actually prove?

Read total together with relation. eq is an exact query total, gte a lower bound and unknown unreliable or null. An empty deeper page does not establish a zero total. Neither exact counts, page traversal nor smaller date windows prove an exhaustive download. Preserve has_more and window_exhausted and stop at the supported page boundary; do not invent a cursor or bypass page 100 by making more identical calls.

How do I decide whether a failed request may be retried?

Handle HTTP 400 by correcting parameters, 401 by checking domain and key, 402 by pausing work and checking the account balance, and 429 with delayed bounded retries. Public /v1/status is free and keyless, but only confirms an HTTP response and static scope. It does not establish search health, archive freshness or whether an earlier uncertain retrieval consumed credit.

How do search, posts and comments differ?

Use /v1/search for the supported search across record kinds. /v1/posts and /v1/comments add a post or comment constraint. They share the documented search filters; /v1/item is the separate route for a known id. None of these routes creates, edits or deletes Reddit content.

How is this different from scraping Reddit pages?

You request structured historical records through the documented routes instead of downloading current HTML and extracting page elements. This avoids making your loader depend on page markup. It does not provide a live proxy, browser session, official OAuth compatibility or a promise of complete historical coverage.

Keep receipt and completion separate

03 / 05

Use two local states: response saved and processing complete. If parsing or writing transformed rows fails, a saved response gives you something concrete to inspect and replay. If no response was saved, you have an uncertain remote attempt instead. That distinction determines whether the next action is local work or another potentially charged archive read; a page counter alone cannot tell you.

Choose a source window, then a stopping point

04 / 05

Choose the creation-date window that answers your batch's question, and separately decide how many requests this run may attempt. A run timestamp describes your worker, not the age of the posts. When a budget or page boundary stops the job, retain that reason with the output. The guide develops this restart procedure; the documentation defines the parameters and the pricing page supplies the cost rules.

Content routes accept limit and page from 1 to 100, with one page per request. Date filters from and to use YYYY-MM-DD in UTC and apply to created_utc, not ingestion time; the final day is fully included. Date windows can organize historical work but cannot certify complete coverage. min_score filters a numeric threshold without sorting. Local sorting or deduplication cannot recover records that were never received.

Count reads before adding a schedule

05 / 05

Every successful retrieval costs one credit, including empty pages and successful repeats: $1 per 1000 requests. Invalid requests do not debit; upstream failures refund reservations. A timeout or disconnected client may follow a charged success. Another successful attempt costs another credit, and a failure in your own database does not cancel the charge. Handle 400, 401, 402 and 429 by cause and cap retries.