GETInsights2 credits
Analyze hashtag
GET https://api.instagramapi.dev/v1/insights/hashtagSamples a hashtag's top and recent posts to estimate how competitive it is (average engagement a top post needs, a 0–100 difficulty score) and how fast it moves (posts per hour). Use it to choose hashtags you can realistically rank for. Cost: 2 credits.
Build this with an AI agent
Paste this prompt into Claude, Codex, or any coding agent.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| tag | string | yes | Hashtag without the `#`. |
Example request
curl "https://api.instagramapi.dev/v1/insights/hashtag?tag=sunset" \
-H "Authorization: Bearer $INSTAGRAMAPI_KEY"Try it
Live request · uses 2 creditsExample responses
Switch tabs to see the body shape for success and each error status.
{
"data": {
"tag": "sunset",
"top_sample": 9,
"recent_sample": 18,
"top_avg_engagement": 84210,
"top_avg_likes": 82900,
"top_avg_comments": 1310,
"posts_per_hour": 4200,
"difficulty_score": 71,
"difficulty_label": "high"
},
"meta": {
"endpoint": "insights/hashtag",
"request_id": "req_3f8a1c9e",
"credits_charged": 2,
"credits_remaining": 4987,
"ms": 412
}
}Response fields
Fields returned under data on a 200 response. Every response also includes a meta object with billing info.
| Field | Type | Description |
|---|---|---|
| tag | string | The hashtag analyzed (without the #). |
| top_sample | number | How many top posts were sampled. |
| recent_sample | number | How many recent posts were sampled. |
| top_avg_engagement | number | Average interactions (likes + comments) of a top post. |
| top_avg_likes | number | Average likes of a top post. |
| top_avg_comments | number | Average comments of a top post. |
| posts_per_hour | number | Estimated number of new posts per hour for the hashtag. |
| difficulty_score | number | How hard it is to rank for the hashtag (0–100). |
| difficulty_label | string | Plain-English difficulty (e.g. low / medium / high). |