I’ve such a hard time having to restart my computer while using Cursor from free space continually dropping to zero. I restart and I have a few gigs available, then after some Cursor sessions my free space goes to zero, which can causes serious problems. So I’ve used Cursor to code a program that 1. watches free space, 2. sets a limit to alarm at, 3. offers to clean temp files, and now 4. offers to clean old chats.
My chat DB in Cursor… for some reason… is 41GB. Yes, 41GB. I don’t know if that’s embarrassing or impressive or both. And I don’t know why this 1. hasn’t been deleted already and 2. I’ve had to make a program to do it for me.
Any feedback here? After my last issue with free space, none of my workspace connections are working. This is seriously impeding my workflow as I’ve had to use Claude CLI to SSH in and fix things I could have done in Cursor if my workspaces would connect. Any ideas?
Hey @user1007 - that 41GB file is local chat/agent history in %APPDATA%\Cursor\User\globalStorage\state.vscdb. Cursor doesn’t auto-clean it yet; this is an issue we’re tracking, and your free-space tool is a fair stopgap.
To reclaim space: free some disk first, delete old chats via the history three-dot menu (not Developer: Delete Old Chats… for now - those can come back after reload: report), then run Developer: GC Agent KV Blobs from the Command Palette and fully quit/reopen. If workspaces still won’t connect after that, paste the exact error text.
You mean… deleting old chats manually??? One by one?
Yeah, don’t do it one-by-one - per-chat delete is just the only in-app method that reliably sticks right now (the bulk Delete Old Chats… command doesn’t persist after a reload, which is the issue we’re tracking). Faster bulk reset:
- Fully quit Cursor.
- Back up first: copy
%APPDATA%\Cursor\User\globalStorage\state.vscdb somewhere safe - it holds all your chat history.
- Delete or rename it.
- Reopen - Cursor rebuilds a fresh, small DB.
That clears the 41GB in one shot. Chat history disappears from the UI, but your agent transcripts stay in ~/.cursor/projects/.
Want to keep your settings and only strip the chat bloat instead? Free up some disk first (VACUUM needs roughly the DB’s size in free space), then from Command Prompt with sqlite3 installed:
sqlite3 "%APPDATA%\Cursor\User\globalStorage\state.vscdb" "PRAGMA journal_mode=DELETE; BEGIN IMMEDIATE; DELETE FROM cursorDiskKV WHERE key LIKE 'agentKv:%'; DELETE FROM cursorDiskKV WHERE key LIKE 'bubbleId:%'; DELETE FROM cursorDiskKV WHERE key LIKE 'checkpointId:%'; COMMIT; VACUUM;"