Alternative · Open source

instagrapi alternative: public Instagram data without a login

instagrapi is the most complete open-source Instagram library for Python: it logs in, reads, posts and sends DMs. If all you need is public data, here is what running it costs and when an API is simpler.

Short answer. instagrapi is a free, MIT-licensed Python wrapper for Instagram’s web and private mobile APIs. It still works (3.2.24 shipped on 30 November 2026) and does things no read-only API does: uploads, DMs, insights for your account. But it works through a logged-in Instagram account, and its own README calls private-API automation fragile in production: account trust, proxies, device state, challenges and 429s.

If you post, message or automate accounts you own, keep instagrapi. If you read public profiles, posts, comments and followers for a product, a hosted API takes the accounts and proxies off your plate: HandleHaul answers with JSON at $1.40 to $0.80 per 1,000 calls.

Facts checked 2 December 2026. Prices change: follow the links before you decide.

instagrapi 3.2.24 (30 November 2026) · MIT licence · about 7.2k GitHub stars (December 2026) · maintained by subzeroid and contributors · Python 3.11+. Sources: GitHub · PyPI · docs, read 2026-12-02.

What instagrapi does well

  • Write actions. Upload photos, videos, reels and stories (with mentions, links and stickers), send and read Direct messages, and work with comments. A public-data API like HandleHaul is read-only and never will do these.
  • Your own account’s private data. Insights, notifications, your DMs and collections. None of that is public, so only a logged-in client can read it.
  • Breadth. Users, media, comments, stories, highlights, hashtags, locations, notes, search, and follower sorting by follow date order on the mobile API. Async users have a sister library, aiograpi.
  • Honest docs. The README and best practices are frank about what breaks and how to handle 429s, challenges and relogins. Few projects are this clear.

Where instagrapi hurts in production

  • A logged-in account is required for real work. The README says anonymous public paths are opportunistic rather than guaranteed, and that production work should use authenticated sessions. So every job runs through an Instagram account you own and can lose.
  • One account per stable IP. The best practices recommend one account per stable proxy or IP, gradual warm-up for new accounts, random delays between requests and limited concurrency per account. Scaling reads means scaling accounts and proxies.
  • Blocks you have to handle. ClientThrottledError (429), PleaseWaitFewMinutes, FeedbackRequired and ChallengeRequired each need their own handling. The guide notes that some newer challenge paths may still need manual review.
  • By its own description. The README says the project is “best suited for testing, research, and controlled internal automation”, and points account-owned business workflows to Instagram’s official APIs.

instagrapi vs a hosted API

instagrapi compared with HandleHaul, by requirement
RequirementinstagrapiHandleHaul
Instagram login neededYes, for reliable useNo, an API key only
Your accounts at riskEvery account you automateNone: we never log in to accounts
ProxiesOne stable proxy or IP per account recommendedNot needed
Rate limits429, please-wait and feedback blocks per account10 to 30 requests per second by tier
Private accountsOnes the logged-in account can seeNo, public only (the call is free)
Posting, DMs, insightsYesNo, read-only
Public profiles, posts, comments, followersYesYes
LanguagesPython (REST wrapper available)Any HTTP client; Python and Node SDKs
CostFree licence; you pay for accounts, proxies, servers, upkeep$1.40 to $0.80 per 1,000 calls
MaintenanceSession storage, challenge handling, upgradesOurs; failed calls are free

Same job, both ways

Profile and follower count of @natgeo. instagrapi logs in first; HandleHaul needs an API key.

instagrapi
from instagrapi import Client

cl = Client()
cl.login(USERNAME, PASSWORD)       # a real Instagram account
cl.dump_settings("session.json")   # reuse the session next run

user = cl.user_info_by_username("natgeo")
print(user.pk, user.follower_count, user.media_count)

followers = cl.user_followers(user.pk, amount=100)  # dict: pk -> UserShort
From the instagrapi README and user guide. Store the session and reload it; repeated fresh logins invite challenges.
import os, requests

r = requests.get(
    "https://api.handlehaul.com/v1/instagram/users/by-username/natgeo",
    headers={"X-Api-Key": os.environ["HANDLEHAUL_API_KEY"]},
)
print(r.json()["data"])
HandleHaul: key in HANDLEHAUL_API_KEY, 1 credit per successful call. The profile call is the lookup, so it never adds a lookup credit.

For the 100 followers, call /v1/instagram/users/{user}/followers four times (25 per page) with the id from the profile. Code on the Instagram followers API page.

Running it yourself vs paying per call

instagrapi is free. What production costs is everything around it, and none of it has a fixed price:

  • Instagram accounts, warmed up slowly, plus replacements for ones that get challenged or restricted.
  • A stable proxy or IP per account, which the docs recommend over rotating pools.
  • Session storage, relogin logic and handlers for each block type.
  • Engineer time on challenges and on upgrades when Instagram changes its private API.

We will not guess those numbers for you. HandleHaul’s side is plain arithmetic:

HandleHaul cost per job
JobCallsHandleHaul cost
One profile1$0.00080 to $0.00140
100 followers (25 per page)4$0.00320 to $0.00560
1,000 followers40$0.032 to $0.056

1 credit per successful call; failed calls and cache hits are free. Naming an account by a handle we have not looked up in the last 7 days adds 1 lookup credit; send the numeric id from any result to skip it. See pricing.

When to keep using instagrapi

  • You post, schedule or reply for accounts you own or manage.
  • You need DMs, insights or other data that is never public.
  • It is a test, research or internal tool where a blocked account is an inconvenience, not an outage.
  • You already run accounts and proxies and they are stable.

For posting on accounts you manage, Instagram’s official API is also worth a look; the instagrapi README suggests it for account-owned business workflows. See our Graph API guide.

Migrating from instagrapi: field map

instagrapi’s User model and the matching fields in the /v1/instagram/users/by-username/{username} response.

instagrapi attributes mapped to HandleHaul response fields
instagrapiHandleHaulNote
user.pkdata.id
user.usernamedata.username
user.full_namedata.full_name
user.biographydata.biography
user.follower_countdata.counts.followers
user.following_countdata.counts.following
user.media_countdata.counts.posts
user.is_privatedata.is_private
user.is_verifieddata.is_verified
user.external_urldata.external_url
user.is_businessdata.is_business
user.category_namedata.category
user.profile_pic_url_hddata.profile_pic_url_hd
cl.user_followers(pk)GET …/followers → data[]list, newest first, not a dict

Follower rows have id, username, full_name, is_private, is_verified, profile_pic_url and position. Public emails, phone numbers and addresses from the User model are not in the HandleHaul profile.

Full fields and errors: Instagram profile API docs, Instagram followers API docs, Instagram posts API docs.

instagrapi alternative: questions

Does instagrapi still work in 2026?
Yes. 3.2.24 was released on 30 November 2026 and the project is active. Whether it works for you depends more on your accounts, proxies and request pattern than on the library.
Can I use instagrapi without logging in?
Some public lookups run without a login, but the README calls those paths opportunistic and recommends authenticated sessions for production. If you want no login at all, use a hosted public-data API.
What is the best Instagram API for Python?
It depends on the job. To post or send DMs for your accounts: Instagram’s official API, or instagrapi for internal tools. To download media: Instaloader. To read public data in an app without accounts: an HTTP API such as HandleHaul (pip install handlehaul).
Can HandleHaul post to Instagram or send DMs?
No. HandleHaul is read-only and public-data only: profiles, posts, reels, comments, followers, stories, hashtags and places. For write actions use Instagram’s official API or a library that logs in.
Why do I get ChallengeRequired or PleaseWaitFewMinutes?
Instagram is asking the account to verify or slow down. instagrapi’s best practices suggest stable IPs per account, random delays, lower concurrency, and stopping to inspect the account by hand after repeated challenges.
Is it allowed to use these tools?
That depends on what you collect, why, and where you are. Check Instagram’s terms and the data protection law that applies to you; we do not give legal advice. HandleHaul serves public data only, under our acceptable use policy.

Public Instagram and TikTok data, one API key

No accounts, proxies or browsers to run. $1.40 to $0.80 per 1,000 calls.

Want to test first? Sandbox keys are free and unlimited, with sample data in the live schema.