paged global variable stores the current page number in the pagination, usually of WordPress archives. It is a query string variable and is set in [wordpress root folder]/wp-includes/template-functions-links.php] if it is not explicitly set.
WordPress theme authors need not use this global variable directly, following functions are provided to support pagination:
next_posts_link($label='Next Page »', $max_page = 0): displays link for posts later in the order
previous_posts_link($label='« Previous Page', $max_page = 0): displays link for posts before the currently displayed posts in the order
posts_nav_link($sep=' — ', $prelabel='« Previous Page', $nxtlabel='Next Page »'): displays both the next and previous post links
These functions refer to the next and previous page in the set of archives. These functions can be used in themes to provide links for navigation within the archives. The archives are displayed in multiple scenarios – the usual index, search, month-wise archive, category-wise archive – for that matter any cohesive set for displaying posts together. You can choose to display posts alphabetically instead of chronologically as mentioned in this WordPress codex document.
$max_num_pages is used to determine the total number of pages in the archive.
Back to full list of global variables.
Copyright Abhijit Nadgouda.