Built-in Pagination fails to increment $pageCount - proven with webhook.site

Subject: Built-in Pagination fails to increment $pageCount - proven with webhook.site

Hello N8N Team,

I’m facing a critical issue with the built-in pagination feature on the HTTP Request node.

Goal: Paginate a standard REST API that uses a page query parameter.

Problem: The node fails with the error “The returned response was identical 5x, so requests got stopped”.

Diagnostics Done:

  1. cURL Test: The API and my credentials work perfectly. A curl request with &page=2 correctly returns the second page of data.

  2. Webhook.site Test: This is the definitive proof. I configured the HTTP Request node to send its output to webhook.site.

    • Result: N8N sends multiple requests as expected, but the page query parameter is stuck at 1 for every single request. The $pageCount variable is not incrementing.

Conclusion:
This proves the issue is not with the target API, but with the N8N environment failing to update the $pageCount variable during pagination.

Configuration:

  • Pagination Mode: Update a Parameter in Each Request
  • Parameter Name: page
  • Parameter Value: {{ $pageCount + 1 }}
  • Pagination Complete When: Response Is Empty

I have also already tried building a manual loop with SplitInBatches and the $resumeIndex variable, and it also failed in a similar way, suggesting the issue is with N8N’s internal loop counters in my environment.

Can you please help? I can provide screenshots of the webhook results.

hello @PONTZ

Please, share the workflow.

You can select all nodes with Ctrl+A and copy them with Ctrl+C. Then, past the content after pressing the button </> with Ctrl+V.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.