Extract Instagram Profile Data via API

Structured profile data from any public Instagram account. Follower counts, bio, post history, reels, stories, comments, and engagement metrics. Eight dedicated endpoints, clean JSON responses.

Eight specialized endpoints Profiles / posts / reels / stories / comments / likes Follower / following lists with pagination No browser automation or login required

Instagram Data Access Is a Moving Target

Instagram's official API has been shrinking for years. The Basic Display API was deprecated in 2024. The Graph API requires a Facebook Business account, an approved app, and only gives you access to accounts that have explicitly connected to your application. If you need competitor data, influencer metrics, or market research across accounts you don't own, the official API is useless.

Building your own scraper is a losing game. Instagram rotates its frontend markup weekly, deploys aggressive bot detection, and rate-limits IP addresses without warning. Every library that worked last month is broken this month. Instaloader, instagram-private-api, and every open-source tool face the same cycle: patch, break, patch, break.

Browser automation tools like Puppeteer or Playwright are heavy, slow, and require maintaining session cookies from real Instagram accounts. One wrong move and your account gets suspended. You're not building a product at that point. You're babysitting infrastructure.

Anysite handles the extraction layer so you don't have to. Eight endpoints cover every public data surface on Instagram. Send an API request with a username, get back structured JSON. No Instagram account needed. No Facebook app review. No browser automation. The infrastructure self-heals when Instagram changes its layout, so your pipeline never breaks.

Eight Endpoints for Complete Instagram Data

Every public data surface on Instagram, accessible via a single API key.

User Profile

GET /api/instagram/user

Core profile data for any public Instagram account. Bio, follower count, following count, post count, profile picture, external URL, verification status, and account category.

Parameter Type Description
user string Instagram username (e.g., natgeo)
Response
{
  "username": "natgeo",
  "full_name": "National Geographic",
  "biography": "Experience the world through the eyes of National Geographic photographers.",
  "followers": 283000000,
  "following": 134,
  "posts_count": 32500,
  "profile_pic_url": "https://scontent.cdninstagram.com/...",
  "external_url": "https://www.nationalgeographic.com",
  "is_verified": true,
  "is_private": false,
  "category": "Media/News Company",
  "id": "787132"
}
Cost: 1 credit per profile

User Posts

GET /api/instagram/user/posts

Retrieve posts from any public Instagram account. Returns captions, like counts, comment counts, media URLs, timestamps, and post type (image, carousel, video).

Parameter Type Description
user string Instagram username
count integer Number of posts per page (default: 12)
cursor string Pagination cursor from previous response
Cost: 1 credit per page (12 posts)

User Reels

GET /api/instagram/user/reels

Retrieve reels and stories from any public Instagram account. Includes view counts, like counts, comment counts, video URLs, and thumbnails.

Parameter Type Description
user string Instagram username
count integer Number of reels per page (default: 12)
cursor string Pagination cursor from previous response
Cost: 1 credit per page (12 reels)

User Friendships

GET /api/instagram/user/friendships

Retrieve follower and following lists for any public Instagram account. Each entry includes username, full name, profile picture, verification status, and whether the account is private.

Parameter Type Description
user string Instagram username
type string followers or following
count integer Number of users per page (default: 50)
cursor string Pagination cursor from previous response
Cost: 1 credit per page (50 users)

Post Details

GET /api/instagram/post

Full details for a single Instagram post. Caption, all media URLs (including carousel images), like count, comment count, timestamp, author info, location tag, and tagged users.

Parameter Type Description
url string Instagram post URL or shortcode
Cost: 1 credit per post

Post Comments

GET /api/instagram/post/comments

Retrieve comments on any public Instagram post. Each comment includes the commenter's username, comment text, timestamp, and like count.

Parameter Type Description
url string Instagram post URL or shortcode
count integer Number of comments per page (default: 20)
cursor string Pagination cursor from previous response
Cost: 1 credit per page (20 comments)

Post Likes

GET /api/instagram/post/likes

Retrieve users who liked a specific Instagram post. Each entry includes username, full name, profile picture, and verification status.

Parameter Type Description
url string Instagram post URL or shortcode
count integer Number of users per page (default: 50)
cursor string Pagination cursor from previous response
Cost: 1 credit per page (50 users)

Search Posts

GET /api/instagram/search/posts

Search Instagram posts by keyword or hashtag. Returns matching posts with full engagement data, author info, media URLs, and captions. Ideal for trend research, campaign tracking, and competitive intelligence.

Parameter Type Description
keywords string Search query (keyword or hashtag)
count integer Number of posts per page (default: 20)
cursor string Pagination cursor from previous response
Cost: 1 credit per page (20 posts)

Code Examples

Production-ready examples for extracting Instagram data.

Influencer Analysis

Pull profile data and recent posts, then compute engagement rate and content performance metrics.

import requests

API_KEY = "YOUR_API_KEY"
BASE = "https://api.anysite.io"
headers = {"access-token": API_KEY}

def analyze_influencer(username):
    """Pull profile + recent posts, compute engagement rate."""

    # Step 1: Get profile data
    profile = requests.get(
        f"{BASE}/api/instagram/user",
        headers=headers,
        params={"user": username}
    ).json()

    # Step 2: Get recent posts
    posts_resp = requests.get(
        f"{BASE}/api/instagram/user/posts",
        headers=headers,
        params={"user": username, "count": 12}
    ).json()
    posts = posts_resp.get("posts", [])

    # Step 3: Compute engagement rate
    followers = profile["followers"]
    avg_likes = sum(p["likes"] for p in posts) / len(posts)
    avg_comments = sum(p["comments"] for p in posts) / len(posts)
    engagement_rate = (avg_likes + avg_comments) / followers * 100

    return {
        "username": username,
        "followers": followers,
        "avg_likes": avg_likes,
        "avg_comments": avg_comments,
        "engagement_rate": round(engagement_rate, 2),
        "bio": profile["biography"],
        "is_verified": profile["is_verified"]
    }

# Analyze a batch of influencers
influencers = ["natgeo", "nike", "airbnb"]
for handle in influencers:
    result = analyze_influencer(handle)
    print(f"@{result['username']}: {result['followers']:,} followers, "
          f"{result['engagement_rate']}% engagement")

Hashtag Research

Search posts by hashtag, aggregate top authors, and identify trending content.

import requests
from collections import Counter

API_KEY = "YOUR_API_KEY"
BASE = "https://api.anysite.io"
headers = {"access-token": API_KEY}

def research_hashtag(hashtag, pages=3):
    """Search posts by hashtag and analyze top performers."""
    all_posts = []
    cursor = None

    for _ in range(pages):
        params = {"keywords": hashtag, "count": 20}
        if cursor:
            params["cursor"] = cursor

        resp = requests.get(
            f"{BASE}/api/instagram/search/posts",
            headers=headers, params=params
        )
        data = resp.json()
        all_posts.extend(data.get("posts", []))
        cursor = data.get("cursor")
        if not cursor:
            break

    # Top posts by engagement
    top_posts = sorted(all_posts, key=lambda p: p["likes"] + p["comments"], reverse=True)

    # Most active authors
    authors = Counter(p["author"]["username"] for p in all_posts)

    print(f"Hashtag: {hashtag}")
    print(f"Posts found: {len(all_posts)}")
    print(f"\nTop 5 posts by engagement:")
    for post in top_posts[:5]:
        print(f"  @{post['author']['username']}: {post['likes']} likes, {post['comments']} comments")

    print(f"\nMost active authors:")
    for author, count in authors.most_common(5):
        print(f"  @{author}: {count} posts")

research_hashtag("#sustainablefashion")

Get User Profile

# Get profile data for any public Instagram user
curl -X GET "https://api.anysite.io/api/instagram/user" \
  -H "access-token: YOUR_API_KEY" \
  -G -d "user=natgeo"

Get User Posts

# Get recent posts with engagement data
curl -X GET "https://api.anysite.io/api/instagram/user/posts" \
  -H "access-token: YOUR_API_KEY" \
  -G -d "user=natgeo" -d "count=12"

Get Post Comments

# Get comments on a specific post
curl -X GET "https://api.anysite.io/api/instagram/post/comments" \
  -H "access-token: YOUR_API_KEY" \
  -G -d "url=https://www.instagram.com/p/ABC123/" \
  -d "count=20"

Search Posts by Hashtag

# Search posts by hashtag
curl -X GET "https://api.anysite.io/api/instagram/search/posts" \
  -H "access-token: YOUR_API_KEY" \
  -G -d "keywords=#sustainablefashion" \
  -d "count=20"

CLI Commands

# Get Instagram profile
anysite instagram user --user natgeo

# Get recent posts
anysite instagram user posts --user natgeo --count 12

# Get reels
anysite instagram user reels --user natgeo --count 12

# Get followers
anysite instagram user friendships --user natgeo --type followers --count 50

# Search posts by hashtag
anysite instagram search posts --keywords "#travel" --count 20

Batch Extraction

# usernames.txt contains one Instagram username per line
while read username; do
  anysite instagram user --user "$username" --format json >> profiles.jsonl
done < usernames.txt

Pipeline YAML

# pipeline.yaml — daily influencer monitoring
name: influencer-monitor
schedule: "0 9 * * *"
steps:
  - source: instagram/user
    params:
      user: target_influencer
    output: profile

  - source: instagram/user/posts
    params:
      user: target_influencer
      count: 12
    output: posts

  - filter:
      min_likes: 100

  - output:
      format: json
      path: ./data/influencer-Apr 11, 2026.json

Use Cases

How teams use Instagram profile and content data.

Influencer Marketing

Problem

Brands waste budget on influencers with inflated follower counts and low real engagement. Manually vetting influencers across Instagram is slow and subjective. You need hard numbers: engagement rate, audience quality, posting consistency, and content performance trends.

Solution

Pull profile data for follower counts, recent posts for engagement metrics, and follower samples to detect fake audiences. Compute engagement rate, average likes per post, comment-to-like ratio, and posting frequency programmatically.

Result

Vet hundreds of influencers per hour with objective metrics. Identify creators with genuine engagement versus inflated numbers. Build a scored shortlist based on data, not gut feel.

Competitive Brand Monitoring

Problem

Your competitors are posting on Instagram but you have no systematic way to track their content strategy, engagement trends, or audience growth. Manual monitoring is ad-hoc and misses patterns.

Solution

Schedule daily pulls of competitor profiles and posts. Track follower growth, posting frequency, engagement rates, and content themes over time. Compare your metrics against the competitive set.

Result

Real-time competitive intelligence dashboard. Spot strategy shifts when competitors change posting cadence or content mix. Benchmark your engagement against industry peers with actual data.

Hashtag and Trend Research

Problem

Finding trending hashtags and understanding what content performs well within a niche requires manually browsing Instagram's Explore page. There is no way to systematically search and analyze hashtag performance at scale.

Solution

Use the Search Posts endpoint to pull posts for target hashtags. Aggregate engagement data across posts to identify which hashtags drive the most interaction. Cross-reference top-performing authors to find collaboration opportunities.

Result

Data-driven hashtag strategy. Know which hashtags drive real engagement in your niche versus vanity tags. Identify trending topics before they peak. Find the right hashtag combinations to maximize reach.

E-Commerce and Product Research

Problem

Product brands need to track how their products are featured on Instagram, identify user-generated content for marketing, monitor competitor product launches, and understand consumer sentiment around product categories.

Solution

Search for brand mentions and product hashtags. Pull comments on product posts to gauge sentiment. Track competitor product launch posts and their engagement. Build a library of high-performing UGC for marketing.

Result

Automated product intelligence. Catch every UGC post mentioning your brand. Monitor competitor launches in real time. Build a content library of authentic customer posts that outperform branded content.

Comparison

How Anysite compares with other Instagram data tools.

Feature Anysite Apify PhantomBuster Instaloader Official Graph API
Account required No No Instagram login cookie Instagram login Facebook Business + app
Setup time Under 5 minutes 10-15 minutes 15-30 minutes 30+ minutes Days to weeks (app review)
Profile data Any public profile Any public profile Any public profile Any public profile Connected accounts only
Posts + engagement Full data + pagination Yes Limited Yes (fragile) Own account only
Reels + Stories Yes Partial Partial Stories with login Own account only
Followers / following Paginated with metadata Yes Limited Yes (rate-limited) No
Content search Keyword + hashtag Hashtag only No Hashtag only Limited hashtag
Self-healing Yes, automatic Actor updates Manual fixes Community patches N/A (official)
Access method REST API + CLI + MCP Web UI + API Browser extension + API Python CLI REST API
Starter price $49/mo (15K credits) $49/mo $69/mo Free (OSS) Free (limited)

Pricing

Credit costs per endpoint. All plans include access to every endpoint.

Endpoint Credit Cost Items per Page
User Profile 1 credit 1 profile
User Posts 1 credit / page 12 posts
User Reels 1 credit / page 12 reels
User Friendships 1 credit / page 50 users
Post Details 1 credit 1 post
Post Comments 1 credit / page 20 comments
Post Likes 1 credit / page 50 users
Search Posts 1 credit / page 20 posts

Cost Examples

Scenario What You Get Credits Used
Vet 100 influencers Profile + 12 posts each 200 credits
Monitor 20 competitors daily Profile + 12 posts each, 30 days 1,200 credits/month
Hashtag research campaign 5 hashtags, 100 posts each 25 credits
Full influencer audit Profile + posts + reels + followers + comments ~10 credits per influencer

Frequently Asked Questions

Do I need an Instagram account to use the API?
No. Anysite does not require an Instagram account, Facebook Business verification, or Graph API app approval. You get an API key and start making requests immediately. No OAuth, no app review, no login cookies.
Can I access private Instagram accounts?
No. Anysite only extracts data from public Instagram profiles. If an account is private, the API returns an error and you are not charged credits. If an account switches from public to private, subsequent requests will fail gracefully.
How do I calculate engagement rate from the API data?
Pull the user profile for follower count, then pull recent posts for likes and comments. Engagement rate = (average likes + comments per post) / followers * 100. The API gives you all the raw numbers to compute any engagement metric you need, including comment-to-like ratio, posting frequency, and content performance trends.
How fresh is the data?
Anysite fetches data in real time at the moment of your API request. There is no stale cache. Follower counts, post engagement metrics, and bio text reflect the current state of the Instagram profile at the time of extraction.
Can I extract data in bulk?
Yes. Send concurrent API requests to extract multiple profiles simultaneously. The CLI tool supports batch extraction from a file of usernames. Rate limits depend on your plan tier. The Scale plan supports high-concurrency use cases.
How does pricing work?
A profile extraction costs 1 credit. Posts cost 1 credit per page of 12. Reels cost 1 credit per page of 12. Follower lists cost 1 credit per page of 50. Plans start at $49/month for 15,000 credits with a 7-day free trial. You only pay for the data you pull.

Start Extracting Instagram Data

7-day free trial with 1,000 credits. Full access to all eight Instagram endpoints, plus every LinkedIn, Twitter, Reddit, and YouTube endpoint.