Skip to main content

Get the Instagram ID of a user without an access token


  1. The easiest way to get the instagram id of a given username.
  2. Access token is not needed.
  3. Only a few lines of code.
  4. PHP example available on github:


Send a get request with the parameter “username”

ig id 3

How it works#

  1. username = $_GET["username"]
  2. Send a get request to:
  3. The returned JSON contains the user id.

Structure of the returned JSON (may have changed):

ig id 1


ig id 2