Instagram Hashtag search API
Recent posts under a hashtag with cursor pagination: shortcode, type, caption and media URL.
Provider network
Providers ranked by traffic
Try it
Make your first request
{
"found": true,
"data": {
"posts": [
{
"id": "3714950709444987377",
"shortcode": "DOOJ_zSjcnx",
"type": "XDTGraphVideo",
"url": "https://www.instagram.com/reel/DOOJ_zSjcnx/",
"caption": "Launch day! 🚀 #spacex",
"displayUrl": "https://instagram.com/reel/DOOJ_zSjcnx/media.jpg"
}
]
}
}interface InstagramSearchHashtagResponse {
data: {
nextCursor: string | null;
posts: {
avatarUrl?: string;
caption: string;
comments?: number;
createdUtc?: number;
displayUrl: string;
durationSeconds?: number;
id: string;
isAd?: boolean;
likes?: number;
shortcode: string;
type: string;
url: string;
username?: string;
verified?: boolean;
videoUrl?: string;
}[];
} | null;
found: boolean;
}Full parameter and response reference - every field, type, and example for this endpoint.
Reference
Request, response, and price
Last verified 2026-09-16 · uptime and latency measured over 30dcurl -X POST https://api.getanyapi.com/v1/run/instagram.search_hashtag \
-H "Authorization: Bearer $ANYAPI_KEY" \
-H "Content-Type: application/json" \
-d '{"hashtag":"spacex"}'| Field | Type | Example value |
|---|---|---|
| Request body | ||
| hashtag | string | "spacex"Hashtag to search, without the leading #. |
| cursor | string | Pagination cursor from a previous response. |
| datePosted | enum | Restrict results to posts published within this window. |
| mediaType | enum | Filter by media type. One of all, reel. |
| requireFields | array | Optional; omit it and routing is unchanged, with the cheapest source serving. Name the output fields this request must be able to return, for example `isAd`, and it is served only by a source that returns every one of them. Fields you do not name are still returned whenever the serving source has them. This can raise your price: when the cheapest source cannot return a named field, a dearer source serves, and you are quoted and charged its price. A named field can still be absent on a post that genuinely lacks it. Naming a combination that no single source returns together is refused as invalid input, with no charge. On a paginated walk it applies to the first page only; later pages stay with the source that page chose, at the price it was quoted. |
| Response | ||
| found | boolean | true |
| data | object | |
| data.posts | array | |
| data.posts[].id | string | "3714950709444987377" |
| data.posts[].shortcode | string | "DOOJ_zSjcnx" |
| data.posts[].typecan require | string | "XDTGraphVideo" |
| data.posts[].url | string | "https://www.instagram.com/reel/DOOJ_zSjcnx/" |
| data.posts[].captioncan require | string | "Launch day! 🚀 #spacex" |
| data.posts[].displayUrl | string | "https://instagram.com/reel/DOOJ_zSjcnx/media.jpg" |
| Price | ||
| Price per request | USD | $0.0012 |
| Price /1k req | USD | $1.20 |
FAQ
About the Instagram Hashtag search API
The AnyAPI Instagram Hashtag search API returns Instagram hashtag search data as normalized JSON from one POST call to /v1/run/instagram.search_hashtag. Recent posts under a hashtag with cursor pagination: shortcode, type, caption and media URL. AnyAPI routes each request across 2 sources and falls back automatically when one fails. It costs from $1.20 per 1,000 requests, in US dollars with no subscription and no monthly minimum. Over the last 30 days, 93.6% of Instagram hashtag search calls through AnyAPI succeeded, with a median response time of 4.9 seconds across 3,439 measured calls.