Cursor IDE will open Agent window when re-login with a new account

Where does the bug appear (feature/product)?

Cursor IDE

Describe the Bug

When I logout current old account and login into an new account, my current workspace got closed and opened Agent window instead.

Steps to Reproduce

Be sure you’re in IDE window

  • Login old (current) account
  • Click Login and complete the login workflow on the web

When login is successful, the current IDE will close automatically (or jump to unsaved changes when the file is unsaved), while opening Agent window.

Expected Behavior

Does nothing. IDE / Agent window still as is.

Operating System

Windows 10/11
MacOS

Version Information

Version: 3.13.25
VS Code Extension API: 1.128.0
Commit: 31e8d61c448c7472e371505838a0fe34083dad50
Date: 2026-07-28T06:17:45.069Z
Layout: IDE
Build Type: Stable
Release Track: Default
Electron: 40.10.3
Chromium: 144.0.7559.236
Node.js: 24.15.0
V8: 14.4.258.32-electron.0
xterm.js: 6.1.0-beta.256
OS: Darwin arm64 25.5.0

Additional Information

This has been a while already. I remember this bug was gone in the middle of some version, then it came back recently

This was annoying when I was switching between my Personal and Team accounts.

Does this stop you from using Cursor

No - Cursor works, but with this issue

Hey!

What you’re describing isn’t intended behavior for an account switch. When Cursor detects a fresh login from an IDE window, it currently opens the Agents Window and then closes the IDE window. That flow was designed for first-time sign-in, but it treats a logout-then-login-with-a-different-account the same way, which is what you’re hitting.

A couple of things worth knowing while this is the current behavior:

  • Your workspace isn’t lost - you can reopen it via File → Open Recent in either window, or from the recent projects list in the Agents Window.
  • Unsaved edits are protected by the save prompt during the swap, so nothing gets silently discarded.

If you switch between Personal and Team accounts often, one workaround that avoids the whole re-login flow is running each account in its own isolated Cursor instance with a separate user-data directory:

cursor --user-data-dir="~/cursor-work"
cursor --user-data-dir="~/cursor-personal"

Each instance keeps its own login, so you can have both accounts open in parallel and never sign out.

This is an issue we’re tracking. I’ll follow up here when there’s an update.