NEWStandard createTask and in.php APIs. Change the address and you are connected.View API docs
GATESOLVER

Glossary

Pagination: walking through long lists page by page

Pagination is how a site breaks a long result list into smaller chunks, and every scraper that wants the full list has to follow it to the end.

The four styles you will meet

Almost every paginated list uses one of four patterns. Identify the pattern first, because it decides how you build the next request and how you know you are done.

StyleHow the next chunk is requestedHow the end looks
Page number?page=3 in the URLAn empty list or a missing Next link
Offset and limit?offset=60&limit=30Fewer items than the limit
CursorAn opaque value from the previous response, such as next_cursorThe cursor is null or absent
Infinite scrollJavaScript loads more when you reach the bottomThe loader stops firing

Page numbers and offsets

These are the easiest to crawl because you can compute every URL in advance. If the first page says there are 40 pages, you can queue all 40 at once and fetch them in parallel. The risk is drift: if new items are inserted while you crawl, offsets shift and you see some rows twice and miss others. Deduplicate on a stable ID such as a product SKU rather than on position.

Cursors

Cursor pagination hands you a token with each response that points to the next slice. You cannot jump ahead, so the crawl is sequential per list, but it is stable when data changes underneath you. Store the last cursor you processed; if the job stops, you can resume from it instead of starting over. Cursors often expire after a few minutes, so do not hold them overnight.

Infinite scroll

On a page that loads more items as you scroll, the browser is usually calling a JSON endpoint with a page or cursor parameter. Watch the Network panel while scrolling and you will often find a plain paginated API underneath, which you can call directly (see hidden API scraping). If no clean endpoint exists, drive a headless browser that scrolls, waits for new nodes and stops when the item count stops growing.

Detecting the last page reliably

Do not trust a single signal. Combine several: the Next link is missing, the response holds zero items, the items repeat the previous page, or a total count says you have them all. Also set a hard ceiling on pages per list, so a bug in the end check cannot keep a worker looping forever.

Where CAPTCHAs appear in paginated crawls

Deep pages are a classic trigger. A visitor rarely clicks to page 80, so sites often show a challenge after a certain depth or after a burst of fast page loads. When a page returns a challenge instead of results, pause that list, solve the challenge (for a checkbox widget, a reCAPTCHA v2 task usually returns under 9 seconds), retry the same page and continue. Spacing requests and keeping a steady concurrency level per site reduces how often this happens.

Save progress per list (last page or cursor) in your request queue, so a restart picks up where it stopped.

Common questions

Which pagination style is easiest to scrape?

Page numbers, because you can generate every URL up front and fetch them in parallel. Cursor lists must be read one step at a time.

Why do I get duplicate items across pages?

Items were added or removed while you crawled, so positions shifted. Deduplicate on a stable ID instead of on page position.

How do I scrape an infinite scroll page without a browser?

Find the JSON request the page makes while you scroll and call it directly with the same page or cursor parameter.

Why does a CAPTCHA appear only on later pages?

Deep paging is unusual for people, so many sites raise checks after a certain depth or speed. Slow down and solve the challenge when it appears.

Should I limit how many pages a job can request?

Yes. A per list ceiling protects you from end detection bugs that would otherwise loop until the job is killed.

Keep reading