Title: Default and max numberposts
Last modified: August 20, 2016

---

# Default and max numberposts

 *  [frizzle](https://wordpress.org/support/users/frizzle/)
 * (@frizzle)
 * [14 years, 10 months ago](https://wordpress.org/support/topic/default-and-max-numberposts/)
 * The numberposts attribute for get_posts is very poorly documented.
 * It seems that the default displayed is 5. I would have thought that by specifying
   numberposts=>” you’d be saying “show all posts,” but that seems to just make 
   the maximum into 10! (How would one guess that THAT was going to be the case?)
 * Implicitly, in the documentation it kind of specifies that if you set numberposts
   to -1, it shows all. But it never says this explicitly. On the WP Query page,
   you can infer this if you realize that numberposts is the same thing as posts_per_page,
   but you’ll never figure that out with Google searches, since they are not the
   same thing (and numberposts never appears once on that page).
 * Can someone please, PLEASE write up some actual technical documentation for this
   very important parameter? Are there any other tricks I should be aware of? I’ve
   now had to rewrite a TON of get_posts calls each time I figure out some sort 
   of other behavior with numberposts, which is really quite unnecessary…

Viewing 1 replies (of 1 total)

 *  Moderator [Ipstenu (Mika Epstein)](https://wordpress.org/support/users/ipstenu/)
 * (@ipstenu)
 * 🏳️‍🌈 Advisor and Activist
 * [14 years, 10 months ago](https://wordpress.org/support/topic/default-and-max-numberposts/#post-2252754)
 * I believe the 10 is grabbed from your settings (WP Admin -> General -> Reading).

Viewing 1 replies (of 1 total)

The topic ‘Default and max numberposts’ is closed to new replies.

 * In: [Requests and Feedback](https://wordpress.org/support/forum/requests-and-feedback/)
 * 1 reply
 * 2 participants
 * Last reply from: [Ipstenu (Mika Epstein)](https://wordpress.org/support/users/ipstenu/)
 * Last activity: [14 years, 10 months ago](https://wordpress.org/support/topic/default-and-max-numberposts/#post-2252754)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
