Most APIs hand you a key in a dashboard and you are done. Meta does it differently. Every call to the official Instagram API carries an access token that a professional account granted to your app. This guide follows Meta's documentation as read in November 2026.
There is no Instagram API key
Three credentials replace it:
| Credential | Where it comes from | What it does |
|---|---|---|
| App ID | App Dashboard of your Meta app | Identifies your app in the login flow |
| App secret | App Dashboard, kept on your server | Exchanges codes and short-lived tokens |
| Access token | Granted by an Instagram professional account | Sent with each API call |
Access tokens follow the OAuth 2.0 protocol and are app-scoped: a token works for your app and the account that granted it, and nothing else.
Before you start
- A Meta developer account.
- An Instagram professional account, business or creator. With Instagram Login the account does not need a Facebook Page. With Facebook Login for Business it must be linked to one.
- A redirect URL on your server to receive the authorization code.
How to get an Instagram access token, step by step
The steps below use Instagram Login (Business Login for Instagram), which calls the API on graph.instagram.com.
1. Create a Meta app
In the App Dashboard, create an app, pick the Other use case and choose the Business type. Only a business type app can add the Instagram product.
2. Add the Instagram product
Adding Instagram sets up API setup with Instagram login. Your Instagram app ID and app secret sit under Business login settings in that section. While you build, add your own account as a tester in App Roles.
3. Send the account owner to the authorization window
https://www.instagram.com/oauth/authorize ?client_id=YOUR_INSTAGRAM_APP_ID &redirect_uri=https://yourapp.com/auth/callback &response_type=code &scope=instagram_business_basic,instagram_business_manage_comments
After consent, Instagram redirects to your URL with a code. The code is valid for 1 hour and works once.
4. Exchange the code for a short-lived token
curl -X POST https://api.instagram.com/oauth/access_token \ -F client_id=YOUR_INSTAGRAM_APP_ID \ -F client_secret=YOUR_INSTAGRAM_APP_SECRET \ -F grant_type=authorization_code \ -F redirect_uri=https://yourapp.com/auth/callback \ -F code=CODE_FROM_THE_REDIRECT
The response holds the access token, the user ID and the permissions granted. This token is valid for 1 hour.
5. Swap it for a long-lived token
curl -G https://graph.instagram.com/access_token \ --data-urlencode "grant_type=ig_exchange_token" \ --data-urlencode "client_secret=YOUR_INSTAGRAM_APP_SECRET" \ --data-urlencode "access_token=SHORT_LIVED_TOKEN"
The long-lived token is valid for 60 days. Meta requires this call to run in server-side code, since it carries your app secret.
6. Refresh it before day 60
curl -G https://graph.instagram.com/refresh_access_token \ --data-urlencode "grant_type=ig_refresh_token" \ --data-urlencode "access_token=LONG_LIVED_TOKEN"
A token can be refreshed once it is at least 24 hours old and still valid, if the user granted instagram_business_basic. The new token lasts 60 days from the refresh. A token left 60 days without a refresh expires and the account owner has to log in again.
Permissions you can request
With Instagram Login, the scopes you can ask the account owner for are:
- instagram_business_basic: profile fields and media of the account.
- instagram_business_content_publish: publishing posts.
- instagram_business_manage_comments: reading and replying to comments.
- instagram_business_manage_messages: Instagram Direct messages.
Apps that use Facebook Login for Business request the instagram_basic family instead, plus Page permissions. An app uses one login or the other, never both.
Standard Access, Advanced Access and App Review
- Standard Access is the default. It covers people who have a role on your app and professional accounts you own or manage. No App Review needed.
- Advanced Access is required when your app serves professional accounts you do not own, for example as a tool sold to other businesses. It requires App Review and Business Verification.
Rate limits and the data each access level returns are covered in the Instagram API guide.
When an access token is the wrong tool
A token only opens the accounts that granted it, plus a few public fields of other professional accounts through Business Discovery. It never returns a followers list or the email shown on someone else's profile. If your project needs the people behind a competitor, a hashtag or a post, a data API does that job with a plain API key and no Instagram login.
curl -X POST https://api.igleads.ai/v1/leads/competitors \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "usernames": ["yourcompetitor"], "limit": 500 }'The key comes from your dashboard on the Business ($199 a month) and Scale ($399 a month) plans. Endpoints and filters are on the developer page. The followers API guide walks through a full search in Python.
Frequently asked questions
Is there an Instagram API key?
No. The official Instagram API uses an app ID, an app secret and OAuth access tokens. The token is what you send with each call, so it plays the role an API key plays elsewhere.
How long does an Instagram access token last?
A token from the login flow is short-lived and valid for 1 hour. You can exchange it for a long-lived token valid for 60 days, then refresh it once it is at least 24 hours old. A token not refreshed within 60 days expires for good.
Can I get an access token for a personal Instagram account?
No. Every way into the official API requires an Instagram professional account, business or creator. The Basic Display API, which served personal accounts, stopped on December 4, 2024.
Do I need App Review to get an access token?
Not for accounts you own or manage and have added to your app: Standard Access covers them. As soon as your app serves professional accounts you do not own, you need Advanced Access, which requires App Review and Business Verification.