Preview
Design guidance
Use numbered pagination when people need to return to a specific page. Use load more to extend results without changing pages.
Controls use the shared 32px default size and expand to a 44px minimum on touch devices. The current page has a smaller number container and exposes aria-current="page". Navigation, arrow buttons and jump controls have accessible names.
Installation
Basic usage
Structures
Pagination owns the navigation controls and ellipsis editor. The caller owns the current page, result records and total page count. Compose Select beside it for page size, or Button for load more. These examples keep counts and page state in the caller.
Pagination.Navigation renders adjacent native links from caller-supplied destinations and names.
Examples
Numbered
Keep the current page visible with a bounded window of page numbers.
Ellipsis to input
Click either ellipsis to replace it with a page field. The field accepts whole digits only. Enter goes to a page from 1 to the total; Escape cancels and returns focus. An out-of-range value keeps the field open with an error.
Load more
Keep the current results in place. The loaded count updates after each batch; the action is disabled when all items are shown.
Page size
Choose how many items to show per page. Changing the size resets to the first page and updates the range and page count.
Also install Select for this example.
Compact
Pair named Previous and Next actions with the current page and total.
Previous and next
Move between bounded pages with arrow controls.
Adjacent pages
Navigate to named pages with native links. Omit a destination at either boundary.
API reference
| Prop | Type | Default | Description |
|---|---|---|---|
page | number | Required current 1-based page. Non-integers use page one; integer values clamp to the valid range. | |
pageCount | number | Required non-negative safe integer total. Zero or invalid totals render an empty navigation. | |
onPageChange | (page: number) => void | Reports a valid requested page. Without a callback, navigation is read-only. | |
variant | numbered | compact | previous-next | numbered | Number window, summary with named actions, or arrow controls. |
siblingCount / boundaryCount | number | 1 | Visible page-window sizes, each capped at 100. |
disabled / loading | boolean | false | Block navigation. Loading also exposes aria-busy. |
labels | { previous?: string; next?: string; navigation?: string } | Accessible labels; defaults to Previous page, Next page and Pagination. | |
className / ref / native nav props | string / Ref<HTMLElement> / ComponentPropsWithoutRef<"nav"> | Extend or reference the navigation root. |
| Prop | Type | Default | Description |
|---|---|---|---|
previous / next | { href: string; label: string } | Optional native link with its destination, name and directional icon. | |
aria-label | string | Adjacent pages | Accessible navigation name. |
className / native nav props | string / ComponentPropsWithoutRef<"nav"> | Additional class and native navigation attributes. |