# Issue with Pagination – “No Path Back to Node” for endCursor

**URL:** <https://community.n8n.io/t/issue-with-pagination-no-path-back-to-node-for-endcursor/80477>\
**Category:** Questions\
**Tags:** looping\
**Created:** [February 21, 2025, 7:25pm UTC](https://community.n8n.io/t/issue-with-pagination-no-path-back-to-node-for-endcursor/80477 "2025-02-21T19:25:15Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Isaac\_Harmon](https://dub1.discourse-cdn.com/n8n/user_avatar/community.n8n.io/isaac_harmon/32/58878_2.png) [@Isaac\_Harmon](https://community.n8n.io/u/Isaac_Harmon)\
**Post date:** [February 21, 2025, 7:25pm UTC](https://community.n8n.io/t/issue-with-pagination-no-path-back-to-node-for-endcursor/80477/1 "2025-02-21T19:25:15Z")

</div>

**Title:**

Issue with Pagination – “No Path Back to Node” for endCursor

**Problem**

I’m looping through paginated API responses in n8n and setting endCursor for the next request. However, when I reference it in the next iteration, I get:

```auto
"variables": { "after": "[No path back to node]" }

```

How can I correctly pass endCursor between iterations?

**What I’ve Tried**

• Referencing {{$json[“endCursor”]}} and {{$node[“Set End Cursor”].json[“endCursor”]}}

• Ensuring Set End Cursor runs before the next API call

• Using an **IF** node to check hasNextPage before looping

**Setup**

• **n8n version:**

• **Database:** SQLite (default)

• **Execution mode:** (own/main)

• **Running via:** (Docker, npm, cloud, etc.)

• **OS:**

**Question**

How do I ensure endCursor is correctly passed to the next request in a loop?

---

<div class="post-metadata">

**Author:** ![n8n](https://dub1.discourse-cdn.com/n8n/user_avatar/community.n8n.io/n8n/32/26906_2.png) [@n8n](https://community.n8n.io/u/n8n)\
**Post date:** [February 21, 2025, 7:25pm UTC](https://community.n8n.io/t/issue-with-pagination-no-path-back-to-node-for-endcursor/80477/2 "2025-02-21T19:25:16Z")

</div>

It looks like your topic is missing some important information. Could you provide the following if applicable.

- **n8n version:**
- **Database (default: SQLite):**
- **n8n EXECUTIONS\_PROCESS setting (default: own, main):**
- **Running n8n via (Docker, npm, n8n cloud, desktop app):**
- **Operating system:**

---

<div class="post-metadata">

**Author:** ![hubschrauber](https://dub1.discourse-cdn.com/n8n/user_avatar/community.n8n.io/hubschrauber/32/46788_2.png) [@hubschrauber](https://community.n8n.io/u/hubschrauber)\
**Post date:** [February 21, 2025, 7:35pm UTC](https://community.n8n.io/t/issue-with-pagination-no-path-back-to-node-for-endcursor/80477/3 "2025-02-21T19:35:38Z")

</div>

It’s not exactly the same, but I recently posted [an example of how to handle loop iteration variables](http://community.n8n.io/t/incrementing-your-own-loop-variable/79196/3), which might help you figure out how to do what you want here. It should at least give you some ideas about how to reference things with expressions depending on whether they are inside or outside of your loop.

---

<div class="post-metadata">

**Author:** ![system](https://dub1.discourse-cdn.com/n8n/user_avatar/community.n8n.io/system/32/195824_2.png) [@system](https://community.n8n.io/u/system)\
**Post date:** [May 22, 2025, 7:43pm UTC](https://community.n8n.io/t/issue-with-pagination-no-path-back-to-node-for-endcursor/80477/5 "2025-05-22T19:43:13Z")

</div>

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