Is the first item returned by get_posts() always the latest post?

Yes and Maybe

Yes: According to https://developer.wordpress.org/reference/functions/get_posts/ the default is ordered by date in a descending order.

Maybe: But plugins may change the query through ie hook(s) pre_get_posts.

Leave a Comment