# Instagram Hashtag Scraper (`datahamster/instagram-hashtag-scraper`) Actor

Instagram hashtag scraper: get the reels Instagram lists for a hashtag with plays, views, likes, comments, caption, hashtags, upload date, duration, audio, video and thumbnail links. No login. Monitor mode returns each new reel once. Owners are named only for verified accounts.

- **URL**: https://apify.com/datahamster/instagram-hashtag-scraper.md
- **Developed by:** [Viktor Dubnytskiy](https://apify.com/datahamster) (community)
- **Categories:** Social media
- **Features:** Limited permissions
- **Stats:** 5 total users, 2 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.44 / 1,000 result items

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.
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

## Instagram Hashtag Scraper

Instagram Hashtag Scraper returns the reels Instagram shows for a hashtag, one row per reel, with plays, views, likes, comment count, caption, hashtags, upload date, duration, audio, video and thumbnail links. You give it hashtags such as `travel` or `#streetphotography`. No Instagram login, cookies or API key are needed.

**Try it:** the prefilled example returns 20 rows in about 45 to 75 seconds and costs about $0.037. Results cost $1.80 per 1,000.

**Coverage:** Instagram shows logged-out visitors a reel list only for hashtags it has a public topic page for. Many hashtags have one (travel, running, marketing, streetphotography), but on 05.11.2026 some very large ones did not (fitness, food, nike, ootd). Those hashtags return no rows and cost nothing. The list is ordered by popularity, not by date, and holds about 60 reels per hashtag (#travel: 60 on 05.11.2026).

### Why this one

- **Monitor mode for new reels.** Save a task, schedule it, and each run returns only reels the task has never seen under your hashtags, with a Telegram message or a webhook call when there are some. The leading Store hashtag scraper has no monitor mode and no alert inputs. Measured on 05.11.2026 for `travel` and `running`: the first run recorded 120 reels in 20 seconds and returned nothing, a repeat run read the same 120, found 0 new and took 23 seconds with $0.0004 of platform usage plus one $0.005 monitor-check. Likes and comments are fetched only for reels that are returned.
- **One row per reel across all your hashtags.** A reel listed under several of your hashtags is returned and charged once, under the first one. With 8 related hashtags (travel, traveling, travelgram, wanderlust, running, run, runner, runners) Instagram listed 420 reels, 48 of them repeats of a reel already listed; this actor returned 372 rows. The leader treats each hashtag as a separate search.
- **Lower price on most plans.** Results cost $1.80 per 1,000 reels on the free and Bronze plans, $1.62 on Silver and $1.44 on Gold and higher. The leading Store hashtag scraper charges $2.60, $2.30, $2.10, $1.90, $1.70 and $1.40 per 1,000 on Free, Bronze, Silver, Gold, Platinum and Diamond (05.11.2026), so on Diamond it is slightly cheaper. Its price includes platform usage; here usage is billed on top, about $0.04 to $0.06 per 1,000 reels with details and under $0.02 without.

### What you get

Real rows from the example dataset (`hashtags: ["travel", "running"]`, `maxPerHashtag: 10`):

| hashtag | rank | ownerUsername | shortcode | caption | playCount | likeCount | commentCount | createdAt |
|---|---|---|---|---|---|---|---|---|
| `travel` | `1` | `null` | `DTfS7SMEk8B` | "Switzerland all the year 🇨🇭🥹  Which one is your pr..." | `30251543` | `3285406` | `6236` | `2026-01-14T11:13:01Z` |
| `travel` | `2` | `null` | `DSI7LxnEbrb` | "Those were the best times" | `147562675` | `17871136` | `15146` | `2025-12-11T22:10:52Z` |
| `running` | `4` | `austinsley` | `DbHetziJ_Sm` | "Movement is the cure . . . #run #running #runner" | `607585` | `42323` | `204` | `2026-07-23T01:25:25Z` |
| `running` | `5` | `thefashionjogger` | `DeUljjzg_m7` | "If you RUN, you are a GREAT RUNNER 💪 No matter the..." | `901537` | `27047` | `285` | `2026-10-10T17:09:30Z` |

Full row: `id`, `url`, `hashtag`, `rank`, `shortcode`, `mediaId`, `mediaType`, `productType`, `caption`, `mentionCount`, `hashtags`, `playCount`, `viewCount`, `likeCount`, `commentCount`, `durationSeconds`, `createdAt`, `postedAt`, `videoUrl`, `thumbnailUrl`, `width`, `height`, `audioTitle`, `audioArtist`, `usesOriginalAudio`, `ownerUsername`, `ownerIsVerified`, `ownerFollowersCount`, `detailsLoaded`, `query`, `scrapedAt`.

`playCount` is Instagram's play counter from the hashtag list (replays included) and `viewCount` is the view count from the reel's embed, so the two numbers differ. `createdAt` is the upload time encoded in the reel's id; the exact publishing time (`postedAt`) is read only with `includePostedAt`, one extra page per reel.

### Monitor new reels for a hashtag

Save the input as a task, set **Mode** to `monitor` and run it on a schedule (for example once a day). The first run of a task records the reels Instagram lists for each hashtag now and returns nothing (you pay one monitor-check and no rows). Every later run returns only reels this task has never seen, with `changeType: "new"`. A reel that appears under two hashtags is returned once. In monitor mode `maxItems` caps the rows returned and charged, not the rows read; reels over the cap come with the next run. Likes and comments are read only for reels that are returned, so a quiet day costs one monitor-check and the list requests.

### Accounts and privacy

The account behind a reel is named only when the reel's own embed marks the account as verified, the same rule as in our other Instagram actors, so `ownerUsername` needs `includeDetails`. With `includeDetails: false` no account is named. In our test runs on 05.11.2026, 3 of 20 and 5 of 100 reels came from such an account. For every other account the row has the reel's own numbers and caption, while `ownerUsername`, `ownerFollowersCount` and the original-audio author stay empty. In captions every @mention is replaced with `@user` (the original number is kept in `mentionCount`), and e-mail addresses and phone numbers are removed. Profile pictures, user ids, full names, coauthors and tagged people are never returned.

### Related actors

- [Instagram Reel Scraper](https://apify.com/datahamster/instagram-reel-scraper) returns views, likes and comments of reels you already have links for.
- [Instagram Post Scraper](https://apify.com/datahamster/instagram-post-scraper) returns the latest posts of verified brand and media accounts.
- [TikTok Video Scraper](https://apify.com/datahamster/tiktok-video-scraper) returns views, likes, comments and saves of TikTok videos.
- [YouTube Search Scraper](https://apify.com/datahamster/youtube-search-scraper) finds YouTube videos for a keyword with their view counts.

### Use cases

- See which reels lead a hashtag in your niche and what their captions, audio and length have in common.
- Track the reels that enter a hashtag every day with monitor mode, without opening the app.
- Collect reels of verified brands and creators under campaign hashtags for a report.

### Input

| Field | Meaning | Default |
|---|---|---|
| `hashtags` | Hashtags (`travel`, `#travel`) or hashtag links (`https://www.instagram.com/explore/tags/travel/`) | `travel`, `running` |
| `maxPerHashtag` | Reels to read per hashtag (24 per request; Instagram lists about 60) | `60` |
| `includeDetails` | Read likes, comments, views, duration and audio from each reel's embed (one request per reel) | `true` |
| `includePostedAt` | Read the exact publishing time (one more page per reel) | `false` |
| `maxItems` | Stop after this many rows | `20` |
| `mode` | `scrape` or `monitor` | `scrape` |
| `monitorStateId`, `webhookUrl`, `telegramBotToken`, `telegramChatId` | Monitor state key and alert targets | empty |

### Pricing

| Event | Price |
|---|---|
| result | $0.0018 per reel ($1.80 per 1,000) |
| monitor-check | $0.005 per monitor run |
| change | $0.0018 per new reel reported in monitor mode |

Apify Store discounts: SILVER -10%, GOLD and higher -20% on every event. You pay only for rows that are pushed. Hashtags without a public list produce no rows and no charge. Platform usage (compute and proxy) is billed by Apify on top; the actor uses no proxy unless Instagram blocks the free tier.

**Found it useful?** A short review on the Store page helps other people find this actor and tells us what to improve. If something is wrong, open an issue on the actor page.

### How it works

1. The actor asks Instagram for a hashtag's reel list the same way Instagram's public topic page does for a logged-out visitor, 24 reels per request, and follows the list's cursor up to `maxPerHashtag`.
2. With `includeDetails` each reel is then read from its public embed page, the same page Instagram serves when a reel is embedded on a website. It holds the like, comment and view counts, the duration and the audio. If the embed is not served, the row is still returned with the list fields and `detailsLoaded: false`.
3. If Instagram answers with a login wall or a rate limit, the request is repeated after a pause and then through a datacenter and then a residential proxy. A hashtag walled on every proxy is skipped and the next one is read. When no hashtag of a run could be read, the run stops with a "blocked" reason instead of returning an empty dataset, and after 3 hashtags in a row are walled on every proxy it stops with a "rate_limited" reason.

### Limits

- **Only hashtags with a public list.** Instagram shows a logged-out visitor reels only for hashtags it has a public topic page for. A hashtag without one returns nothing, and the run log says so.
- **Popular reels, not the newest.** Instagram orders the list by popularity, so it contains older reels next to recent ones. Use monitor mode to collect what enters the list over time.
- **Reels only.** Instagram's public hashtag list contains reels; photo and carousel posts are not listed.
- **No comment texts.** The public embed shows only the number of comments.
- **Video and image links are signed and expire** after a few days. Download them soon after the run if you need the files.
- **Counts can be hidden** by the owner; `playCount` and `viewCount` are then empty.

### FAQ

**Do I need an Instagram account?** No. Every request is a logged-out request.

**Why did a hashtag return nothing?** Instagram has no public reel list for it. Try a related, more specific hashtag.

**Why is `ownerUsername` empty?** The reel belongs to an account that is not verified. Those accounts are treated as private individuals and are not named.

### Changelog

- 0.1 (2026-11-05): first release with reels per hashtag, likes and comments from the embed, and monitor mode for new reels.

# Actor input Schema

## `hashtags` (type: `array`):

Hashtags (travel, #travel) or hashtag links (https://www.instagram.com/explore/tags/travel/), one per line. Hashtags Instagram has no public reel list for return nothing and cost nothing.

## `maxPerHashtag` (type: `integer`):

How many reels to read per hashtag. Instagram returns 24 per request and lists about 60 reels per hashtag. In monitor mode this is the depth checked on every run.

## `includeDetails` (type: `boolean`):

Read likes, comments, views, duration and audio from each reel's public embed (one request per reel). Turn off for faster runs with the list fields only (plays, caption, links).

## `includePostedAt` (type: `boolean`):

Read the exact publishing time of each reel from its public page (one more request per reel). Without it, createdAt gives the upload time from the reel id.

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

Stop after this many rows (you are charged only for pushed rows). In monitor mode it caps the new reels returned per run; the rest come with the next run.

## `mode` (type: `string`):

scrape = full results; monitor = only new/changed items since the previous run of this task

## `monitorStateId` (type: `string`):

Optional state id when not running as a saved task (monitor mode)

## `webhookUrl` (type: `string`):

POST a change summary here in monitor mode

## `telegramBotToken` (type: `string`):

Optional: bot token for monitor-mode change summaries

## `telegramChatId` (type: `string`):

Optional: chat id that receives monitor-mode summaries

## Actor input object example

```json
{
  "hashtags": [
    "travel",
    "running"
  ],
  "maxPerHashtag": 10,
  "includeDetails": true,
  "includePostedAt": false,
  "maxItems": 20,
  "mode": "scrape"
}
```

# Actor output Schema

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

All pushed rows (dataset, JSON)

## `resultsTable` (type: `string`):

Dataset in the Console viewer

## `runSummary` (type: `string`):

RUN_SUMMARY record

# 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 = {
    "hashtags": [
        "travel",
        "running"
    ],
    "maxPerHashtag": 10,
    "maxItems": 20
};

// Run the Actor and wait for it to finish
const run = await client.actor("datahamster/instagram-hashtag-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 = {
    "hashtags": [
        "travel",
        "running",
    ],
    "maxPerHashtag": 10,
    "maxItems": 20,
}

# Run the Actor and wait for it to finish
run = client.actor("datahamster/instagram-hashtag-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 '{
  "hashtags": [
    "travel",
    "running"
  ],
  "maxPerHashtag": 10,
  "maxItems": 20
}' |
apify call datahamster/instagram-hashtag-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,datahamster/instagram-hashtag-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/X7jiUC9XQKzGL3cgr/builds/ymbIm09aUE4pEsrsw/openapi.json
