Instagram Post Comments API
Get comments on any Instagram post. Sentiment analysis and community research from $0.01/call.
Fetch comments on any Instagram post by shortcode. Returns comment text, author info, and likes with pagination.
Try it live
Fill in the fields and hit Run to see a real response.
{
"ok": true,
"data": {
"comments": [
{
"text": "Beautiful!",
"username": "commenter",
"like_count": 50
}
],
"end_cursor": "...",
"has_next_page": true
}
}Features
Resolves a post by shortcode and returns a comments array of the actual comment text left on it, ready for reading or analysis.
Each comment includes the commenter's username, so you can attribute opinions and identify who is engaging in the conversation.
Every comment carries its own like_count, letting you surface the most-upvoted reactions and gauge which opinions resonate.
Responses include end_cursor and has_next_page; pass end_cursor back to read an entire comment thread, not just the first page.
Use cases
Sentiment Analysis
Analyze audience sentiment through post comments.
Community Engagement
Study community engagement and discussion patterns.
Quick start
Copy this snippet and start making calls.
const res = await fetch('https://api.yepapi.com/v1/instagram/post-comments', {
method: 'POST',
headers: {
'x-api-key': 'YOUR_API_KEY',
'Content-Type': 'application/json',
},
body: JSON.stringify({
"shortcode": "CxYzAbCdEf"
}),
});
const data = await res.json();
console.log(data);Read the comment thread on any Instagram post
The YepAPI Instagram Post Comments API returns the full conversation under a post — a comments array with each comment's text, author username, and like_count — from the post's shortcode. A POST to /v1/instagram/post-comments pages through an entire thread with end_cursor, giving sentiment and community-research tools the raw discussion to work with.
It picks up where the Post API leaves off: the Post API gives the content and totals, Comments gives the voices reacting to it. Pair it with the Post Likers API to see who liked versus who spoke, and profile notable commenters with the User Profile API. One key also covers TikTok, YouTube, SEO, and AI endpoints.
What is an Instagram comments API?
An Instagram comments API returns the comments left on a specific post as structured JSON. You send {"shortcode": "CxYzAbCdEf"} and receive a comments array where each entry carries the comment text, the commenter's username, and the comment's own like_count, plus an end_cursor for reading further into long threads. Unlike a post lookup, which returns the content and aggregate counts, the comments API returns the actual words the audience wrote. It is the raw material for sentiment analysis, community research, and moderation — the qualitative layer behind the engagement numbers.
Build your own Instagram sentiment-analysis tool
Use the Post Comments endpoint to run sentiment analysis on a campaign's reactions, study how a community discusses a topic, or detect spam and abuse under your own posts. Because each comment includes its author and like_count, you can weight the loudest voices, attribute opinions, and rank reactions by how many people agreed. Page through the whole thread with end_cursor, then feed the text into the YepAPI AI endpoints for classification or summarization without leaving one key.
Instagram Post Comments API pricing — $0.01 per call
Each page of comments costs a flat $0.01, with no tiers or minimums. Reading a long thread across several paginated pages stays in the cents range, and the spend shares one balance with every YepAPI endpoint — including the AI calls you might use to analyze the text. You pay per call only, so comment mining scales with thread depth.
Public comment threads the official API gates
Instagram's official Graph API exposes comments only on media you own or manage through a business account. The YepAPI Post Comments API returns the public comment thread of any post by shortcode, so you can analyze sentiment on a competitor's launch or a creator's viral post you have no control over — research the official API does not permit.
Try the Instagram Post Comments API free
Sign up for $5 in free credit, no card needed. That is 500 comment-page calls — enough to mine and analyze the threads on many posts before you pay a cent.
Start making API calls in 30 seconds
$5 free credit on signup. No credit card required. Pay per call.
What developers say
“Switched from SerpAPI and cut our SERP costs by 80%. Same data quality, way simpler billing.”
“One API key for AI models, SERP data, and web scraping. Saved us from managing 4 separate providers.”
“The $5 free credit let us prototype our entire rank tracking feature before committing. No other API does that.”
Frequently asked questions
Fetch comments on any Instagram post by shortcode. Returns comment text, author info, and likes with pagination.
Each API call costs $0.01. No monthly minimums or subscriptions — you only pay for what you use.
Sign up for a free API key, then send a POST request to /v1/instagram/post-comments. Check the code example above for a ready-to-use snippet in JavaScript, cURL, or Python.
YepAPI bundles SEO, AI, and web scraping APIs under one key with no monthly minimums. You get lower per-call pricing, a unified dashboard, and one billing account instead of managing multiple providers.
Ready to integrate?
Get your API key and start making calls in 30 seconds. $5 free credit on signup — no credit card required.
More instagram api endpoints
Search
$0.01Search Instagram users, hashtags, and places. Discovery and research from $0.01/call.
User
$0.01Get Instagram user profiles — followers, bio, posts count, and verification from $0.01/call.
User About
$0.01Get extended Instagram user info — account category, contact details, and business info from $0.01/call.