All-in-One Instagram Scraper avatar

All-in-One Instagram Scraper

Pricing

from $1.56 / 1,000 profile results

Go to Apify Store
All-in-One Instagram Scraper

All-in-One Instagram Scraper

Instagram scraper β€” 11 modes: profiles, posts, reels, comments, hashtags, tagged, search, followers count & more. No browser needed β€” HTTP-only, 256MB, fast. Premium residential proxy (~95% success rate). Pay per result: 40% cheaper. MCP-ready for AI agents.

Pricing

from $1.56 / 1,000 profile results

Rating

0.0

(0)

Developer

Japi Cricket

Japi Cricket

Maintained by Community

Actor stats

1

Bookmarked

82

Total users

26

Monthly active users

2 hours ago

Last modified

Share

All-in-One Instagram Scraper

All-in-One Instagram Scraper

Scrape Instagram profiles, posts, reels, comments, hashtags, tagged posts, search results, and follower counts β€” 11 modes in 1 actor (including a built-in cookie health monitor). Up to 40% cheaper than alternatives on every mode. No login required for most modes. HTTP-only, runs on 256–512 MB. Exact (non-rounded) engagement numbers via profile-lookup strategy. You only pay for results with actual data β€” empty results and input-validation errors are never charged.

What's new (April 2026 release)

  • βœ… Reliable latestPosts across every profile in a batch. Fixed a case where Instagram would silently strip the embedded-posts array on later profiles of a large batch. You now get the full up-to-12 latest posts on every profile β€” Profile, Data Extractor, and All-in-One all benefit automatically.
  • ⚑ Followers Count is now ~4Γ— faster at large batch sizes. Runs with 25+ usernames finish in ~70 seconds instead of 5+ minutes, with no change in accuracy.
  • πŸ›‘οΈ Fail-fast cookie check for Comments + Search. If your IG_LOGIN_COOKIES are expired, the run aborts in 2 seconds with a clear error item β€” and you are not billed. No more burning minutes on a dead session.
  • πŸ“Š Transparent cost reporting. Every run now emits a bandwidth_report item with a per-tier breakdown (residential vs datacenter bytes + USD cost). Use it to audit your spend and benchmark modes against each other.
  • 🚦 Per-category error counter in quality_report. See rate-limit, login-required, blocked, and deleted-account tallies at a glance β€” plot them over time to spot Instagram pressure before it breaks your pipeline.
  • πŸ’¨ Faster same-owner post/reel batches. Scraping 10 posts from the same creator now runs ~50% faster β€” the scraper recognises cache hits and shortens its inter-item pacing automatically.
  • πŸ“‰ Posts ↔ reels residential-proxy bandwidth down ~20-30%. We stopped making requests that Instagram rejects (known-dead GraphQL hashes, redundant HTML meta scrapes) β€” no data loss, just fewer wasted bytes.
  • πŸ’° Updated pricing schedule (see table below) β€” Search dropped to $0.90/1K and Followers Count to $0.78/1K, both 40% below the closest competitor.

Getting Started

  1. Click "Try for free" at the top of this page
  2. Choose a scraping mode from the dropdown
  3. Add your input β€” usernames, URLs, hashtags, or search queries
  4. Click Start β€” results appear in the Dataset tab within seconds
  5. Download as JSON, CSV, or Excel β€” or connect via API, n8n, Make, or Zapier

No login required. Just paste and scrape.

11 Scraping Modes

ModeDescriptionBest ForCookies needed?
Profile ScraperFull profile + up to 12 latest posts with engagementLead enrichment, influencer researchNo
Post ScraperIndividual posts by URL: caption, likes, media URLsContent monitoringNo (limited)
Reels ScraperReels with play counts, audio info, engagementTrend analysisNo (limited)
Comments ScraperComments with author info, likes, threaded repliesSentiment analysisYes
Hashtag ScraperHashtag metadata: ID, description, profile pictureHashtag researchNo
Tagged PostsProfile + latest posts for tagged/mentioned usersInfluencer discoveryNo
Search ScraperSearch for users, hashtags, or placesProspectingYes
Followers CountLightweight follower/following/post countsMonitoring, trackingNo
All-in-OneCombine profiles + posts + hashtags + search in one runMulti-type extractionNo
Data ExtractorLightweight bulk profile extractionLarge-scale data collectionNo
MonitorCookie health check + run failure analysisAutomated alertingNo (reads from KV store)

Standard vs Enhanced Mode (Cookies)

Without cookies, most modes work great. With cookies, you unlock exact metrics and additional fields:

ModeWithout cookiesWith cookies
Profile ScraperFull data (all fields)+ Business email & phone via mobile API
Post ScraperCaption, owner, image, likes (rounded), dateExact (non-rounded) likes/comments, postId, owner details, tagged users, location, carousel images, dimensions, accessibility caption
Reels ScraperCaption, owner, thumbnail, likes (rounded), dateExact likes/comments, plays, shares, saves, audio info, video URL, video duration, tagged users
Comments ScraperEmpty resultsFull comments with author info, likes, threaded replies
Hashtag ScraperName, ID, description, mediaCount+ topPosts array with the 9-10 top posts currently trending for the tag
Tagged PostsProfile + latest posts+ Actual tagged media feed (historical posts where the user was tagged)
Search ScraperBasic result list (no follower counts)Full results with follower counts, following, posts count, and bio via per-result enrichment
Followers CountFull dataSame β€” no cookies needed

Cookies: bring your own (customer-supplied)

8 of 11 modes work fully cookieless (Profile, Post, Reel, Hashtag, Tagged, Followers Count, All-in-One, Data Extractor). Only Comments and Search require cookies β€” Instagram blocks both endpoints to anonymous requests.

Important: this actor does NOT include any Instagram cookies for customer runs

When a mode requires authentication, you must paste your own cookies into the loginCookies input field. There is no shared cookie pool, no built-in fallback, and no operator-side cookie injection β€” every authenticated run uses the cookies you provide, attributing the activity to your Instagram account.

This is intentional. Account-flag risk lives with the supplied cookies, not with the actor author. Top-MAU IG comment + search scrapers on Apify (apify/instagram-comment-scraper, apify/instagram-search-scraper) follow the same pattern.

Customer usage β€” supply cookies via input

{
"scrapeMode": "instagram-comment-scraper",
"postURLs": ["https://www.instagram.com/p/SHORTCODE/"],
"loginCookies": "sessionid=...; csrftoken=...; ds_user_id=...; ig_did=...; mid=...; datr=..."
}

Get the cookies from a logged-in browser session: DevTools β†’ Application β†’ Cookies β†’ instagram.com β†’ copy the standard set (sessionid, csrftoken, ds_user_id, ig_did, mid, datr) into a single semicolon-separated string. The scraper also accepts JSON-object and JSON-array formats β€” see the loginCookies field description in the input schema.

The 8 cookieless modes don't need any of this β€” just pass profiles, postURLs, hashtags, or searchQueries and run.

Operator daily-testing only

The daily-test orchestrator passes the operator's cookies via input.loginCookies (same input field customers use). This keeps customer and operator paths uniform and prevents accidental operator-cookie leakage to customer runs. The IG_LOGIN_COOKIES environment variable is no longer read by the scraper as of build 2026-05-08 β€” it remains in place only to feed the daily-test orchestrator and the cookie-health-check probe.

Always use a dedicated burner Instagram account for testing, never your primary personal account β€” Instagram's "automated behavior" detection treats sustained API access as a flag signal.

Migration note (2026-05-08)

Earlier versions of this actor accepted useAuthMode=true to opt into the IG_LOGIN_COOKIES env var. That fallback has been removed for the customer-vs-operator cookie boundary. The useAuthMode field is preserved in the input schema for backward compatibility but no longer changes behavior β€” to enable authenticated mode, pass cookies via loginCookies.

Recovery posture (when cookies have been flagged)

After an Instagram "Was this you?" / "automated behavior" warning, set these env vars on your actor before the next run:

Env varRecommended valueEffect
IG_COOLOFF_UNTIL2026-MM-DDT00:00:00Z (β‰₯7 days from flag)Refuses ALL runs until date passes β€” even probes
IG_MAX_RUNS_PER_HOUR2Hard cap (overrides default 5/hr)
IG_MAX_RUNS_PER_DAY10Hard cap (overrides default 30/day)
IG_SESSION_CALL_CAP50Soft per-run cap (default 100)

Halt-on-first-AUTH_EXPIRED is hardcoded β€” the run stops on the first auth failure, not after 3 retries.

Pricing β€” Pay Per Result

Effective 2026-04-24 (build 0.1.144). See docs/pricing-strategy.md for cost rationale + tier-discount math. Empty results and input-validation errors are not billed.

ModePrice / 1,000Best-seller on Apify StorePosition
Profile Scraper$1.38$2.3040% cheaper
Post Scraper$4.18$2.30premium (exact counts + video + audio; 65% gross margin over residential-proxy bandwidth)
Reels Scraper$5.32$2.30premium (exact plays + shares + saves + audio; 65% gross margin)
Comments Scraper$1.14$1.9040% cheaper
Hashtag Scraper$1.38$2.3040% cheaper
Tagged Posts$1.38$2.3040% cheaper
Search Scraper$0.90$1.5040% cheaper
Followers Count$0.78$1.3040% cheaper
All-in-One (scraper-result)$1.38$2.3040% cheaper
Data Extractor$1.38$2.3040% cheaper
MonitorFreeβ€”ops tool

Why Post / Reel cost more than the best sellers: those modes deliver exact (non-rounded) engagement numbers + video URLs + audio metadata, which requires authenticated Instagram GraphQL/media-info calls via residential-proxy bandwidth. The $0.50/1K-tier scrapers round counts ("2M likes") and omit video URLs. If rounded counts are acceptable for your use case, use the cheaper competitors β€” we optimise for full fidelity.

Cost examples:

  • 10 profiles with 3 posts each embedded: ~$0.014
  • 100 follower counts in a single batch: ~$0.078
  • 5 posts by URL (exact counts + video URL): ~$0.021
  • 50 search results (users + hashtags + places): ~$0.045
  • 2 posts Γ— 50 comments each = 100 comments: ~$0.114

πŸ›‘οΈ Built-in reliability (2026-04-24)

The scraper now ships with several runtime safeguards so you don't silently lose results or burn compute on avoidable failures:

SafeguardWhat it catchesCustomer benefit
Eager cookie pre-flight (Comments + Search)Expired / invalid IG_LOGIN_COOKIES β€” Instagram returns a login-wall shape instead of dataRun aborts in ~2 s with resultType: "input_validation_error" and a hint field explaining the fix. Zero billing.
Empty-edges auto-fallback (Profile / Data Extractor / All-in-One)Instagram throttles the datacenter IP after ~5 profiles per run, silently stripping latestPostsDetects the stripped response, auto-rotates to a residential IP for the rest of the run. Every profile in the batch gets its embedded posts
Cache-poisoning guardA throttled response caching an empty timeline for 5 minutesProfileCache refuses to cache profiles where postsCount > 0 but latestPosts is empty β€” stale posts-free data can't leak into subsequent Post/Reel/Tagged callers
latestPosts regression signalSilent parser regressions that deliver empty arrays when posts ARE expectedquality_report.byMode.profile.lowQualityFields now explicitly flags latestPosts when β‰₯ 50 % of posts-bearing profiles return empty arrays
Dead-hash GraphQL skip (Post / Reel)Instagram rotates their query_hash every 2-4 weeks, breaking the GraphQL path silentlyAfter 3 consecutive null responses, the scraper stops calling the dead hash and reaches for cheaper strategies instead β€” you don't pay for wasted residential bandwidth
Adaptive cache-hit delays (Post / Reel)Same-owner batches (e.g. 10 posts from one influencer) pacing as if they were 10 independent scrapesAfter the first post establishes the owner, subsequent items with a profile-cache hit downgrade the inter-item delay from reading (3-15 s) to micro (0.8-4 s) β€” same-owner batches finish ~50 % faster
Per-category error counter (quality_report.errors)Silent Instagram rate-limit pressure that only shows up as slower runsEvery run reports errors.byCategory: {DELETED, RATE_LIMITED, LOGIN_REQUIRED, BLOCKED, NETWORK, …} β€” plot these over time to see if IG is tightening the screws on your proxy/cookie pair
Per-tier bandwidth split (bandwidth_report)Overstated cost estimates that priced every byte at the residential-proxy rateNew fields split residential (evomiCostUsd) vs Apify-datacenter (apifyDcCostUsd) so you can audit the actual per-tier spend. Most modes show ~0 residential bandwidth

All safeguards are automatic β€” no input changes required.

What each run emits in the Dataset

Every run ends with two informational items you can filter out via resultType:

  1. quality_report (penultimate) β€” per-mode fill rates, lowQualityFields array, errors.byCategory object, total + degraded counts
  2. bandwidth_report (last) β€” per-tier bytes/calls/cost breakdown: evomiBytesDown, evomiCostUsd, apifyDcBytesDown, apifyDcCostUsd, totalBandwidthCostUsd

If something went wrong at pre-flight (bad input, missing/expired cookies, unknown mode), a single input_validation_error item replaces everything else, the run aborts, and you are not charged.

None of these report items are billable. Filter them out with resultType in ['profile', 'post', 'reel', 'comment', 'hashtag', 'search'] to get just the data rows.


Mode 1: Profile Scraper

Scrape full Instagram profile data including business info, follower counts, and up to 12 latest posts embedded in each profile.

Input Parameters

ParameterTypeRequiredDescription
scrapeModestringYes"instagram-profile-scraper"
profilesstring[]YesInstagram usernames (with or without @)
maxPostsPerProfileintegerNoLatest posts to include per profile (0-100, default: 12)
loginCookiesstringNoAll browser cookies for business email enrichment

Input Example

{
"scrapeMode": "instagram-profile-scraper",
"profiles": ["cristiano", "instagram", "leomessi"],
"maxPostsPerProfile": 3
}

Output Fields

FieldTypeDescriptionExample
instagramIdstringInstagram user ID"173560420"
usernamestringInstagram handle"cristiano"
fullNamestringDisplay name"Cristiano Ronaldo"
biographystringProfile bio"My official Instagram"
followersCountintegerFollower count672883042
followsCountintegerFollowing count630
postsCountintegerTotal posts4033
isVerifiedbooleanBlue checkmarktrue
isBusinessAccountbooleanBusiness accountfalse
isProfessionalAccountbooleanCreator/professionaltrue
businessCategoryNamestringBusiness category"Athlete"
businessEmailstringPublic email (with cookies)"info@starbucks.com"
businessPhoneNumberstringPublic phone (with cookies)"8007827282"
profilePicUrlstringProfile picture (150px)URL
profilePicUrlHDstringHD profile picture (320px)URL
externalUrlstringWebsite link"https://www.cr7.com"
pronounsstringUser pronouns"he/him"
isPrivatebooleanPrivate accountfalse
profileUrlstringFull profile URL"https://www.instagram.com/cristiano/"
latestPostsarrayUp to 12 latest posts with full engagement dataSee post fields below
latestPostsCountintegerNumber of posts embedded12

Business email enrichment: When cookies are provided, the scraper calls Instagram's mobile API to fetch public_email and public_phone_number β€” fields that the standard web API no longer returns. This works for accounts that have set public contact info in their Instagram Business settings.

Output Example

{
"instagramId": "173560420",
"username": "cristiano",
"fullName": "Cristiano Ronaldo",
"biography": "",
"followersCount": 672883042,
"followsCount": 630,
"postsCount": 4033,
"isVerified": true,
"isBusinessAccount": false,
"isProfessionalAccount": true,
"profilePicUrl": "https://...",
"profilePicUrlHD": "https://...",
"externalUrl": "https://hrbl.me/CR7Pro2col",
"profileUrl": "https://www.instagram.com/cristiano/",
"latestPosts": [
{
"shortCode": "DWpF10RgBRg",
"caption": "Getting ready",
"likesCount": 3058419,
"commentsCount": 22019,
"mediaType": "Carousel",
"displayUrl": "https://...",
"timestamp": "2026-04-02T20:05:16.000Z",
"ownerUsername": "cristiano",
"hashtags": [],
"mentions": [],
"taggedUsers": ["alnassr"]
}
],
"latestPostsCount": 3,
"resultType": "profile"
}

Use Cases

  • Lead enrichment: Enrich CRM contacts with Instagram profile data (bio, followers, website)
  • Influencer research: Analyze follower counts, engagement, and content strategy
  • Competitor monitoring: Track follower growth, posting frequency, and content themes
  • B2B prospecting: Find business email and phone via mobile API enrichment

How to Run

curl "https://api.apify.com/v2/acts/get-leads~all-in-one-instagram-scraper/runs" \
-X POST -H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-d '{"scrapeMode":"instagram-profile-scraper","profiles":["cristiano","instagram"]}'

Mode 2: Post Scraper

Scrape individual Instagram posts by URL or shortcode. Returns caption, likes, comments, media URLs, hashtags, and mentions.

Input Parameters

ParameterTypeRequiredDescription
scrapeModestringYes"instagram-post-scraper"
postURLsstring[]YesPost URLs or shortcodes
loginCookiesstringNoAll browser cookies for exact metrics

Input Example

{
"scrapeMode": "instagram-post-scraper",
"postURLs": [
"https://www.instagram.com/p/DWpF10RgBRg/",
"https://www.instagram.com/reel/DWmZq_Aj5-R/"
]
}

Output Fields

FieldTypeWithout cookiesWith cookies
postIdstringNoYes (exact Instagram pk)
shortCodestringYesYes
captionstringYesYes
likesCountintegerRounded when owner isn't identifiableExact (e.g. 1,637,955 not "2M")
commentsCountintegerRounded when owner isn't identifiableExact (e.g. 14,597 not "15K")
mediaTypestringImage/ReelImage/Video/Carousel/Reel
displayUrlstringYesYes
videoUrlstringNoYes
timestampstringDate onlyFull ISO timestamp
ownerUsername / ownerId / ownerFullName / ownerIsVerifiedmixedPartialAll four populated
hashtagsarrayYes (from caption)Yes
mentionsarrayYes (from caption)Yes
taggedUsersarrayNoYes (e.g. ["natgeotv","hulu"])
locationName / locationIdstringNoYes (if tagged)
dimensionsobjectNoYes ({width, height})
accessibilityCaptionstringNoYes (Instagram AI alt-text)
imagesarrayNoYes (carousel children)
isPaidPartnershipbooleanNoYes
commentsDisabledbooleanNoYes

Output Example

{
"postId": "3880328676760217008",
"shortCode": "DXZsl9mDeWw",
"caption": "Focused and ready ⚽️πŸ’ͺ🏼",
"likesCount": 1669169,
"commentsCount": 14724,
"mediaType": "Carousel",
"displayUrl": "https://scontent-waw2-1.cdninstagram.com/...",
"timestamp": "2026-04-21T17:07:26.000Z",
"ownerUsername": "cristiano",
"ownerId": "173560420",
"ownerFullName": "Cristiano Ronaldo",
"ownerIsVerified": true,
"dimensions": { "height": 1440, "width": 1440 },
"accessibilityCaption": "Photo by Cristiano Ronaldo...",
"taggedUsers": [],
"locationName": null,
"isPaidPartnership": false,
"commentsDisabled": false,
"hashtags": [],
"mentions": [],
"resultType": "post"
}

Use Cases

  • Content monitoring: Track engagement on specific posts
  • Campaign analysis: Measure likes, comments, and reach on branded content
  • Social listening: Extract hashtags and mentions from post captions
  • Media archiving: Save post images, videos, and captions

How to Run

curl "https://api.apify.com/v2/acts/get-leads~all-in-one-instagram-scraper/runs" \
-X POST -H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-d '{"scrapeMode":"instagram-post-scraper","postURLs":["https://www.instagram.com/p/DWpF10RgBRg/"]}'

Mode 3: Reels Scraper

Scrape Instagram reels with play counts, audio info, and engagement metrics.

Input Parameters

ParameterTypeRequiredDescription
scrapeModestringYes"instagram-reels-scraper"
postURLsstring[]YesReel URLs
loginCookiesstringNoAll browser cookies for full metrics

Input Example

{
"scrapeMode": "instagram-reels-scraper",
"postURLs": [
"https://www.instagram.com/reel/DWmZq_Aj5-R/",
"https://www.instagram.com/reel/DWnBCQLj7iW/"
]
}

Output Fields

All Post Scraper fields, plus:

FieldTypeWithout cookiesWith cookies
playsCountintegerNoYes
sharesCountintegerNoYes
savesCountintegerNoYes
videoViewCountintegerPartialYes
videoDurationnumber (seconds)NoYes
audioTitlestringNoYes when reel has named audio (null for "Original audio")
audioAuthorstringNoYes when reel has named audio
audioIsOriginalbooleanNoYes
audioIdstringNoYes
productTypestringNo"clips" for reels

Output Example

{
"postId": "3875111963462821867_787132",
"shortCode": "DXHKcyvEWfr",
"caption": "One trip to Italy is never enough. @StanleyTucci returns...",
"likesCount": 84682,
"commentsCount": 1172,
"mediaType": "Reel",
"playsCount": 4173980,
"sharesCount": 25035,
"savesCount": 0,
"videoViewCount": 4173980,
"videoDuration": 73.32,
"videoUrl": "https://scontent-waw2-2.cdninstagram.com/...",
"displayUrl": "https://scontent-waw2-1.cdninstagram.com/...",
"timestamp": "2026-04-14T13:00:04.000Z",
"ownerUsername": "natgeo",
"ownerId": "787132",
"ownerIsVerified": true,
"dimensions": { "height": 1280, "width": 720 },
"taggedUsers": ["natgeotv", "natgeotravel", "hulu", "disneyplus", "stanleytucci"],
"audioTitle": null,
"audioAuthor": null,
"audioIsOriginal": null,
"productType": "clips",
"resultType": "reel"
}

Use Cases

  • Trend analysis: Identify viral reels by play count and engagement
  • Audio tracking: Monitor trending sounds and music usage
  • Creator benchmarking: Compare reel performance across accounts

How to Run

curl "https://api.apify.com/v2/acts/get-leads~all-in-one-instagram-scraper/runs" \
-X POST -H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-d '{"scrapeMode":"instagram-reels-scraper","postURLs":["https://www.instagram.com/reel/DWmZq_Aj5-R/"]}'

Mode 4: Comments Scraper

Extract comments from posts/reels with author info, likes, and threaded replies. Requires login cookies.

Input Parameters

ParameterTypeRequiredDescription
scrapeModestringYes"instagram-comment-scraper"
postURLsstring[]YesPost/reel URLs to scrape comments from
maxCommentsPerPostintegerNoMax comments per post (1-1000, default: 100)
loginCookiesstringYesAll browser cookies (sessionid, csrftoken, ds_user_id, ig_did, mid, datr)

Input Example

{
"scrapeMode": "instagram-comment-scraper",
"postURLs": ["https://www.instagram.com/p/DWpF10RgBRg/"],
"maxCommentsPerPost": 10,
"loginCookies": "sessionid=XXX; csrftoken=XXX; ds_user_id=XXX; ig_did=XXX; mid=XXX; datr=XXX"
}

Output Fields

FieldTypeDescriptionExample
commentIdstringUnique comment ID"17892368145442706"
textstringComment body"Great photo!"
timestampstringISO timestamp"2026-04-04T03:12:09.000Z"
likesCountintegerComment likes150
repliesCountintegerReply count3
ownerUsernamestringComment author"fan_account"
ownerIdstringAuthor's Instagram ID"8499404141"
ownerIsVerifiedbooleanAuthor verifiedfalse
ownerProfilePicUrlstringAuthor avatar URLURL
postShortCodestringParent post shortcode"DWpF10RgBRg"
isReplybooleanIs this a replyfalse
parentCommentIdstringParent comment (for replies)null

Output Example

{
"commentId": "17892368145442706",
"text": "Yo si le doy el balon",
"timestamp": "2026-04-04T03:13:17.000Z",
"likesCount": 0,
"repliesCount": 0,
"ownerUsername": "rosew_it7",
"ownerId": "71467268730",
"ownerIsVerified": false,
"postShortCode": "DWpF10RgBRg",
"isReply": false,
"parentCommentId": null,
"resultType": "comment"
}

Use Cases

  • Sentiment analysis: Analyze audience reactions to posts
  • Community management: Monitor and respond to comments at scale
  • Engagement research: Study comment patterns and influencer interactions
  • Competitive intelligence: Track audience feedback on competitor content

How to Run

curl "https://api.apify.com/v2/acts/get-leads~all-in-one-instagram-scraper/runs" \
-X POST -H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-d '{"scrapeMode":"instagram-comment-scraper","postURLs":["https://www.instagram.com/p/DWpF10RgBRg/"],"maxCommentsPerPost":10,"loginCookies":"YOUR_COOKIES_HERE"}'

Mode 5: Hashtag Scraper

Get hashtag metadata: hashtag ID, description, and profile picture.

Input Parameters

ParameterTypeRequiredDescription
scrapeModestringYes"instagram-hashtag-scraper"
hashtagsstring[]YesHashtag names (with or without #)
loginCookiesstringNoCookies for top posts

Input Example

{
"scrapeMode": "instagram-hashtag-scraper",
"hashtags": ["travel", "photography", "#fitness"]
}

Output Fields

FieldTypeDescriptionExample
hashtagIdstringInstagram hashtag ID"17841404124112880"
namestringHashtag name (without #)"travel"
profilePicUrlstringHashtag representative imageURL
descriptionstringEditorial description"Watch short videos about travel..."
hashtagUrlstringExplore page URL"https://www.instagram.com/explore/tags/travel/"
topPostsarrayTop posts (with cookies only)Array of post objects

Output Example

{
"hashtagId": "17841404124112880",
"name": "travel",
"profilePicUrl": "https://...",
"description": "Watch short videos about travel from people around the world.",
"hashtagUrl": "https://www.instagram.com/explore/tags/travel/",
"resultType": "hashtag"
}

Use Cases

  • Hashtag research: Discover hashtag IDs for tracking and monitoring
  • Content strategy: Identify trending hashtags for post optimization
  • Brand monitoring: Track branded hashtags

How to Run

curl "https://api.apify.com/v2/acts/get-leads~all-in-one-instagram-scraper/runs" \
-X POST -H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-d '{"scrapeMode":"instagram-hashtag-scraper","hashtags":["travel","fitness"]}'

Mode 6: Tagged Posts Scraper

Scrape profiles along with their latest posts. With cookies, also fetches photos the user is tagged in.

Input Parameters

ParameterTypeRequiredDescription
scrapeModestringYes"instagram-tagged-scraper"
profilesstring[]YesInstagram usernames
maxPostsPerProfileintegerNoPosts per profile (default: 12)
loginCookiesstringNoCookies for actual tagged media feed

Input Example

{
"scrapeMode": "instagram-tagged-scraper",
"profiles": ["cristiano", "instagram"],
"maxPostsPerProfile": 3
}

Output Fields

Same as Profile Scraper β€” returns 1 profile per input with latestPosts embedded.

Output Example

{
"username": "cristiano",
"fullName": "Cristiano Ronaldo",
"followersCount": 672967974,
"latestPosts": [
{ "shortCode": "DWpF10RgBRg", "likesCount": 3058419, "caption": "Getting ready" }
],
"latestPostsCount": 3,
"resultType": "profile"
}

Use Cases

  • Influencer discovery: Find profiles being tagged by brands
  • UGC monitoring: Track user-generated content mentioning your brand
  • Campaign tracking: Monitor tagged posts from campaign participants

How to Run

curl "https://api.apify.com/v2/acts/get-leads~all-in-one-instagram-scraper/runs" \
-X POST -H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-d '{"scrapeMode":"instagram-tagged-scraper","profiles":["cristiano","instagram"]}'

Mode 7: Search Scraper

Search for users, hashtags, or places on Instagram. Requires login cookies.

Input Parameters

ParameterTypeRequiredDescription
scrapeModestringYes"instagram-search-scraper"
searchQueriesstring[]YesSearch terms
resultsPerPageintegerNoResults per query (default: 50)
loginCookiesstringYesAll browser cookies

Input Example

{
"scrapeMode": "instagram-search-scraper",
"searchQueries": ["fitness influencer", "vegan restaurant"],
"resultsPerPage": 10,
"loginCookies": "sessionid=XXX; csrftoken=XXX; ds_user_id=XXX; ig_did=XXX; mid=XXX; datr=XXX"
}

Output Fields

FieldTypeDescriptionExample
resultTypestringuser, hashtag, or place"user"
usernamestringUsername (for users)"fitnessinfluencernavya"
fullNamestringDisplay name"Navya Singh"
followersCountintegerFollower count (parsed from social context)724000
profilePicUrlstringProfile picture URLURL
isVerifiedbooleanVerified badgefalse
isPrivatebooleanPrivate accountfalse
profileUrlstringProfile URL"https://www.instagram.com/fitnessinfluencernavya/"

Output Example

{
"resultType": "user",
"username": "fitnessinfluencernavya",
"fullName": "Navya Singh",
"followersCount": null,
"isVerified": false,
"isPrivate": false,
"profileUrl": "https://www.instagram.com/fitnessinfluencernavya/",
"input": "fitness influencer"
}

Use Cases

  • Prospecting: Find potential leads or influencers by keyword
  • Market research: Discover accounts in a specific niche
  • Competitor discovery: Find similar accounts in your industry

How to Run

curl "https://api.apify.com/v2/acts/get-leads~all-in-one-instagram-scraper/runs" \
-X POST -H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-d '{"scrapeMode":"instagram-search-scraper","searchQueries":["fitness influencer"],"loginCookies":"YOUR_COOKIES_HERE"}'

Mode 8: Followers Count

Lightweight mode returning just follower/following/post counts. Fast and cheap β€” ideal for monitoring.

Input Parameters

ParameterTypeRequiredDescription
scrapeModestringYes"instagram-followers-count-scraper"
profilesstring[]YesInstagram usernames

Input Example

{
"scrapeMode": "instagram-followers-count-scraper",
"profiles": ["cristiano", "instagram", "leomessi", "starbucks", "nike"]
}

Output Fields

FieldTypeDescriptionExample
usernamestringInstagram handle"cristiano"
fullNamestringDisplay name"Cristiano Ronaldo"
followersCountintegerFollowers672967974
followsCountintegerFollowing630
postsCountintegerTotal posts4034
isVerifiedbooleanVerifiedtrue
isPrivatebooleanPrivatefalse
isBusinessAccountbooleanBusiness accountfalse
profilePicUrlstringProfile pictureURL
profileUrlstringFull URL"https://www.instagram.com/cristiano/"

Output Example

{
"username": "cristiano",
"fullName": "Cristiano Ronaldo",
"followersCount": 672967974,
"followsCount": 630,
"postsCount": 4034,
"isVerified": true,
"isPrivate": false,
"isBusinessAccount": false,
"profileUrl": "https://www.instagram.com/cristiano/",
"resultType": "profile"
}

Use Cases

  • Follower tracking: Monitor follower growth over time with scheduled runs
  • Influencer vetting: Quick follower count check before outreach
  • Competitive benchmarking: Compare follower counts across competitors
  • Dashboard data: Feed follower metrics into analytics dashboards

How to Run

curl "https://api.apify.com/v2/acts/get-leads~all-in-one-instagram-scraper/runs" \
-X POST -H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-d '{"scrapeMode":"instagram-followers-count-scraper","profiles":["cristiano","instagram","leomessi"]}'

Mode 9: All-in-One Scraper

Combine profiles + posts + hashtags + search in a single run. Routes each input to the appropriate scraping function.

Input Parameters

ParameterTypeRequiredDescription
scrapeModestringYes"instagram-scraper"
profilesstring[]NoInstagram usernames
postURLsstring[]NoPost/reel URLs
hashtagsstring[]NoHashtag names
searchQueriesstring[]NoSearch terms (requires cookies)

Input Example

{
"scrapeMode": "instagram-scraper",
"profiles": ["cristiano"],
"postURLs": ["https://www.instagram.com/p/DWjils2FF_9/"],
"hashtags": ["travel"],
"maxPostsPerProfile": 2
}

Output Example

Returns mixed results β€” each item has a resultType field ("profile", "post", "hashtag"):

[
{ "resultType": "profile", "username": "cristiano", "followersCount": 672967974, "latestPosts": [...] },
{ "resultType": "post", "shortCode": "DWjils2FF_9", "likesCount": 57000, "ownerUsername": "instagram" },
{ "resultType": "hashtag", "name": "travel", "hashtagId": "17841404124112880" }
]

Use Cases

  • Multi-type data collection: Scrape profiles, posts, and hashtags in one run
  • Dashboard feeds: Collect mixed data for analytics dashboards
  • One-shot research: Quick exploration across multiple data types

How to Run

curl "https://api.apify.com/v2/acts/get-leads~all-in-one-instagram-scraper/runs" \
-X POST -H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-d '{"scrapeMode":"instagram-scraper","profiles":["cristiano"],"postURLs":["https://www.instagram.com/p/DWjils2FF_9/"],"hashtags":["travel"]}'

Mode 10: Data Extractor

Lightweight extraction mode for bulk profile data at lower cost. Same as Profile Scraper but billed at $1.00/1K instead of $1.56/1K.

Input Parameters

ParameterTypeRequiredDescription
scrapeModestringYes"instagram-data-extractor"
profilesstring[]YesInstagram usernames
maxPostsPerProfileintegerNoPosts per profile (default: 12)

Input Example

{
"scrapeMode": "instagram-data-extractor",
"profiles": ["cristiano", "instagram", "leomessi", "starbucks", "nike"],
"maxPostsPerProfile": 1
}

Output Fields

Same as Profile Scraper.

Use Cases

  • Large-scale data collection: Scrape thousands of profiles at the lowest cost
  • CRM enrichment: Bulk-enrich contact databases with Instagram data
  • Market research: Collect profile data across an entire industry

How to Run

curl "https://api.apify.com/v2/acts/get-leads~all-in-one-instagram-scraper/runs" \
-X POST -H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-d '{"scrapeMode":"instagram-data-extractor","profiles":["cristiano","instagram","leomessi"]}'

What Monitor Mode Does

Monitor mode validates your Instagram cookie and analyzes recent run history before your test schedules run. It catches expired cookies and run failures early, so you get alerted before your production schedules start failing.

Run it with:

{ "scrapeMode": "instagram-monitor" }

What it checks:

  1. Cookie health β€” reads the cookie from the IG_LOGIN_COOKIES env var (or loginCookies input), tests it against the Instagram mobile API, and reports valid, expired, missing_or_malformed, etc.
  2. Endpoint health battery β€” in parallel, pings the 4 IG endpoints the scraper depends on (web_profile_info, tags/web_info, usertags/feed/, topsearch) with response-shape validation. Detects IG-side rotation or breakage BEFORE a production run hits it.
  3. Run history β€” fetches the last 20 runs and categorizes them as successes, failures, or empty results.
  4. Alerting β€” if any issues are found (expired cookie, degraded endpoint, failed runs), stores an alert in the instagram-alerts KV store and optionally POSTs to a webhook.

The scraper resolves login cookies in this order:

  1. loginCookies in your run input β€” highest priority, overrides everything else.
  2. IG_LOGIN_COOKIES environment variable on the actor β€” convenient for scheduled runs so you don't repeat the cookie in every schedule.
  3. No cookies β€” the scraper continues with public-only endpoints. Modes that require auth (Comments, Search) return a helpful info message instead of failing.

When Instagram expires your session, refresh the cookie in one place (the env var) and every scheduled run picks it up automatically.

Setting Up the Monitor Schedule

Create a schedule that runs ~5 minutes before your first test schedule:

SettingValue
Cron55 6 * * * (UTC) β€” runs at 06:55 daily
Input{ "scrapeMode": "instagram-monitor" }
Memory128 MB

The monitor will check the cookie and run history, then your test schedules start at 07:00 knowing the cookie is valid.


How to Get Your Login Cookies

Some modes (Comments, Search) require cookies. Other modes (Post, Reel) return richer data with cookies.

  1. Log into Instagram in your browser
  2. Open Developer Tools (F12) β†’ Application β†’ Cookies β†’ instagram.com
  3. Copy ALL cookie values β€” you need: sessionid, csrftoken, ds_user_id, ig_did, mid, datr
  4. Paste into the Login Cookies field

The scraper accepts multiple cookie formats β€” use whichever is easiest for you:

Standard (recommended):

sessionid=YOUR_SESSION_ID; csrftoken=YOUR_CSRF; ds_user_id=YOUR_USER_ID; ig_did=YOUR_DEVICE_ID; mid=YOUR_MID; datr=YOUR_DATR

JSON object:

{"sessionid": "YOUR_SESSION_ID", "csrftoken": "YOUR_CSRF", "ds_user_id": "YOUR_USER_ID"}

JSON array (browser export format):

[{"name": "sessionid", "value": "YOUR_SESSION_ID"}, {"name": "csrftoken", "value": "YOUR_CSRF"}]

Raw sessionid value:

65432198765%3AaBcDeFgHiJkLmN%3A12

Important: The cookie must include a valid sessionid. Instagram requires this for authentication.

Download Your Data

After every run, download your results in any format:

  • JSON β€” for developers and API integrations
  • CSV β€” for spreadsheets and data analysis
  • Excel (XLSX) β€” for business users
  • XML β€” for data pipelines
  • Google Sheets: Use =IMPORTDATA() with the CSV download link for instant import

All Apify export formats available: JSON, JSONL, CSV, XLSX, XML, HTML Table, RSS.

Key Features

Accuracy

  • Derived profile analytics β€” Profile / Data Extractor / All-in-One outputs include avgLikes, avgComments, engagementRate (4-decimal precision), and medianDaysBetweenPosts computed from latestPosts. Customers no longer have to aggregate raw per-post numbers themselves.
  • Collab + commerce signals on posts β€” coauthorProducers[] (usernames) and productTags[] ([{name, price, merchantUsername}]) populate on posts that have them. Undefined when absent (null = correct).
  • Exact (non-rounded) engagement β€” Post and Reel modes use a profile-lookup + base64url shortcodeβ†’PK strategy that returns real counts like 1,637,955 likes rather than Instagram's rounded "2M" HTML-meta string. Works for any post age, not just the owner's latest 12.
  • Full Unicode hashtag extraction β€” #ζ—₯本, #cafΓ©, #Москва are all captured (regex uses \p{L}\p{N} with the u flag).
  • Hashtag top posts β€” hashtag mode returns the 9-10 currently trending posts for a tag via Instagram's web_info endpoint.
  • Actual tagged media feed β€” Tagged Posts mode uses edge_user_to_photos_of_you + /usertags/<userId>/feed/ to return real tagged media, not just the user's own posts.
  • Search follower enrichment β€” Search mode enriches every user result with exact follower count, following count, posts count, and bio β€” matches what a logged-in Instagram user sees.
  • Business email enrichment β€” with cookies, the mobile API fetches public_email and public_phone_number that the web API no longer returns.
  • Nested carousel videoUrl β€” mixed-media carousels correctly populate videoUrl on each video child.
  • Comments pagination β€” verified working to 100+ comments across multiple GraphQL pages.

Reliability (self-diagnosing runs)

  • Cookie self-healing β€” 3 consecutive LOGIN_REQUIRED errors auto-stops the run early with cookieStatus: "expired" in the summary. No more wasted compute on bulk runs with stale cookies.
  • GraphQL query_hash rotation detector β€” when a hash returns null 5+ times in a row, the run emits a WARN naming the exact hash to rotate in src/utils/constants.js.
  • Retry-After header honored β€” Instagram's rate-limit hint is respected on 429/503 responses, capped at 5 minutes.
  • Pre-flight input validation β€” bad inputs (empty postURLs on Post mode, malformed cookies without sessionid=, etc.) fail-fast in <2 s with NO billing. A {resultType:"input_validation_error"} item lands in the dataset with a clear reason.

Observability

  • Per-run quality report β€” every run ends with a {resultType:"quality_report"} dataset item listing per-field fill rates and a degradedResults counter (items that fell back to rounded HTML meta). Detects silent parser regressions.
  • Structured JSON log events β€” event=run_start and event=run_end lines with all KPIs in one JSON blob, parseable by any aggregator (Datadog, n8n, etc.).
  • Endpoint health battery in Monitor β€” pings the 4 IG endpoints the scraper depends on with response-shape validation. Alerts on rotation before production runs hit it.

Infrastructure

  • No login required for Profile, Followers Count, Post, Reel, Tagged, Hashtag modes.
  • 11 modes in one actor β€” profiles, posts, reels, comments, hashtags, tagged, search, followers count, all-in-one, data extractor, monitor.
  • Chrome TLS fingerprinting β€” Impit impersonates real Chrome browser fingerprints (JA3/JA4).
  • Auto-proxy β€” residential proxy enabled by default; falls through to direct fetch on anonymous endpoints for minimal bandwidth cost.
  • Adaptive anti-detection delays β€” Box-Muller normal-distribution pacing that scales down for single-item runs (no dead idle time on smoke tests).
  • 128 MB memory β€” lightweight HTTP-only architecture, ~87% less than competitors (1024 MB).
  • Node.js 22 runtime β€” ~33 % runtime reduction vs Node 20 from V8 improvements.
  • No charge for empty results β€” you only pay when actual data is extracted.
  • 176 automated unit tests β€” every parser + helper + library module has regression coverage.
  • MCP-compatible β€” works with Claude, GPT, Cursor, and any MCP client.
  • Pay per result β€” no subscription, no monthly fee.

Error Handling

The scraper handles errors gracefully β€” individual failures never crash the entire run:

  • Invalid inputs fail fast β€” empty postURLs on Post mode, malformed cookies without sessionid=, unknown scrapeMode, etc. abort the run in under 2 seconds with NO billing. A {resultType:"input_validation_error"} item lands in the dataset explaining exactly what's wrong.
  • Invalid usernames: Skipped with a warning in the log. Only valid usernames are processed.
  • Profile not found: Profiles that return no data are skipped (not added to the dataset).
  • Rate limits: Honors Instagram's Retry-After header on 429/503 responses (capped at 5 minutes); falls back to exponential backoff + session rotation otherwise.
  • Cookie expired mid-run: After 3 consecutive LOGIN_REQUIRED errors, the scraper stops early with cookieStatus: "expired" + cookieStopReason in the summary. No wasted compute on bulk runs with stale cookies.
  • GraphQL endpoint rotated: Detected automatically β€” when a query_hash returns null 5+ times in a row, a WARN fires naming the exact hash, and the end-of-run summary carries a graphqlRotationWarnings[] array.
  • Private profiles: Basic info (username, bio, follower count) is still returned. Posts are skipped.
  • Partial results: If one profile fails, the rest continue unaffected.
  • Login wall: If Instagram returns a login page, the scraper falls back to alternative data sources.

Check the Run Log tab in Apify Console to see warnings for any skipped or failed items, or inspect the summary record in the run's Key-Value store for a structured JSON breakdown.

Per-run quality report (every run)

Every successful run ends with a final {resultType:"quality_report"} item in the dataset:

{
"resultType": "quality_report",
"totalResults": 12,
"degradedResults": 0,
"byMode": {
"profile": {
"count": 12,
"degraded": 0,
"fields": {
"username": { "filled": 12, "total": 12, "fillRate": 1 },
"followersCount": { "filled": 12, "total": 12, "fillRate": 1 }
},
"lowQualityFields": []
}
}
}

degradedResults counts items that fell back to the HTML-meta (rounded-counts) path β€” filter on the _degraded: true flag if you only want exact values. lowQualityFields flags any field with < 50% fill rate over β‰₯ 2 samples, so silent parser regressions show up immediately in your dataset.

Structured log events

Every run emits two JSON-parseable log lines that aggregators (Datadog, n8n, Zapier Storage, …) can regex on:

INFO event=run_start {"runId":"...","mode":"instagram-profile-scraper","build":"...","inputCounts":{...},"hasLoginCookies":true,"proxyTier":"residential"}
INFO event=run_end {"runId":"...","durationSecs":14,"results":1,"errors":0,"successRate":1,"cookieStatus":"ok","degradedResults":0,"graphqlRotationHashes":[],"memoryMB":102,"qualityFillRates":{"profile":{"username":1,...}}}

Join the two by runId for per-run latency + success-rate dashboards.

Performance Tips

  • Batch your inputs β€” scraping 50 profiles in one run is faster and cheaper than 50 separate runs
  • Use Profile mode for posts β€” Profile Scraper includes up to 12 latest posts with exact engagement data. This is richer and cheaper than Post Scraper mode (which uses meta tags without cookies)
  • Provide cookies for comments β€” Comments mode returns empty without cookies. Copy ALL browser cookies (sessionid, csrftoken, ds_user_id, ig_did, mid, datr)
  • Start with small batches β€” test with 3-5 inputs first, then scale up
  • Check the logs β€” the Run Log shows exactly what was scraped, skipped, or retried
  • Proxy is auto-configured β€” residential proxy is enabled automatically if you leave it empty. Override with custom proxy settings if needed

Daily Limits

There are no Apify-side limits on how many times you can run this scraper.

Instagram-side recommendations:

  • Without cookies: No practical limit β€” requests use Instagram's public web_profile_info API
  • With cookies: ~200 requests per cookie per day recommended. Exceeding this may trigger Instagram rate limits on your session
  • Hashtag mode: Instagram rate-limits explore pages aggressively. The scraper uses 10-second delays between hashtags
  • Profile mode: ~3-5 seconds per profile. 1,000 profiles takes ~60-90 minutes

Tip: For high-volume scraping (1,000+ profiles/day), run without cookies to avoid any Instagram session risk. Profile and Followers Count modes work fully without cookies.

Technical Details

  • Runtime: Node.js 22
  • HTTP library: Impit (Chrome TLS fingerprint impersonation)
  • Memory: 128 MB default (~87 % less than competitors)
  • Speed: ~3-5 s per profile on bulk runs; single-item test runs complete in ~14 s thanks to adaptive idle-pause scaling
  • No login required: Profile and Followers Count modes work fully without cookies
  • Direct fetch: Anonymous endpoints (e.g., web_profile_info when cookies are absent) use direct HTTP; authenticated calls route through residential proxy so cookie-IP pairing stays intact
  • Accuracy-first fallback chain: GraphQL auth β†’ profile-lookup via web_profile_info timeline β†’ shortcodeβ†’PK base64url decode + /api/v1/media/<pk>/info/ mobile API β†’ HTML meta (only as a last resort, flagged _degraded: true)
  • Test coverage: 176 Node-built-in tests covering parsers, helpers, and lib modules β€” run locally with npm test

Limitations

  • Posts/Reels by URL without cookies: profile-lookup + pk-based media info give exact counts on any post age when cookies are present. Without cookies, recent posts (owner's latest ~12) are still exact (via public timeline); older posts fall back to rounded HTML-meta counts and are flagged _degraded: true.
  • Comments: Requires login cookies. Without them the run aborts at pre-flight validation.
  • Search: Requires login cookies. Without them the run aborts at pre-flight validation.
  • Hashtag mediaCount: Comes from Instagram's authenticated web_info endpoint. Without cookies the field is omitted (but hashtag id, name, URL are still populated).
  • Tagged media: Requires cookies. The scraper returns an empty posts array when the tagged tab genuinely has nothing (matches ground truth β€” a null-equals-null response counts as 100 % correct).
  • Private profiles: Only basic info available. Posts are not accessible.
  • Reel audio metadata: audioTitle / audioAuthor are populated only when the reel uses licensed or named audio. Reels that use "Original audio" correctly return null for these fields.

FAQ

Do I need an Instagram account? No. Profile, Followers Count, Post, Reel, Tagged, and Hashtag modes all work without any login or cookies. Optionally provide cookies for richer data on posts/reels, and to unlock Comments and Search modes.

How do I get my cookies? Open Instagram in Chrome β†’ F12 β†’ Application β†’ Cookies β†’ instagram.com β†’ copy ALL cookie values (sessionid, csrftoken, ds_user_id, ig_did, mid, datr) as semicolon-separated pairs.

Why do I need ALL cookies, not just sessionid? Instagram requires the full cookie set (including ds_user_id, ig_did, mid, datr) for GraphQL authentication. With just sessionid and csrftoken, requests get redirected to the login page.

What if a profile returns empty? The scraper retries up to 3 times with different sessions. If it still fails, the profile may not exist, be suspended, or be behind a region-specific login wall. Check the Run Log for details.

How fast is it? Profiles: ~3-5 seconds each. Posts/Reels: ~8 seconds each. Followers Count: ~3 seconds each. Comments: ~2 seconds per page of 50 comments.

Can I scrape private profiles? Partially. You can get basic info (username, bio, follower count, profile picture) but NOT posts, comments, or tagged media from private accounts.

Why are post likes rounded (3M instead of 3,087,331)? Without cookies, post data comes from Instagram's HTML meta tags which show rounded numbers. With cookies, the GraphQL API returns exact counts.

Can I get business emails? Yes β€” with cookies. The scraper calls Instagram's mobile API to fetch public_email and public_phone_number. These fields only appear for accounts that have enabled public contact info in their Instagram Business settings.

Is there a monthly subscription? No. Pay only for results delivered. Higher Apify plans get automatic discounts.

What's the difference between Profile Scraper and Followers Count? Profile Scraper returns full profile data + up to 12 latest posts. Followers Count returns only counts (followers, following, posts) β€” faster and cheaper at $0.78/1K vs $1.56/1K.

MCP Integration for AI Agents

This scraper works with AI agents via the Model Context Protocol (MCP). Connect it to Claude Desktop, Cursor, GPT, or any MCP-compatible client.

Setup:

  1. Go to mcp.apify.com
  2. Add "All-in-One Instagram Scraper" to your MCP server
  3. Ask your AI: "Get the Instagram profile of Cristiano Ronaldo"

Example prompts for your AI agent:

  • "Scrape the Instagram profile of @starbucks and get their follower count"
  • "Get the latest posts from @instagram with engagement metrics"
  • "Find Instagram accounts about fitness influencers"
  • "Get comments from this Instagram post: https://www.instagram.com/p/DWpF10RgBRg/"
  • "Track follower counts for Nike, Adidas, and Puma on Instagram"

Works with Claude Desktop, Cursor, GPT via MCP, and any other MCP-compatible AI client.

Integrations

n8n

  1. Add the Apify node in your n8n workflow
  2. Select "All-in-One Instagram Scraper" as the actor
  3. Configure the scrape mode and input parameters
  4. Connect the output to your CRM, Google Sheets, or database
  5. Schedule to run daily for automated Instagram monitoring

Make.com (Integromat)

  1. Add the Apify module to your scenario
  2. Select "Run Actor" and choose this scraper
  3. Map the JSON output fields to your downstream modules
  4. Use for automated influencer tracking, content monitoring, or CRM enrichment

Zapier

  1. Create a new Zap with Apify as the trigger or action
  2. Select "Run Actor" and configure with this scraper's actor ID: get-leads/all-in-one-instagram-scraper
  3. Map output fields to Google Sheets, HubSpot, Salesforce, or Slack
  4. Trigger on schedule or from a webhook for automated data collection

REST API & SDKs

Use the Apify API, JavaScript SDK, or Python SDK for programmatic access. See examples below.

Code Examples

Python

from apify_client import ApifyClient
client = ApifyClient("YOUR_API_TOKEN")
run = client.actor("get-leads/all-in-one-instagram-scraper").call(run_input={
"scrapeMode": "instagram-profile-scraper",
"profiles": ["instagram", "cristiano"],
})
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
print(f"{item['username']}: {item.get('followersCount', 'N/A')} followers")

JavaScript / Node.js

import { ApifyClient } from 'apify-client';
const client = new ApifyClient({ token: 'YOUR_API_TOKEN' });
const run = await client.actor('get-leads/all-in-one-instagram-scraper').call({
scrapeMode: 'instagram-profile-scraper',
profiles: ['instagram', 'cristiano'],
});
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach(item => console.log(`${item.username}: ${item.followersCount} followers`));

Residential Proxy (Optional)

Set proxyTier to "residential" to route all requests through a residential IP. This prevents cookie sessions from being flagged by Instagram's security system and avoids rate limits on authenticated modes. Residential proxy is included.

When to use:

  • Your cookies expire quickly (Instagram flagging datacenter IPs)
  • You're scraping authenticated modes (comments, reels, followers) at scale
  • You're getting frequent rate limits or CAPTCHAs

Alternative: Supply your own proxy via proxyConfiguration.proxyUrls.


Support

Found a bug? Open an issue via the "Issues" tab on the actor's Apify Store page.

Questions? Contact us at get-leads@apify.com

Other Scrapers by Get Leads

Follow us on LinkedIn for updates, tips, and new scraper releases.

Proxy Tiers

The scraper supports four proxy strategies via the proxyTier input:

TierWho uses residentialBest for
auto (default)Auth-heavy modes: profile, post, reel, comment, tagged, search, all-in-oneMost users β€” balances cost and success rate
noneNobody (datacenter only)Testing, minimum cost
residentialAll modesMaximum success rate, higher cost
customYour own proxy via proxyConfigurationYou have your own residential proxy provider

Why auto? Instagram rate-limits datacenter IPs aggressively on auth endpoints. Without residential proxy, cookie sessions get flagged within minutes and profile scraping success rate drops to ~40%. Residential IPs bring that back to ~95%. Lightweight modes (followers-count, hashtag, data-extractor, monitor) work fine on datacenter IPs.