Cursor re-opens closed chat tabs on each launch

Where does the bug appear (feature/product)?

Cursor IDE

Describe the Bug

I have for example 5 opened agent tabs in the sidebar. I close them all. Close Cursor and open it again.
I see all those tabs opened again.
They’re old agents I don’t want to see them again; I closed them for a reason. But Cursor thinks it’s smarter than me. Maybe, but you have to release a few more updates for Composer model for that.
That issue exists quite a long time; can’t tell from which version it began. I was too lazy to report it earlier.

On my screenshot you can see even worse situation. It opens empty chats on each run, alongside with 1 of my previous chats. I expected to see it as it was left before I closed the Cursor. There was only 1 empty “New Agent” tab.

Steps to Reproduce

You must have some opened agent chats.
Close them.
Close Cursor.
Run Cursor.
You’ll see the same chats opened again.

Expected Behavior

Closed chats must stay closed.

Screenshots / Screen Recordings

Operating System

Windows 10/11

Version Information

Version: 3.7.21 (user setup)
VS Code Extension API: 1.105.1
Commit: 517f696d8ab6c53eb04fbfdaae705cd146bf3460
Date: 2026-06-07T21:46:09.237Z
Layout: editor
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
xterm.js: 6.1.0-beta.256
OS: Windows_NT x64 10.0.26200

Does this stop you from using Cursor

No - Cursor works, but with this issue

Hey, thanks for the report. Tab persistence across restarts is a known pain point. I’ve logged your specific case internally, where closed tabs reopen and empty New Agent tabs also get created. I can’t share an ETA for a fix yet.

A couple questions to help narrow it down:

  • Does this happen on every launch, or only sometimes?
  • What’s your setting for the open tabs limit (5 / 10 / unlimited / custom)? It’s interesting that exactly 5 reopen, which matches the default limit, so I want to check if that’s related.

If you change the limit, for example to unlimited, then close and reopen Cursor, does the behavior change? Let me know, it’ll help pinpoint the cause.

It happens constantly.

If I set custom tabs count to 1 it will open the same set of tabs as on my screenshot anyway. Just checked it.

UPD.

Closed all again. Relaunched Cursor. Have 4 “New Agent” tabs.

I have the same issue. Old AI chat tabs that I close because I no longer need them keep reappearing after I close and reopen Cursor. It’s becoming really frustrating because I have to manually close them every single time just to be able to work normally.
At the moment, the only workaround that consistently works for me is deleting the project-specific folder from Cursor\User\workspaceStorage, which removes the saved Cursor state for that project.
Please fix this issue, as it is very annoying and significantly affects the overall user experience.

Thanks, this is helpful. Since custom limit = 1 still opens the same set of tabs, it’s clearly not a limit issue. It points to a problem with state restore itself. The empty “New Agent” tabs confirm that. I’ve noted this in our internal report.

@Grzegorz96 thanks for confirming and for the workaround. Deleting the project folder from Cursor\User\workspaceStorage does reset the stuck state, but please note it also removes all saved state for that project, including chat history and workspace settings. So only do this if you’re OK losing that data.

This bug is known and being tracked. I can’t share an ETA for a fix yet. I’ll post an update in the thread when I have one.

Today I’ve updated Cursor and bug disappeared. Can you keep it like that?

Great news, glad it resolved on its own. Thanks for coming back to share, that’s helpful.

Can you tell me the exact version you updated to (Help > About or from the release info in the top bar)? I want to note which build fixed the behavior.

Oh no, the issue is still there.

Version: 3.7.42 (user setup)
VS Code Extension API: 1.105.1
Commit: 5702c9cfca656d8710fad58402fe37f14345e3a0
Date: 2026-06-15T19:39:42.738Z
Layout: editor
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
xterm.js: 6.1.0-beta.256
OS: Windows_NT x64 10.0.26200

Worked for some time, created a few chats and it started happening again.)

Hey, sad to hear it’s back. Thanks for sharing the exact version. We’re tracking the bug, but I can’t share an ETA for a fix yet.

To help narrow it down: did you notice the bug comes back specifically after creating a few new chats? And is it related to how you close Cursor, like closing a bunch of tabs and quitting right away, or does it reproduce either way?

If there’s an update on the fix, I’ll post it here.

hey @deanrie ; any news regarding this bug please?

at my company we have enterprise plan for cursor, and the editor view in cursor is what keeps me using cursor (a product which I like and advocate internally).

This bug has been here for quite a while, and it has been a serious annoyance to the point where I’m considering dropping cursor and just use vscode with codex and claude code extensions.

can you please investigate?

thanks!

Hey @tiagopi, this is a known bug and we’re tracking it on our side, but I honestly can’t share an ETA for a fix yet. As soon as I have an update, I’ll reply in this thread.

A couple questions to help narrow it down (we’ve collected some data in this thread already, but details from your setup would still help):

  • Does it only come back after you create several new chats, or can you reproduce it without that?
  • Does it depend on how you close Cursor, like closing a bunch of tabs and quitting right away, or does it happen no matter what?

As a temporary workaround, deleting the project folder under Cursor\User\workspaceStorage resets the stuck state. Just a heads up, this wipes all saved project state, including chat history and workspace settings, so only do it if you’re OK losing that data.

I know this has been going on for a while and it’s really disruptive. Thanks for sticking with us on this, and let me know your answers to the questions above, it’ll help us move the diagnosis forward.

Hi @deanrie thanks for you reply.

I’ve cleared the workspace storage, which in my system it was installed at ~/Library/Application\ Support/Cursor/User/workspaceStorage/

I will ping back if the problem still persists :slight_smile:

Best, Tiago

My computer (Windows 11) also encounters this issue.
However, the issue basically reoccurs stably after installing Superpowers. I tried uninstalling (including clearing the local cache) and reinstalling, and I basically didn’t encounter this problem again. But as long as I install Superpowers, it will definitely appear! At this point, even if I uninstall Superpowers, this issue will continue to occur.

also archived tabs reappear.

Where does the bug appear (feature/product)?

Cursor IDE

Describe the Bug

Cursor keeps reopening closed chats at startup.

Steps to Reproduce

  • I manually close old chats I don’t need anymore
  • I close the IDE
  • Once the IDE is reopened, old closed chats are open again

Expected Behavior

Manually closed chats should stay closed

Screenshots / Screen Recordings

Operating System

MacOS

Version Information

Version: 3.12.10
VS Code Extension API: 1.128.0
Commit: 24a12dbd9cabf48956ce5bb3dbd234e41385b3d0
Date: 2026-07-16T03:15:48.538Z
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 24.6.0

Does this stop you from using Cursor

No - Cursor works, but with this issue

Same bug keeps happening for me for a number of weeks now, still present in the latest version.

Version: 3.12.17 (user setup)
VS Code Extension API: 1.128.0
Commit: 0fb762053c34788bb7760d5673f8a6d4c8589d50
Date: 2026-07-17T02:53:53.006Z
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: Windows_NT x64 10.0.19045

Hey, @JianXin_Lin, @m4.5, thanks for the extra details, that helps.

@JianXin_Lin the link to Superpowers is a useful clue. A few questions to narrow it down:

  • Before installing Superpowers, did tabs behave correctly and stay closed after restart?
  • Which chats reopen, only ones related to that plugin, or all of your old chats?
  • After removing the plugin and clearing cache, if you delete the project folder in Cursor\User\workspaceStorage, does that reset the issue, or does it come back even after that?

@m4.5 got it on archived tabs showing up again, that’s part of the same tracking.

Just to be direct: we’re tracking this bug, but I can’t share an ETA yet. As a temporary workaround, deleting the project folder in Cursor\User\workspaceStorage can clear the stuck state, make a backup first. Keep in mind this will remove all saved project state, including chat history and workspace settings, so only do it if you’re OK with losing that data.

I’ll post here as soon as I have an update.

Hi @deanrie,

I also noticed this behavior today, I think it’s been happening for a while but it’s not happening for my colleagues.

I noticed that the system had my last agent window open with around 7 or 8 of my previous agents (it wasn’t the last 7 or 8, it seems to be scattered / random ones from the month).

I closed all of them and closed Cursor from the top right close button. When I opened it again, they were all back. If I add a new agent window and close it, it will reappear and make it e.g. 9.

I used the agent this afternoon to create a python script for me that will clear all but the last 1 per workspace so I can use that to clear the accumulation. Shout if you want me to post it.

here are the contents of cursor-bug-report.md generated on my machine by the agent:

Bug report: “Open Chat as Editor Tabs” toggle greyed out; chats forced to behave as editor tabs and accumulate on restart

Summary

On my machine the Settings → General → Layout → “Open Chat as Editor Tabs” toggle is disabled/greyed out and shows off, yet my agent chats are still rendered and persisted as editor tabs. A colleague on the same Cursor version can change this toggle; I cannot. The result is that old agent conversations keep reopening as editor tabs on every startup and accumulate without bound — closing them does not stick.

Environment

  • Cursor version: 3.12.17
  • VS Code base: 1.128.0
  • Commit: 0fb762053c34788bb7760d5673f8a6d4c8589d50
  • OS: Windows 10 (19045)

What I expected

  • Either the “Open Chat as Editor Tabs” toggle is changeable, or
  • With the toggle off, chats should NOT behave as editor tabs (they should use the stacked/sidebar view), and
  • Closing a chat editor tab should keep it closed after restart (standard VS Code editor behavior).

What actually happens

  1. The “Open Chat as Editor Tabs” toggle is greyed out / not changeable.
  2. The toggle reads off, but chats are still shown and persisted as editor tabs anyway.
  3. On every launch, previously-opened agents reopen as editor tabs and accumulate (2 → 3 → 4 …, one added per session).
  4. Closing an agent tab (×) does not remove it from the restore set — it comes back after restart.

Relevant internal state (read from globalStorage/state.vscdb, read-only)

cursor/unifiedAppLayout                        = agent
cursor/layoutControl.eligibleAfterOnboarding   = false
cursor/removeAgentLayoutIde.treatmentSticky    = false
cursor/firstWindowOpenGlassTreatment           = true
  • My colleague and I are BOTH on unifiedAppLayout = agent and the SAME version, but only he can toggle the setting — which points to a per-account/server-side experiment (Statsig) assignment differing between us, with layoutControl.eligibleAfterOnboarding = false locking the control on my side.

Root-cause detail (editor-tab persistence)

The restore of agent editor tabs is driven by:

  • composer.composerDataselectedComposerIds / lastFocusedComposerIds (per-workspace state.vscdb)
  • workbench.parts.embeddedAuxBarEditor.state (the embedded auxiliary-bar editor grid)

Closing an agent tab in the UI does not remove its ID from selectedComposerIds, so on startup Cursor re-opens every listed composer as an editor tab. This diverges from standard VS Code behavior, where a closed editor stays closed after restart.

Repro

  1. Be on unifiedAppLayout = agent with layoutControl.eligibleAfterOnboarding = false.
  2. Open several agent chats (they appear as editor tabs in the auxiliary bar).
  3. Close them with the × and/or toggle the agents panel off.
  4. Fully quit and reopen Cursor.
  5. Observe the chats reopen as editor tabs and grow in number over sessions.
  6. Note the “Open Chat as Editor Tabs” toggle is greyed out and cannot be changed.

Requests

  1. Allow the “Open Chat as Editor Tabs” toggle to be changed (or explain the eligibility gate), so accounts stuck with eligibleAfterOnboarding = false can opt out.
  2. When the toggle is off, chats should not persist/behave as editor tabs.
  3. Closing an agent editor tab should remove it from selectedComposerIds so it does not restore.
  4. Ideally expose this as a real, documented settings.json key rather than server-only experiment state.

Workaround I’m currently using

A script that, while Cursor is closed, trims selectedComposerIds/lastFocusedComposerIds and the embeddedAuxBarEditor grid down to the most-recently-focused agent per workspace — otherwise the tabs grow unbounded.