# Instagram Scraper (`steadyfetch/instagram-scraper`) Actor

Instagram scraper for any mix of usernames, profile, post and reel links, hashtags and places in one run: posts or reels (a profile's rows carry its followers, following and post count), a post's comments on request. From $0.238 per 1,000 posts, no start fee.

- **URL**: https://apify.com/steadyfetch/instagram-scraper.md
- **Developed by:** [Steadyfetch Team](https://apify.com/steadyfetch) (community)
- **Categories:** Social media, Lead generation, Automation
- **Features:** Limited permissions, Multi-tenant, Server interface
- **Stats:** 1 total users, 0 monthly users, 0.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.24 / 1,000 posts

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/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 Scraper

**Put any mix of Instagram usernames, profile links, post or reel links, #hashtags and place links in one list and get back the right rows for each: a profile's posts or reels, a hashtag's posts, a place's posts, a post's own row and its comments. A username or profile link's rows also carry the account's followers, following and post count. No login, no cookies, no start fee — from $0.238 per 1,000 posts.**

One run takes the whole mixed list. A username gives you its newest posts (or its reels), a hashtag or a place gives you its posts, a post or reel link gives you that post and, if you ask, its comments. Each result row says which line of your list it came from, so one dataset holds everything and still sorts cleanly.

**Using an AI agent?** Pin this actor in Apify's MCP server with one link: `https://mcp.apify.com?tools=steadyfetch/instagram-scraper`

- **Actor id:** `steadyfetch/instagram-scraper`
- **Input:** `{ "directUrls": ["nasa", "https://www.instagram.com/p/DgLGMGVly-p/", "#travel"], "resultsLimit": 12, "includeComments": false }`
- **Cap the bill:** set `maxTotalChargeUsd` on the run (a run option, not Actor input), e.g. `0.50` — the run stops when it reaches it.
- **Price:** from $0.000238 per post or reel, $0.00025 per comment, and one $0.0045 lookup per input that returns at least one row. Full table below.
- **How often it changes:** an account's newest posts and a hashtag's or place's posts change every day; likes, plays and comment counts keep moving for a few days after a post goes up. Re-run daily or weekly for fresh numbers.

Not affiliated with or endorsed by Instagram.

### What you get

**Post and reel rows** (`rowType` = `post`), one per post:

| Column | What it holds |
|---|---|
| `shortCode` · `url` · `postId` | the post's code, its link and its id |
| `type` · `productType` · `isReel` | image, video or carousel; reels are marked `isReel` |
| `caption` · `hashtags` · `mentions` | the caption (e-mail addresses and phone numbers hidden, see below), and the hashtags and accounts it names |
| `takenAt` | when it was posted |
| `likeCount` · `commentCount` · `playCount` · `videoDuration` | engagement as Instagram shows it, and a video's length in seconds |
| `ownerUsername` · `ownerFullName` · `ownerIsVerified` · `ownerProfileUrl` | the account that posted it |
| `profileFollowers` · `profileFollowing` · `profilePostCount` | the account's public counts, on every post row of a username or profile link (empty on rows found by hashtag, place or post link) |
| `taggedUsers` · `coauthors` · `locationName` · `locationId` | tagged accounts, co-authors and the place (a location that holds a number or an address is left empty) |
| `displayUrl` · `videoUrl` · `videoUrlExpiresAt` · `carouselCount` | the image and video links (Instagram's links expire; `videoUrlExpiresAt` says when) |
| `isPinned` · `isSponsored` | pinned to the profile, and paid partnership |
| `postSource` | how it was found: `profile-posts`, `profile-reels`, `hashtag`, `place` or `link` |

**Comment rows** (`rowType` = `comment`), one per comment when you turn comments on: `text` (e-mail addresses and phone numbers hidden, see below), `username`, `userFullName`, `userIsVerified`, `userProfileUrl`, `userProfilePicUrl`, `likeCount`, `replyCount`, `createdAt`, `isReply`, `isPinned`, `isByPostAuthor`, `postShortcode`, `postUrl`.

E-mail addresses and phone numbers in captions, comment text and people's names are replaced with `[e-mail removed]` and `[phone removed]`, and so are the usual ways of writing an e-mail out in words, such as name (at) example (dot) com. A phone number is 7 to 15 digits written as one (a date, a year range or a time is not), so a long number written into a caption, such as a count or an order number, is hidden too. Digits written straight onto a name (such as shop12345678) and a number inside a web link (other than a phone link) are left as written; ids, counts and dates in their own columns are never touched. A location that holds a number or an address is left empty.

Every result row also carries `input` (the line of your list it came from), and every row carries `charged`, `chargedEvents`, `status`, `retryable` and `statusReason`, so you can reconcile your bill from the dataset itself. The last row (`run_summary`) is the run's receipt.

### How to use it

1. Put your inputs in **Instagram links, usernames, hashtags or places**, one per line:
   - a username: `nasa` or `@nasa`, or a profile link `https://www.instagram.com/nasa/`
   - a profile's reels tab: `https://www.instagram.com/nasa/reels/` (or set **Profile tab** to `reels`)
   - a post or reel: `https://www.instagram.com/p/DgLGMGVly-p/` or `https://www.instagram.com/reel/…/`
   - a hashtag: `#travel` or `https://www.instagram.com/explore/tags/travel/`
   - a place: its Instagram place link, `https://www.instagram.com/explore/locations/103912118089363/eiffel-tower/`
2. Set **Max results per input** (12 by default): the most posts read for each profile, hashtag and place. It is a ceiling: an input with fewer gives you what it has. A profile's posts or reels come newest first by their own date; a pinned post sits at its own date, so it is in your results only when it is one of the newest.
3. For post and reel links, turn on **Include comments of post links** and set **Max comments per post** (20 by default).
4. Press Start. With the list left empty (the form as it opens, or an API call with no input) the run reads a 5-post sample of the public account @nasa, so you can see the rows first. Pressing Start on the empty form runs that example as a normal run, charged like any run at your plan's prices (5 posts and one lookup, under one cent). A free-plan account gets one example a day; later presses in the next 24 hours show built-in example rows, with no fee.

A run on a paid Apify plan reads until its own run timeout; set **Max run seconds** to stop it sooner. The one time limit of ours left there stops a run only when nothing new has come back for 10 minutes. One run handles up to about 150,000 posts; for more than that, split your list into several runs. The same post found through two of your inputs (a profile and a hashtag, say) is delivered and charged once. This actor keeps no memory between runs: running the same list again reads it again from the start and charges again.

This actor does not read stories, highlights, a profile's tagged tab or follower lists. For those, see our [Instagram Stories Scraper](https://apify.com/steadyfetch/instagram-stories-highlights-scraper), [Instagram Mentions Scraper](https://apify.com/steadyfetch/instagram-mentions-scraper) and [Instagram Followers Scraper](https://apify.com/steadyfetch/instagram-followers-scraper). For a reel's spoken words, see our [Instagram Transcript Scraper](https://apify.com/steadyfetch/instagram-reel-transcript-scraper).

### Pricing

You pay per result delivered, never for starting a run, and an input that delivers nothing is never charged.

| Event | Apify free plan | Bronze | Silver | Gold, Platinum, Diamond |
|---|---|---|---|---|
| `post` — one post or reel row | $0.000308 | $0.00028 | $0.000238 | $0.000238 |
| `comment` — one comment row | $0.000297 | $0.00027 | $0.00025 | $0.00025 |
| `lookup` — once per input that returns at least one row | $0.0045 | $0.0045 | $0.0045 | $0.0045 |

The lookup rides the first row each input delivers. So a profile asked for 12 posts costs 12 posts and one lookup: about $0.007 on Gold. A post link with 20 comments costs one post, 20 comments and one lookup: about $0.010 on Gold.

**On the Apify free plan** an account can make up to 10 reads a day at the free-plan price in the table: looking up one input is one read, and each further page of results (about 10 to 24 posts, or about 16 comments) is one more. The 5-post sample does not count against those reads (one sample a day per free-plan account; a later bare Start in the next 24 hours shows built-in example rows instead, with no result fee). A shared daily allowance for all free-plan accounts can end a run sooner on a busy day. Either way the run stops cleanly, its status line and an uncharged row say when the allowance renews, and nothing past it is read or charged. Paid Apify plans have no daily limit.

Set `maxTotalChargeUsd` on the run to cap what it can charge; the run stops when it reaches it.

### When a result is not delivered

An input that does not deliver in full gets an uncharged row saying why and how many results it stands for (inputs held by the free-plan allowance share one):

- `nothing_found` — Instagram answered that the account, hashtag, place or post does not exist, or its list ended before your limit.
- `not_public` — the account or post is private.
- `try_again` — Instagram did not answer for it on this run; a new run may succeed.
- `not_accepted` — the line is not an Instagram username, link, hashtag or place, or Instagram refused it as written; the row says what to change.
- `not_delivered` — Instagram answered in a form this actor could not read on this run; nothing is charged, and an issue on the Issues tab helps us fix it.
- `your_limit_reached` — your maximum cost per run was reached.
- `not_reached` — the run's time ran out before this input was finished, or nothing new came back for 10 minutes; start it again (raise Max run seconds or the run timeout when the time ran out).
- `limit_reached` — the Apify free plan's daily allowance (with the time it renews), or this run's own limit.

This actor may fail when Instagram changes; failed items are never charged.

### Call it like an API (Standby)

You can also send the same input as an HTTP request and get the rows back in the answer, with no run to start and no dataset to read. The actor's **Endpoints** tab lets you try it from the browser:

```
GET /?directUrls=nasa&directUrls=%23travel&resultsLimit=12
```

A request is charged exactly like a run with the same input — the same `post`, `comment` and `lookup` events at the same prices — and the answer ends with the request's receipt. A request reads as many inputs as its time allows (3 on the Apify free plan, where free-plan callers share a daily and an hourly allowance). A request carries no account memory: it reads every input fresh, and it cannot use your own datasets or webhooks.

### Related actors

- [Instagram Bio Scraper](https://apify.com/steadyfetch/instagram-profile-details-scraper) — one row per profile with its bio and public contact fields.
- [Instagram Transcript Scraper](https://apify.com/steadyfetch/instagram-reel-transcript-scraper) — what is said in reels.
- [Instagram Followers Scraper](https://apify.com/steadyfetch/instagram-followers-scraper) — an account's followers and following.

### Support

Something off? Open an issue on the Issues tab; we usually reply within a couple of hours.

If it earned its keep, a rating helps other buyers find it, and saving the actor keeps it one click away.

# Changelog

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

# Actor input Schema

## `directUrls` (type: `array`):

One per line: a username (nasa or @nasa), a profile link (https://www.instagram.com/nasa/, or .../nasa/reels/ for the reels tab), a post or reel link (https://www.instagram.com/p/CODE/ or /reel/CODE/), a #hashtag (#travel or an /explore/tags/ link) or a place link (https://www.instagram.com/explore/locations/<id>/<name>/). Stories, highlights and a profile's tagged tab are not read here. Left empty, the run reads a 5-post sample of @nasa.

## `profileTab` (type: `string`):

Which part of a profile to read: "posts" (its grid: photos, carousels and the reels shared to the grid) or "reels" (its reels tab). A /reels/ link reads the reels tab whatever this says. Empty means posts.

## `resultsLimit` (type: `integer`):

The most posts or reels read for each profile, hashtag and place (at least 1). A ceiling, never a target: an input with fewer returns what it has.

## `includeComments` (type: `boolean`):

For each post or reel link, also return its comments, one row each, charged per comment row.

## `commentsLimit` (type: `integer`):

The most comments read for each post or reel link when comments are on (at least 1).

## `maxRunSeconds` (type: `integer`):

On a paid plan, leave it empty and the run reads until its own run timeout. Set it (at least 30) and the run stops reading after this many seconds and delivers what it has read; raise it to read more in one run.

## Actor input object example

```json
{
  "profileTab": "posts",
  "resultsLimit": 12,
  "includeComments": false,
  "commentsLimit": 20
}
```

# Actor output Schema

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

One row per delivered result: `rowType` post (a post or a reel, charged as one `post`) or comment (charged as one `comment`), with `input` naming the line of your list it came from; a profile's post rows also carry its followers, following and post count. The first delivered row of each input also carries that input's one `lookup`. Every row carries `charged`, `chargedEvents` and `status`, so the invoice reconciles from the dataset itself: only rows with charged = true were billed.

## `notDelivered` (type: `string`):

An uncharged row for each part of an input that was not delivered, with `resultsNotDelivered` and the reason: nothing_found (Instagram answered that it does not exist, or the list ended), not_public (private), try_again (not read on this run; a re-run may succeed), not_accepted (a value that is not an Instagram username, link, hashtag or place, or that Instagram refused as written; the row says what to change), not_delivered (Instagram answered in a form this actor could not read on this run), your_limit_reached (your maximum cost per run), not_reached (the run's time ran out; a new run reads the input again and charges again), limit_reached (the Apify free plan's daily allowance, with the time it renews, or this run's own limit). None of these is charged.

## `summary` (type: `string`):

Results delivered, results asked for, what stopped the run, and the charged-event totals.

# 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 = {};

// Run the Actor and wait for it to finish
const run = await client.actor("steadyfetch/instagram-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 = {}

# Run the Actor and wait for it to finish
run = client.actor("steadyfetch/instagram-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 '{}' |
apify call steadyfetch/instagram-scraper --silent --output-dataset

```

## MCP server setup

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