# Instagram Post & Reel Stats Scraper (`inovaflow/instagram-post-stats-scraper`) Actor

Track Instagram posts and reels for a campaign: paste post/reel URLs (or profiles) and get likes, comments, reel plays, caption, hashtags, mentions, publish time, owner followers and engagement rate per post. No login, no cookies, pay per post.

- **URL**: https://apify.com/inovaflow/instagram-post-stats-scraper.md
- **Developed by:** [inovaflow](https://apify.com/inovaflow) (community)
- **Categories:** Social media
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.50 / 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.

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

**Paste your campaign's Instagram posts and reels — get likes, comments, plays, owner followers and engagement rate for each, in one table.**

If you run influencer campaigns, you know the end-of-month ritual: a spreadsheet of 60 post links from 20 creators, and someone opening each one to copy likes, comments and views by hand — then looking up every creator's follower count to work out an engagement rate. It takes an afternoon, it's already out of date by the time the report goes out, and the numbers never quite match.

We had the same report to produce, so we built this for ourselves first — and now we're sharing it. Paste the post and reel links (or a few profiles), and each row comes back with the numbers a campaign report needs: likes, comments, **reel plays**, the exact publish time, the caption with its hashtags and mentions, the owner's follower count and the **engagement rate**. No login, no cookies, no Instagram account at risk.

### Who it's for

- **Influencer marketing teams** reporting on deliverables: *"how did the 40 reels from last week's launch perform?"*
- **Agencies** checking that sponsored posts went live with the right tags and hashtags.
- **Brands** benchmarking a competitor's latest posts: *"what engagement do their reels get?"*
- **Analysts and AI agents** that need a clean, flat row per post — one call, dataset only.

### What you get per post

`url`, `type` (reel / image / carousel / video), `ownerUsername`, **`ownerFollowers`**, **`likes`**, **`comments`**, **`plays`** (the views Instagram shows on reels), `videoViews` (legacy 3-second views), **`engagementRate`** (likes + comments ÷ followers, %), `engagementRateByPlays` (likes + comments ÷ plays, %), `postedAt`, `caption`, `hashtags`, `mentions`, `taggedUsers`, `coauthors`, `isPaidPartnership`, `musicTitle`, `musicArtist`, `location`, `videoDuration`, `carouselCount`, `thumbnailUrl` and `status`.

Two table views are built in: **Post stats** (the campaign table) and **Content** (caption, tags, music).

### Options

- **Post and reel URLs** — `/p/`, `/reel/`, `/tv/` links, share links or bare shortcodes. Each gives one row.
- **Profiles (latest posts)** — usernames or profile links; returns each profile's latest posts. Pick how many and whether you want all posts, reels only, or photos only.
- **Look up reel plays and exact post time** (on by default) — reads the owner's recent feed to add plays, the exact time, coauthors and music. It reaches the owner's latest ~60 posts by default (raise *Feed depth* for older ones); older posts still get likes, comments, caption and an estimated time.
- **Add owner followers and engagement rate** (on by default).

### How to set it up

1. Paste your post and reel links, one per line.
2. Click **Start**.
3. Open the **Post stats** view, or download CSV / Excel / JSON.

And that's it — schedule it daily to watch a campaign grow.

### Pricing

Pay per result: **$0.0015 per post** delivered ($1.50 per 1,000). Deleted, private or invalid links are listed in the dataset but never charged.

> **Tip:** paste posts from the same creators together — each creator's feed is read once for all of their posts, so big campaign lists stay fast.

### Notes

- Instagram hides like counts on some posts; those rows show `likes: null` and no engagement rate (we never guess).
- Plays are only public for reels and videos; photos and carousels show `plays: null`.
- Only publicly available data from public accounts is collected. Private accounts return a `status` explaining why.
- Missing a metric? Open an issue in the **Issues** tab — we read them and add what's asked for.

# Actor input Schema

## `postUrls` (type: `array`):

Instagram post or reel links, one per line — `https://www.instagram.com/p/<code>/`, `/reel/<code>/`, `/tv/<code>/`, share links or bare shortcodes. Each gives one row.

## `usernames` (type: `array`):

Instagram usernames or profile URLs, one per line. Returns each profile's latest posts (set how many below).

## `postsPerProfile` (type: `integer`):

How many of each profile's latest posts to return (pinned posts included, newest first).

## `postType` (type: `string`):

For profiles: return every post, only reels/videos, or only photo and carousel posts. Pasted URLs are always returned.

## `includePlays` (type: `boolean`):

Reads the owner's recent feed to find each pasted post: adds reel plays (the views Instagram shows), the exact publish time, coauthors and music. Posts older than the feed depth below keep likes, comments, caption and an estimated time.

## `includeOwnerFollowers` (type: `boolean`):

Engagement rate = (likes + comments) ÷ owner followers × 100.

## `maxFeedPagesPerOwner` (type: `integer`):

How far back the owner's feed is read to find a pasted post (5 pages ≈ the latest 60 posts). Raise it for older posts.

## `maxConcurrency` (type: `integer`):

Concurrent requests to Instagram. Lower it if the log shows many rate-limit retries.

## `residentialFallback` (type: `boolean`):

Retry on a residential IP when Instagram keeps refusing datacenter IPs. Adds a little proxy traffic to the run cost only when needed.

## Actor input object example

```json
{
  "postUrls": [
    "https://www.instagram.com/reel/DdFHJkpyy58/",
    "https://www.instagram.com/p/Dd0Sqf5F3AK/"
  ],
  "usernames": [
    "natgeo",
    "https://www.instagram.com/nasa/"
  ],
  "postsPerProfile": 12,
  "postType": "all",
  "includePlays": true,
  "includeOwnerFollowers": true,
  "maxFeedPagesPerOwner": 5,
  "maxConcurrency": 4,
  "residentialFallback": true
}
```

# Actor output Schema

## `stats` (type: `string`):

One row per post: likes, comments, plays, owner followers, engagement rate and publish time.

## `content` (type: `string`):

Caption, hashtags, mentions, tagged users, coauthors, music and location per post.

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

Counts, feed lookups and request statistics.

# 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 = {
    "postUrls": [
        "https://www.instagram.com/reel/DdFHJkpyy58/",
        "https://www.instagram.com/p/Dd0Sqf5F3AK/"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("inovaflow/instagram-post-stats-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 = { "postUrls": [
        "https://www.instagram.com/reel/DdFHJkpyy58/",
        "https://www.instagram.com/p/Dd0Sqf5F3AK/",
    ] }

# Run the Actor and wait for it to finish
run = client.actor("inovaflow/instagram-post-stats-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 '{
  "postUrls": [
    "https://www.instagram.com/reel/DdFHJkpyy58/",
    "https://www.instagram.com/p/Dd0Sqf5F3AK/"
  ]
}' |
apify call inovaflow/instagram-post-stats-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,inovaflow/instagram-post-stats-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/t9ouh1RkZ5axub57l/builds/0tqQjhvKJAuWHRQaC/openapi.json
