~ / endpoints / Comment API

Instagram Comment Scraper API

Our Instagram comment scraper takes a post or reel URL (or a shortcode) and returns the comments as clean JSON rows: the text, the author handle and id, the like count, and the timestamp, with a cursor to page through a long thread.

Get a free API keyBrowse the endpoints
1,000
free requests / mo
2.6s
median response
JSON
structured output
cursor
paginated
the login wall

Why Instagram Comment data hides behind a login

A logged-out Instagram post page ships zero comment data: the comment thread loads over a separate authenticated request, and the media comments API requires a logged-in session. Our endpoint parses any embedded comment edges when they exist and otherwise calls that comments API in the documented shape, reporting a clear auth status rather than returning a fake thread.

call it once

Your first Instagram Comment Scraper API call

cURL
curl "https://api.instagramscraperapi.com/api/v1/instagram/comments?url=https://www.instagram.com/p/C5xExample/&api_key=$API_KEY"
Python
import requests, os

BASE = "https://api.instagramscraperapi.com"
API_KEY = os.environ["API_KEY"]

# Pass a post/reel URL or a bare shortcode, plus a page size.
data = requests.get(
    f"{BASE}/api/v1/instagram/comments",
    params={
        "url": "https://www.instagram.com/p/C5xExample/",
        "count": 50,
        "api_key": API_KEY,
    },
    timeout=60,
).json()

for c in data["comments"]:
    print(c["author"]["username"], "-", c["text"], f"({c['likes']} likes)")

# Page further with the returned cursor when more are available.
while data.get("has_more"):
    data = requests.get(
        f"{BASE}/api/v1/instagram/comments",
        params={"url": data["url"], "min_id": data["next_min_id"], "api_key": API_KEY},
        timeout=60,
    ).json()
    for c in data["comments"]:
        print(c["author"]["username"], "-", c["text"])
inputs

Parameters

ParameterRequiredDefaultNotes
urlrequired-A post or reel permalink, e.g. https://www.instagram.com/p/C5xExample/ or a /reel/ link. Required unless you pass shortcode.
shortcodeoptional-The post shortcode (the /p// slug) on its own. One of url or shortcode is required.
countoptional50How many comments to pull this call, 1 to 200.
min_idoptional-The pagination cursor. Pass the next_min_id from the previous response to fetch the next page of comments.
countryoptionalUSTwo-letter country code for the egress region. Defaults to US.
api_keyrequired-Your API key, passed as a query parameter. Get one free at signup.
what returns

What the Instagram Comment Scraper API hands back

200 OK
{
  "shortcode": "C5xExample",
  "media_id": "3312345678901234567",
  "url": "https://www.instagram.com/p/C5xExample/",
  "source": "instagram",
  "comments": [
    {
      "position": 1,
      "id": "17954321098765432",
      "text": "Incredible shot!",
      "created_at": "2026-03-31T14:22:05.000Z",
      "likes": 12,
      "author": {
        "id": "1748234592",
        "username": "space_explorer",
        "profile_pic_url": "https://scontent.cdninstagram.com/v/t51.2885-19/example.jpg",
        "is_verified": false,
        "url": "https://www.instagram.com/space_explorer/"
      }
    }
  ],
  "comments_count": 50,
  "has_more": true,
  "next_min_id": "QVFE...",
  "data_source": "v1_api"
}
FieldTypeDescription
shortcodestringThe post shortcode the comments belong to.
media_idstringThe numeric media id resolved for the post, used to call the comments API.
urlstringThe canonical post permalink.
commentsarrayThe comment rows for this page. Each carries position, id, text, created_at, likes, and a nested author object.
authorobjectPer comment: the commenter's id, username, profile_pic_url, is_verified flag, and profile url.
comments_countintegerNumber of comment rows returned on this page (one page per call).
has_morebooleanTrue when another page of comments is available, false or absent on the last page.
next_min_idstringCursor for the next page. Pass it back as min_id, or null when there are no more.
data_sourcestringembedded when the first page came from comment edges on the post page, v1_api when it came from the media comments API hop.
put it to work

Where teams point Instagram data

>

Sentiment analysis

Pull the comments on a post and run them through a sentiment model to gauge how an audience reacted to a launch or campaign.
>

Community management

Read new comments on your own posts on a schedule to surface questions, complaints, and leads that need a reply.
>

Giveaway and contest checks

Collect the comment thread on a contest post to verify entries, tag mentions, and pick winners from structured rows.
>

Influencer engagement audits

Read the comments under a creator's posts to judge whether engagement is genuine before a sponsorship.
>

Trend and topic mining

Aggregate comments across posts in a niche to see the questions and phrases an audience uses in their own words.
>

Feedback pipelines

Feed post comments into a dashboard so product and marketing teams see reactions next to each piece of content.
why it holds

How our Instagram Comment Scraper API stays reliable

We resolve the post's numeric media id and read the comment thread in Instagram's documented shape, mapping each comment to a stable row with its author, likes, and timestamp, and paging with a cursor. Instagram gates comments behind a logged-in session, so on the logged-out tier the endpoint reports an honest auth status rather than a fabricated thread, and a request that cannot return comments is not billed.

*

URL or shortcode input

You pass a post or reel URL, or a bare shortcode, and we resolve the media id the comments API needs.
*

Embedded-first parsing

When Instagram embeds the first comment page on the post, we parse those edges directly with no extra hop, then fall back to the comments API for the rest.
*

Cursor pagination

Each call returns one page plus a next_min_id, and you follow the cursor to walk a long thread at a flat charge per page.
*

Structured comment rows

Every comment maps to text, author (id, username, avatar, verified), likes, and an ISO timestamp in a stable schema.
*

Honest auth reporting

The comments API needs a logged-in session, so the endpoint reports a clear auth status when the thread is gated instead of returning a fake list.
*

Pay for success

A request that cannot return comments because of the login gate is not charged, so you only pay when rows come back.
weigh the options

Instagram Comment Scraper API weighed against the Instagram API and DIY

Our APIDIY (requests / headless)Instagram Graph API
Comment rowsDocumented shape, cursor pagedYou script the app endpoint yourselfOnly on media you own or manage
Media id resolutionURL or shortcode to media id, automaticYou resolve the id yourselfNot applicable
SetupAPI key onlyResidential proxies, session handling, parsersFacebook app, linked Business account, app review
Login gateReported honestly when Instagram walls commentsYou hit the wall and handle it yourselfNot exposed for third-party media
Anti-bot and proxiesBuilt in, residential USYou build and maintain itNot applicable
BillingOnly successful pages are chargedYou eat the cost of blocked callsNot applicable
plans & pricing

Pay only for what you pull

PlanPriceBest for
Free1,000 requestsTesting and small jobs
Pro$0.60 / 1kProduction workloads
Pay-as-you-go$0.90 / 1kSpiky or one-off volume

Median response 2.6s. You only pay for successful requests.

FAQ

What is an Instagram comment scraper?

An Instagram comment scraper is a tool that reads the comments on a post and returns each one in a structured format. Our endpoint takes a post or reel URL (or a shortcode), resolves the media id, and returns comment rows with the text, author handle and id, like count, and timestamp as JSON, plus a cursor to page through a long thread.

Can you scrape Instagram comments logged-out?

Only in limited cases, and we are direct about it. A logged-out post page ships zero comment edges, and the media comments API requires a logged-in session. Our endpoint first parses any embedded comment edges on the rare capture that includes them, then calls the comments API in the correct shape. When Instagram gates the thread it reports an honest auth status rather than inventing comments. A fully populated comment thread needs an authenticated session.

What does the endpoint return when comments are gated?

It returns a classifiable auth status indicating comments need an authenticated session, along with the shortcode and the resolved media id where available, so you know how far the resolution got. It never fabricates comment rows, and a request that cannot return comments is not billed.

How does comment pagination work?

Each successful call returns one page of comments plus a next_min_id cursor and a has_more flag. To fetch the next page, pass next_min_id back as the min_id parameter. Every page is one flat charge, so there is no server-side deep loop and no surprise multi-page bill.

Can I get comments on my own posts through the official API?

Yes. The official Instagram Graph API returns comments for media on accounts you own or manage, after you set up a Facebook app, link a Business or Creator account, and pass app review. It does not return comments on arbitrary third-party posts, which is where a scraper API applies, subject to the login gate described above.

Is scraping Instagram comments legal?

Scraping publicly visible data is broadly permitted in many jurisdictions, and US courts have declined to treat collecting public data as unauthorized access. Comments can contain personal data and usernames, though, and Instagram's terms restrict automated collection and gate the comments API behind a login. Accessing data behind authentication you are not authorized to use can cross into unauthorized access, so use comment data only where you have a lawful basis, comply with GDPR and CCPA, and take your own legal advice.

Pull comment api as clean JSON
Start on 1,000 free requests. No card needed.
Get a free API key Browse the endpoints