# Instagram Post Scraper - Posts, Likes, Comments & Media (`zaver.api/instagram-post-scraper`) Actor

Scrape Instagram posts and carousels from any profile, hashtag, location or post URL - caption, hashtags, mentions, likes, comments, views, timestamp, author and media links. No login, deep export. $0.99 per 1,000 posts. Export CSV, JSON, Excel.

- **URL**: https://apify.com/zaver.api/instagram-post-scraper.md
- **Developed by:** [Zaver](https://apify.com/zaver.api) (community)
- **Categories:** Social media, Marketing
- **Features:** Limited permissions
- **Stats:** 29 total users, 4 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.99 / 1,000 post scrapeds

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

## Instagram Post Scraper — Download Posts, Captions, Likes & Media to CSV

**Download all posts from any public Instagram profile, hashtag or location.** Get
captions, hashtags, mentions, like and comment counts, media type and image URLs —
exported to CSV, Excel, JSON or XML. No login, no API key, no Business account.

Built for bulk post export: point it at a username and pull the whole feed, or filter
to only what was published since your last run.

### What data does the Instagram Post Scraper extract?

#### Post fields

| Field | Description |
|---|---|
| `url` | Canonical post URL |
| `shortcode` | Instagram shortcode, e.g. `DcOX3hWFiey` |
| `post_id` | Numeric post ID |
| `media_type` | `photo`, `video`, `carousel` or `reel` |
| `product_type` | `feed`, `clips` or `igtv` |
| `caption` | Full caption text, emoji and line breaks preserved |
| `taken_at` | ISO publish timestamp |
| `thumbnail_url` | Direct image URL |

#### Engagement fields

| Field | Description |
|---|---|
| `likes` | Like count at scrape time |
| `comments_count` | Number of comments |

#### Parsed caption fields

| Field | Description |
|---|---|
| `hashtags` | Array of hashtags pulled out of the caption |
| `mentions` | Array of @accounts mentioned |

#### Author fields

`username`, `user_id`, `user_full_name`, `is_verified` — plus `source`, which records
the input that produced the row, so multi-target exports stay separable.

### Why use this Instagram post scraper

#### Works from a username, a hashtag or a location

Pass `nasa`, a full profile URL, a hashtag or a place — the Actor resolves the target
type for you. No separate tool per source.

#### Hashtags and mentions arrive pre-parsed

`hashtags` and `mentions` come back as arrays rather than buried in caption text, so
you can build a tag co-occurrence map or a mention graph without writing a parser.

#### Incremental exports with a date filter

`onlyPostsNewerThan` skips anything published before a date — and skipped posts are
not billed. Schedule a daily run and you pay only for new content.

#### Export to CSV, Excel or JSON

Download as **CSV, Excel, JSON, XML or JSONL**, or pull through the Apify API into
your own pipeline.

### How to use it

1. Open the Actor in Apify Console.
2. Put usernames, profile URLs, hashtags or post URLs into **directUrls**.
3. Set **resultsLimit** — posts per target, and your cost ceiling.
4. Optionally set **onlyPostsNewerThan** for an incremental export.
5. **Save & Start**, then download from **Storage**.

### Input example

```json
{
  "directUrls": ["nasa", "https://www.instagram.com/natgeo/"],
  "resultsLimit": 200,
  "onlyPostsNewerThan": "2026-09-01"
}
```

`resultsLimit` applies **per target**, so two profiles at 200 returns up to 400 posts.

### Output example

```json
{
  "source": "nasa",
  "url": "https://www.instagram.com/p/DcOX3hWFiey/",
  "shortcode": "DcOX3hWFiey",
  "post_id": "3967213292204992434",
  "media_type": "photo",
  "product_type": "feed",
  "caption": "With your powers combined… This colorful picture of the cosmos is the product of teamwork between our @NASAHubble, @NASAWebb, and @NASAChandraXray telescopes…",
  "hashtags": ["NASA", "Universe", "Nebula"],
  "mentions": ["NASAHubble", "NASAWebb", "NASAChandraXray"],
  "likes": 566179,
  "comments_count": 4223,
  "taken_at": "2026-08-19T14:11:47+00:00",
  "username": "nasa",
  "user_id": "528817151",
  "user_full_name": "NASA",
  "is_verified": true,
  "thumbnail_url": "https://scontent…jpg"
}
```

### Pricing

**$0.00099 per post scraped** — the same rate on every Apify plan, including the free
one.

| Posts exported | Cost |
|---|---|
| 1,000 | $0.99 |
| 10,000 | $9.90 |
| 100,000 | $99.00 |

Not billed: unreachable usernames, private profiles, and posts excluded by your
`onlyPostsNewerThan` filter.

### Use cases

#### Competitor content audit

Export a rival's last 500 posts with captions and engagement, then sort by likes to
see what actually works in your category.

#### Campaign hashtag tracking

Run it against your campaign hashtag daily and measure reach and engagement while the
campaign is live, not after it.

#### Caption and creative research

A few thousand captions from top accounts in a niche is a training set for your own
copy — or for an LLM writing in that voice.

#### Instagram content archive

Schedule it and keep a permanent record of what an account published, including posts
later deleted.

### FAQ

**How do I download all posts from an Instagram profile?**
Put the username or profile URL into `directUrls`, raise `resultsLimit` to cover the
account's post count, and run it. Export the dataset as CSV or Excel from the Storage
tab.

**Can I scrape Instagram posts without an API key?**
Yes. There is nothing to register. Instagram's official Graph API requires app review,
a Business account and a connected Facebook Page, and only covers accounts you own.
This reads public posts directly.

**How much does it cost to scrape 10,000 Instagram posts?**
$9.90 — a flat $0.00099 per post on every plan, including the free tier. You pay only
for posts actually delivered.

**Does the Instagram Post Scraper include Reels and carousels?**
Yes. `media_type` distinguishes `photo`, `video`, `carousel` and `reel`, so you can
filter after export. For reels-only extraction with play counts, use the
[Instagram Reel Scraper](https://apify.com/zaver.api/instagram-reel-scraper).

**Can I scrape Instagram posts by hashtag?**
Yes. Pass a hashtag in `directUrls` and it returns posts carrying that tag, with the
same fields as profile posts.

**How do I get only new Instagram posts since my last export?**
Set `onlyPostsNewerThan` to the date of your previous run. Older posts are skipped and
not billed, so a daily incremental export costs only what is new.

**Can I export Instagram captions and hashtags to a spreadsheet?**
Yes. `caption` holds the full text, and `hashtags` and `mentions` come back as arrays
that flatten into spreadsheet columns on CSV export.

**Can I scrape posts from a private Instagram account?**
No. Only public profiles return content. A private account yields no posts and is not
billed.

**Is it legal to scrape Instagram posts?**
This Actor collects only publicly available data and never accesses private content.
Public data may still be personal data under GDPR and similar regimes, so only collect
what you have a legitimate reason to process. See Apify's guidance on the legality of
web scraping.

### Integrations

Connect to **Make, Zapier, n8n, Slack, Google Sheets, Google Drive, Airbyte** and
GitHub, or use webhooks on run completion. Official **Node.js** and **Python** SDKs
are available, and the Apify MCP server lets an AI agent call this Actor directly.

### Related Instagram scrapers

- [Instagram Scraper](https://apify.com/zaver.api/instagram-scraper) — all-in-one: posts, reels, comments, profiles, hashtags, places and search
- [Instagram Reel Scraper](https://apify.com/zaver.api/instagram-reel-scraper) — reels only, with play counts and video URLs
- [Instagram Comments Scraper](https://apify.com/zaver.api/instagram-comment-scraper) — every comment on a post or reel
- [Instagram Profile Scraper](https://apify.com/zaver.api/instagram-profile-scraper) — bio, followers, email and category in bulk
- [Instagram Hashtag Scraper](https://apify.com/zaver.api/instagram-hashtag-scraper) — creators and leads by topic

### 🔌 Use this Actor from Claude, ChatGPT or Cursor (MCP)

Add it as a tool in any MCP client - Claude Code, Claude Desktop, Cursor, VS Code or ChatGPT - through Apify's hosted MCP server. The client runs the Actor for you and reads the results back, so you never leave the chat.

**Actor-specific server URL**

```
https://mcp.apify.com/?tools=actors,docs,zaver.api/instagram-post-scraper
```

**Claude Code** - one command:

```bash
claude mcp add --transport http igpost "https://mcp.apify.com/?tools=actors,docs,zaver.api/instagram-post-scraper"
```

**Claude Desktop, Cursor or any client with a JSON config:**

```json
{
  "mcpServers": {
    "igpost": {
      "url": "https://mcp.apify.com/?tools=actors,docs,zaver.api/instagram-post-scraper"
    }
  }
}
```

The first connection opens a browser to sign in to Apify, so no API token sits in your config. If your client cannot do OAuth, send `Authorization: Bearer <YOUR_APIFY_TOKEN>` instead.

Then simply ask:

> Get the recent posts from @natgeo with likes and comments

***

Built and maintained by **Zaver**. For bugs, feature requests or custom data needs,
open an issue on this Actor.

# Actor input Schema

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

What to scrape posts from, one per line: a username or profile URL (<code>nasa</code>), a hashtag (<code>#travel</code>), a location URL, or a single post URL (<code>https://www.instagram.com/p/CODE/</code>).

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

Hashtags to scrape posts from, one per line - bare names are fine (<code>travel</code>, <code>fitness</code>), no <code>#</code> needed. Use this field for tags; put profiles and URLs in the field above.

## `keywords` (type: `array`):

Free-text search - find posts matching a phrase, brand or product name (<code>ashirwad ka diya</code>, <code>iphone 17 unboxing</code>). Uses Instagram's keyword search; one phrase per line.

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

Max posts to export per profile, hashtag or location. Set high for a deep export; billed only per post delivered.

## `onlyPostsNewerThan` (type: `string`):

ISO date (<code>2026-01-01</code>) or relative (<code>7 days</code>, <code>1 month</code>).

## Actor input object example

```json
{
  "directUrls": [
    "nasa"
  ],
  "resultsLimit": 50,
  "onlyPostsNewerThan": ""
}
```

# Actor output Schema

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

One dataset item per post with caption, likes, comments, views, author and media links.

## `resultsCsv` (type: `string`):

The same records as a CSV download.

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

Counts for the run: posts scraped, requests, errors.

# 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 = {
    "directUrls": [
        "nasa"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("zaver.api/instagram-post-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 = { "directUrls": ["nasa"] }

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

```

## MCP server setup

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