Metadata-Version: 2.4
Name: product-hunt-scraper-api
Version: 0.1.0
Summary: Product Hunt scraper API in Python. Pull ranked launches, names, slugs and URLs from Product Hunt as structured data.
Author: wordstotech
License: MIT
Project-URL: Homepage, https://www.scrapingbee.com/scrapers/product-hunt-scraper-api/
Project-URL: Documentation, https://www.scrapingbee.com/documentation/
Project-URL: Repository, https://github.com/ScrapingBee/product-hunt-scraper-api
Keywords: product-hunt-scraper,product-hunt-scraper-api,product-hunt-data-scraper,product-hunt-api,launch-tracking,startup-data,web-scraping-api,scraping-api,data-extraction,scrapingbee
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Internet :: WWW/HTTP
Requires-Python: >=3.8
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: requests>=2.25.0
Dynamic: license-file

# product-hunt-scraper-api

A **Product Hunt scraper** for Python, built on ScrapingBee's
[Product Hunt scraper API](https://www.scrapingbee.com/scrapers/product-hunt-scraper-api/). It
returns the ranked leaderboard as objects with rank, name, slug and URL.

Verified against the live site on 2026-08-25: the homepage returned 70 ranked products and
Auto-Mode charged **1 credit** for the call.

## Install

```bash
pip install product-hunt-scraper-api
```

## Today's launches

```python
from product_hunt_scraper_api import ProductHuntScraper

scraper = ProductHuntScraper("YOUR-API-KEY")

for product in scraper.leaderboard()[:10]:
    print(product.rank, product.name, product.url)
```

```
1 akta.pro https://www.producthunt.com/products/akta-pro
2 Diet Claude https://www.producthunt.com/products/diet-claude
3 Jotform AI Data Assistant https://www.producthunt.com/products/jotform
```

Key from [app.scrapingbee.com](https://app.scrapingbee.com/), 1,000 credits free.

## Why this costs 1 credit and not 25

Product Hunt public listing pages render their product links server-side. That means no headless
browser is needed, and the cheapest proxy tier is enough.

Rather than guessing that, the client sends `mode=auto`. ScrapingBee then tries configurations
from cheapest to most expensive and charges only for the one that returns the page. On the
homepage that settled at 1 credit. Confirm it yourself:

```python
products, charged = scraper.leaderboard_with_cost()
print(len(products), "products for", charged, "credits")
```

If a page ever hardens, Auto-Mode climbs on its own up to `max_cost` without a code change. Raise
the ceiling for a stubborn page:

```python
scraper.leaderboard(max_cost=75)
```

## What a Product object holds

Product Hunt uses Tailwind utility classes with no stable card identifier, so the dependable
anchor is the product link, `a[href^="/products/"]`. Its text carries the rank inline, as
`"1. akta.pro"`. The client splits that apart for you:

| Attribute | Value |
| --- | --- |
| `rank` | `1`, parsed from the link text |
| `name` | `"akta.pro"`, with the rank prefix stripped |
| `slug` | `"akta-pro"` |
| `url` | absolute `https://www.producthunt.com/products/akta-pro` |

`product.as_dict()` returns all four, ready for a dataframe or a JSON column.

## Tracking a topic

```python
for product in scraper.topic("developer-tools")[:10]:
    print(product.rank, product.name)
```

Any Product Hunt listing URL works through `leaderboard(url=...)`, so category, topic and
date-archive pages all behave the same way.

## Rolling your own parse

When the four fields are not enough, take the HTML and parse it yourself:

```python
html = scraper.page_html("https://www.producthunt.com/products/akta-pro")
```

`render_js=True` is available but rarely needed on listing pages, and it raises the floor from
1 credit to 5.

## Watching launch day

Product Hunt rankings move all day. A poll every 30 minutes at 1 credit is 48 credits a day,
which makes a full launch-day watch effectively free:

```python
import time

seen = {}
for _ in range(12):
    for product in scraper.leaderboard():
        previous = seen.get(product.slug)
        if previous and previous != product.rank:
            print(f"{product.name}: #{previous} -> #{product.rank}")
        seen[product.slug] = product.rank
    time.sleep(1800)
```

Check the balance first with `scraper.usage()`, which is free and capped at 6 calls a minute.

## Cost

| Call | Credits |
| --- | --- |
| Leaderboard via Auto-Mode | 1 observed |
| Same page forced to JavaScript rendering | 5 |
| Premium proxy with JavaScript | 25 |
| Failed request (HTTP 500) | 0 |

Tiers at [scrapingbee.com/pricing](https://www.scrapingbee.com/pricing/).

## Related scrapers

For adjacent launch and startup research the same key reaches
[Google search](https://www.scrapingbee.com/features/google/),
[Google News](https://www.scrapingbee.com/scrapers/google-news-scraper-api/) and
[AI extraction](https://www.scrapingbee.com/features/ai-web-scraping-api/), which is handy when a
page changes shape and you would rather describe fields than maintain selectors.

## Scope

Public, pre-login pages only. Scraping behind login credentials is prohibited by the
[ScrapingBee terms](https://www.scrapingbee.com/terms-and-conditions/). Keep API keys out of AI
coding assistants.

MIT licensed. [Repository](https://github.com/ScrapingBee/product-hunt-scraper-api) .
[extraction rules](https://www.scrapingbee.com/features/data-extraction/)
