Hi team,
I accidentally deleted the entire project folder while Cursor was still open. Interestingly, all files disappeared except for the chat, which remained visible. I used the chat’s checkpoint feature to recover the code, and most file timelines were successfully restored.
However, after closing and reopening Cursor, the recovered files and timelines were still there—but the chat history itself was completely blank. I believe the chat data may still exist somewhere locally on my computer. Is there any way to recover the original chat history?
Hey, this might have happened because the project name changed, or you moved it to a different location on your disk, all of which breaks the connection with the chat history. You can also try to restore the chat history using this extension:
Looks like this is my only option now. The version I backed up with Git is from a month ago, so thankfully the checkpoint feature helped me recover most of the lost work. I’m just curious—when the entire project folder was deleted, the chat was still functioning normally. I could view old conversations and even switch between multiple threads without any issues.
But after restarting Cursor, the chat became completely blank with no conversations at all. I suspect the chat history might still be stored somewhere in the .cursor folder on my computer.
Good morning! I’m down the rabbit hole trying to restore my chat history for ~5 months of work in Cursor across different projects after it randomly decided to stop loading for me following an auto-log out after restart this morning (): Can't load past chat after updating to a newer version - #6 by wearywas
I’ve tried installing that extension but it seems like it would only be able to restore new chat sessions moving forward from what I can tell – is there something I’m missing for how it would restore past chats that are no longer loading? To recap, I can see the titles of the Past chats in the chat panel history, but clicking them (as I normally would to load any prior chat) just spins the icon and loads a blank state after – but I seem to be able to load chat history for new chats since the issue started, which… does not bode well for this being a random history corruption/wipe that’s unrecoverable ().
I’m glad to hear I’m not the only one facing a problem with my chat history.
I changed my the name of my route folder, losy all the chat. Changed the the name back, the chats reappeared but can’t access them smh
I recommend using SpecStory extension, it automatically exports each chat as MD file. This works great.
Now in Cursor 0.50 you can also manually export a chat you want to keep as MD file.
For old chats, depending what caused the chats to be deleted, it may not be recoverable.
Perhaps if you have backups of your computer you could restore the old database.
SOLUTION:
Cursor used 2 scripts to help search through the vscdb files and read them. I would tell Cursor what im looking for. key words, times, dates, and Cursor found everything one by one and compiled all the lost code and chat to a .md file. In conclusion ask Cursor to find it for you. I helped guide Cursor (EXAMPLE): " I remember asking to reduce the animation width by 50% and height by 50%." Cursor will find that point in the chat history and give all details and code involved.
I asked Cursor to create a COPY and PASTE instruction message that you can give to your Cursor agent to help you recover lost chat history. here it is:
"Please help me recover lost chat history from Cursor’s workspace storage. This is a two-step process:
First, create a Python script called export_chats.py that can search through SQLite databases in the workspace storage directory (on Mac: ~/Library/Application Support/Cursor/User/workspaceStorage, each containing a state.vscdb file). The script should search through chat data for specific time periods and keywords related to the lost content.
Then, create a Node.js script called clean_history.js that processes the exported chat history. This script should:
Filter conversations based on project-specific keywords
Clean up markdown formatting
Remove irrelevant content
Output cleaned history files for each team
We’ll need to make multiple search passes with export_chats.py, refining the parameters each time to filter out noise and focus on relevant conversations. Once we have the raw chat data, we’ll use clean_history.js to organize and clean it. When we find matching content, help me reconstruct the code and implementation details from the chat fragments. Please guide me through this process step by step, starting with creating both scripts and then helping me search effectively by suggesting relevant search terms and filtering strategies based on what I’m trying to recover. Remember that chat history might contain code snippets, implementation discussions, and debugging sessions that can help piece together the lost work."
Youre good to go -
I hope you get your code back like I just got mine. EASY CODING !