Hacker News Scraper avatar

Hacker News Scraper

Pricing

from $1.00 / 1,000 item returneds

Go to Apify Store
Hacker News Scraper

Hacker News Scraper

Scrape Hacker News via the public Algolia HN Search API. Search stories, Show HN, Ask HN or comments by keyword, sort by relevance or date, filter by minimum points. Clean JSON output with title, URL, author, points, comments and HN item link. No key.

Pricing

from $1.00 / 1,000 item returneds

Rating

0.0

(0)

Developer

Dami's Studio

Dami's Studio

Maintained by Community

Actor stats

0

Bookmarked

1

Total users

0

Monthly active users

3 days ago

Last modified

Share

Scrape Hacker News via the public Algolia HN Search API — no API key, no login, no anti-bot. Search stories, Show HN, Ask HN, comments, or the current front page; sort by relevance or date; filter by minimum points.

What it does

  • Queries https://hn.algolia.com/api/v1/search (relevance) or search_by_date (newest first).
  • Paginates automatically until it has collected maxItems.
  • Returns clean, normalized JSON for each item (HTML stripped from story/comment text).
  • Deduplicates by Hacker News objectID.

Input

FieldTypeDefaultDescription
querystring"openai"Keywords to search for. Empty = newest/front-page items for the chosen tag.
tagsselectstorystory, show_hn, ask_hn, comment, or front_page.
sortByselectrelevancerelevance or date (newest first).
minPointsintegerOnly items with at least this many points.
maxItemsinteger50Max items to return (1–1000).
proxyConfigurationproxyoffOptional; the public API has no anti-bot, so no proxy is needed. Only enable it if you hit IP rate limits at very high volume.

front_page note: the front_page tag always returns the ~30 items currently on the HN front page (no keyword search). For topic searches use story/show_hn/ask_hn/comment instead.

Output

Each successful item:

{
"ok": true,
"objectId": "44159823",
"type": "story",
"title": "OpenAI ...",
"url": "https://example.com/article",
"author": "someuser",
"points": 412,
"numComments": 188,
"createdAt": "2026-06-01T12:34:56.000Z",
"text": "",
"hnUrl": "https://news.ycombinator.com/item?id=44159823"
}

For comments, type is comment, title/url reflect the parent story, and text is the (HTML-stripped) comment body.

Some fields can be null depending on the item: url (Ask HN/text posts and self-posts have no external link), points and numComments (often absent on comments), and text (empty string for link stories). title, author, objectId and hnUrl are present for well-formed items but defensively default to null if the API omits them.

On failure or no results, a single diagnostic row is emitted with ok:false and an errorCode (e.g. NO_RESULTS, RATE_LIMITED, NETWORK) — and nothing is charged.

Pricing

Pay-per-result: one charge per returned item (item event). Diagnostic/empty rows are never charged.