Use simple pagination for a smaller number of pages.
Set the display attribute to simple.
Set the previous page’s URL with the previous-href attribute.
Set the previous page’s label with the previous-label attribute.
Set the next page’s URL with the next-href attribute.
Set the next page’s label with the next-label attribute.
Set up list styled pagination
Use list styled pagination when you are dealing with a larger number of pages.
Set the display attribute to list.
Set the total number of pages in your sequence with the total-pages attribute using a numeric value.
Set the current or active page with the current-page attribute using a numeric value.
Opt to use the url attribute to provide the component with a group of page links. This can be an object if you are working in a JS environment, or a string if you are using HTML.
Apply the URL object for list-style pagination
Use the url object to generate the query strings and fragments for the list pagination’s links.
To modify the value based on the page link being rendered, add the object modifiers ::offset or ::match to a key in the queryStrings object. ::offset counts up with the given value starting from the second page link.
Using ::match on the current page link being rendered, multiplies it by the value provided.
url = { queryStrings: { 'page::match': 1, },};
Using either ::offset or ::match, allows a number to be injected into a string. Using {{#}}, the modifier will inject the modified number based on the counting method into the string when rendering.
The url attribute defines the object (in a JavaScript environment) or string (in HTML) that generates the query strings and fragment for the list-styled pagination links.
Code builder Generate an instance of the component you need by selecting its code properties.
Explore by choosing different code values to generate the instance you want.
Get the code and pull it into your environment.
Add any copy you need to the component (like text for a label).
Note: The code builder uses English for all code elements, which follows standard practice. Help us improve Have questions or a request? Give feedback on our contact form. Something's wrong? Raise it through GitHub with an account. You'll have access to the team's direct responses, progress made on your issue, and issues raised by others. Give feedback Report an issue on GitHub 2026-05-20