Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8950483
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T13:27:55+00:00 2026-06-15T13:27:55+00:00

In general I need to get all user media. User has more than 250

  • 0

In general I need to get all user media.

User has more than 250 photos.

I do /users/1/media/recent/?access_token=...&count=250

But it returns only 20 photos.

Maybe instagram has a limit for getting media.
If it is, response has a pagination to solve it.
But there are only max ID photo. How to know the first (min) ID photo to paginate it then?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T13:27:56+00:00Added an answer on June 15, 2026 at 1:27 pm

    You’re right, the Instagram API will only return 20 images per call. So you’ll have to use the pagination feature.

    If you’re trying to use the API console. You’ll want to first allow the API console to authenticate via your Instagram login. To do this you’ll want to select OAUTH2 under the Authentication dropdown.

    Once Authenticated, use the left hand side menu to select the users/{user-id}/media/recent endpoint. So for the sake of this post for {user-id} you can just replace it with self. This will then use your account to retrieve information.

    At a bare minimum that is what’s needed to do a GET for this endpoint. Once you send, you’ll get some json returned to you. At the very top of the returned information after all the server info, you’ll see a pagination portion with next_url and next_max_id.

    next_max_id is what you’ll use as a parameter for your query. Remember max_id is the id of the image that is the oldest of the 20 that was first returned. This will be used to return images earlier than this image.

    You don’t have to use the max_id if you don’t want to. You can actually just grab the id of the image where you’d like to start querying more images from.

    So from the returned data, copy the max_id into the parameter max_id. The request URL should look something like this https://api.instagram.com/v1/users/self/media/recent?max_id=XXXXXXXXXXX where XXXXXXXXXXX is the max_id. Hit send again and you should get the next 20 photos.

    From there you’ll also receive an updated max_id. You can then use that again to get the next set of 20 photos until eventually going through all of the user’s photos.

    What I’ve done in the project I’m working on is to load the first 20 photos returned from the initial recent media request. I then, assign the images with a data-id (-id can actually be whatever you’d like it to be). Then added a load more button on the bottom of the photo set.

    When the button is clicked, I use jQuery to grab the last image and it’s data-id attribute and use that to create a get call via ajax and append the results to the end of the photos already on the page. Instead of a button you could just replace it to have a infinite scrolling effect.

    Hope that helps.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

In general it would be great to get some sort of description of all
I need to know how to go about implementing general security for a C#
General wisdom is when you remove a component from the stage you also need
I need to be able to print reports, general stuff. But I need it
I am in need of an in-memory general-purpose cache for my iOS app that
General use case I am trying to implement a basic shell. Description I need
I know it is a general question but I need your recommodations about a
I need to implement a method for non-linear interpolation between values, ease-in, ease-out, general
This is a general question, but I'll explain my specific need at the moment:
EDIT: This question was initially too general, I think. So What I really need

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.