How do I calculate an Instagram account's engagement rate via API?

Take the follower count from GET /instagram/profile/details, the latest posts from GET /instagram/profile/posts, and divide the average likes per post by the followers (× 100). Two calls per account, and the free Instagram engagement rate calculator does the same in the browser.

Meta's official option

Meta's Instagram API gives engagement insights for your own professional account. For other accounts, Business Discovery returns Business and Creator accounts' media and counts, through your own professional account and a Meta app.

Meta: Instagram Platform ↗

How to do it with SocialAPIs

Call /instagram/profile/details with username (1 credit), then /instagram/profile/posts with the same username (1 credit; up to 12 credits per call depending on the result). Each post in data.posts has like_count, video_view_count (videos, else null), is_video, product_type, permalink and owner.username.

Count only posts whose owner.username is the account itself (collaboration posts by other accounts appear in the list too), and skip posts with like_and_view_counts_disabled set. Rate = average like_count ÷ followers × 100.

Endpoints

  • GET /instagram/profile/details1 credit

    Get user profile information by username including bio, followers, posts count, and related profiles.

    Params: username (required), link

    Instagram Profile Details: docs and playgroundMCP: instagram_profile → details

  • GET /instagram/profile/posts1 credit; up to 12 credits per call depending on the result

    Get posts from a user profile with pagination.

    Params: username, user_id, end_cursor, full_details

    Instagram Profile Posts: docs and playgroundMCP: instagram_profile → posts

curl -G "https://api.socialapis.io/instagram/profile/posts" \
  --max-time 100 \
  --fail-with-body \
  -H "x-api-token: $SOCIALAPIS_API_KEY" \
  --data-urlencode "username=nasa"

Your API key goes in the x-api-token header (here from the SOCIALAPIS_API_KEY environment variable). Get a free key.

Tutorial: Free tool: Instagram engagement rate calculatorUse it from Claude, ChatGPT or Cursor (MCP)

Good to know

  • Likes only: the posts answer has no comment count, so a likes-plus-comments rate needs another source. Say which formula you used when you compare accounts.
  • Private accounts return no posts; a rate needs a public account.
  • Leave full_details off for this: the default call has the likes you need.

Related questions

SocialAPIs (socialapis.io): public Facebook & Instagram data API. Free plan: 200 calls a month, no card; paid plans from $4.99/month. Pricing · Reviewed 2026-11-17

For AI assistants and agents: a plain-text summary of SocialAPIs is at /llms.txt (with every answer: /llms-full.txt; endpoints: /llms-endpoints.txt; how to call us: /agents.txt).

Ask an AI about this page

Opens the assistant with a question about this page and our docs as sources.