> For the complete documentation index, see [llms.txt](https://docs.aicrisk.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.aicrisk.com/api-overview/chat-apis/pagination-getconversation-s/recap.md).

# Recap

🔁 Recap: Building a UI with Pagination

To integrate pagination smoothly into your UI:

1. Set a default `results` value (e.g., 20 or 50)
2. Track `currentPage` in your frontend or backend state
3. When the user clicks “Next” or “Previous”:
   * Update `page`
   * Recalculate `skip`
   * Re-fetch data using the helpers above
4. Render the results into your UI

💡 **Pro tip**: You can pre-fetch the next page in the background to create an “instant” pagination experience.
