Pagination

I have a problem with my application due to the amount of data that is being returned with an action to search for customers on my platform. It turns out that some companies have thousands of customers and they are all being returned at once.

How can I paginate this search?