Pagination

The row of Previous, 1, 2, 3, and Next controls that splits a long result list into pages and lets you jump between them.

the 1 2 3 next buttons under a listpage numbers at the bottom of search resultsprevious and next buttons for a tablethe page 1 of 12 thing at the bottomhow do I get to page 2split a long list into pagespagerpagenation

See it

Live demo coming soon

What it is

Pagination is the row of controls that divides one long result set into numbered chunks: Previous, 1, 2, 3, ..., 18, Next. The page number tells you where you are, while the surrounding links let you move one page at a time or jump farther. It borrows the familiar mental model of numbered pages in a book or catalog, the same idea behind Google's old Goooooogle bar, where every extra o was one more page of results.

Reach for it when people need a stable position in a finite set, such as search results, orders, audit logs, or a large table. Numbered pages make it easy to return to page 6, share that URL, and understand roughly how much remains. For an open-ended feed, infinite scroll or a Load more button is usually a better fit. When the set is huge but nobody cares which page they are on, Gmail's version works too: Previous and Next arrows sitting next to a plain '1-50 of 2,341' count.

Gotcha: the control is navigation, not decoration. Use links when each page has its own URL, make the current page visually distinct and mark its link with aria-current='page', and preserve active filters and sorting in every destination. An ellipsis means skipped pages, so it should be plain text unless clicking it opens a real page picker. Previous and Next also need clear disabled states at the ends. Real anchors matter past accessibility too: Google said in 2019 that it had long since stopped using rel=prev and rel=next as indexing signals, so crawlable links are the only thing tying page 6 to page 5.

Ask AI for it

Build numbered pagination for a results list with Previous, page numbers, and Next controls. Keep the first and last page visible, show two pages on either side of the current one, and collapse each longer gap into a noninteractive ellipsis. Render the controls as links inside a nav with aria-label='Pagination', mark the current page with aria-current='page', and give every link a visible :focus-visible style and a 44px minimum touch target. Use URLSearchParams to write the page number into the URL while preserving existing filter and sort parameters, so refresh, sharing, and browser Back restore the same view. On the first and last pages, replace the unavailable Previous or Next link with a visibly disabled span instead of a dead anchor.

You might have meant

cursor paginationinfinite scroll vs paginationdata table with sticky headerfaceted filterbreadcrumbs