Pagination

Page navigator on bits-ui Pagination. Renders prev/next, numbered links, and ellipsis — motion stays out of the way, the active link simply swaps to the outline button variant.

Usage

Controlled page

Bind page to drive pagination from the outside.

Current page: 3

Pagination.Root props

Inherits bits-ui Pagination.Root props. Use the children snippet to render pages and ellipses.

PropTypeDescription
numberTotal number of items to paginate.
numberItems per page. Drives the total page count.
number (bindable)Controlled current page. Two-way bindable.
numberHow many pages to show on either side of the current page before an ellipsis.
booleanWhen true, keyboard navigation wraps past the ends.
PropTypeDescription
PagePage descriptor from the Root children snippet.
booleanMarks the link as the current page. Applies the outline button variant and aria-current.
'default' | 'xs' | 'sm' | 'lg' | 'icon' | 'icon-xs' | 'icon-sm' | 'icon-lg'Size token forwarded to the Button variant.