Remote SSH: subagent path inconsistency

Where does the bug appear (feature/product)?

Cursor IDE

Describe the Bug

I’m connecting to a remote host via SSH.
I have defined a subagent in ~/.cursor/agents/mysubagent.md .
Cursor couldn’t tell me whether the file is expected on the local host or the remote host, so I duplicated the file with a small difference to tell the difference. This way, I observed an inconsistency.

In ‘Cursor Settings’, the subagents list is taken by looking at the local ~/.cursor/agents path.
However, when actually chatting with an agent and asking it to use a subagent, it is taking the subagent definition from the remote ~/.cursor/agents path.

This is a problem because a change to the subagent via the Cursor CLI (e.g. change the model, or the subagent body), does not actually take effect because a real agent will look at a different file. I need to manually keep the files in sync between the local machine and the remote host.

Steps to Reproduce

Create a subagent, duplicate the file between local host and remote host, and let each copy announce a different string on startup, so you can tell the difference.

Expected Behavior

The ‘Cursor Settings’ list of subagents should reflect the subagents actually used by the agent.
Documentation should be updated to clarify path expectations.

Operating System

Linux

Version Information

Version: 2.6.20
VSCode Version: 1.105.1
Commit: b29eb4ee5f9f6d1cb2afbc09070198d3ea6ad760
Date: 2026-03-17T01:50:02.404Z
Build Type: Stable
Release Track: Default
Electron: 39.8.1
Chromium: 142.0.7444.265
Node.js: 22.22.1
V8: 14.2.231.22-electron.0
OS: Linux x64 6.12.58-gentoo

Does this stop you from using Cursor

No - Cursor works, but with this issue

Thanks for the thorough testing with the different strings on local vs remote. That’s a clean way to isolate the problem.

This does look like a bug in how subagent definitions are resolved during Remote SSH sessions. We have a few related reports from WSL users experiencing a similar local-vs-remote path mismatch (Subagents in WSL), and our team is actively working on improving Remote SSH context handling more broadly.

For now, the workaround is to edit your subagent files directly on the remote host (since that’s what the runtime reads), and treat the Settings UI listing as unreliable when connected via SSH.

Also worth noting: you’re on version 2.6.20, which is a couple months old. Updating to the latest stable may help, as there have been several Remote SSH improvements since then.

We’ll update this thread when there’s a fix for this.