Cursor Wiped my Entire Computer

Cursor just wiped my entire computer on the first day of using it. I understand now from reading other posts that there is a proper set-up which I clearly didn’t have.

What am I supposed to do to restore my files?

Hey, I’m sorry this happened. It’s a really frustrating situation, especially when a lot hits at once. I’ll try to help with what you can actually do right now.

For context on how this works: the agent only runs shell commands with permission. Either you approve each one manually, or auto-run is enabled and commands run without confirmation. With default settings and no extra safeguards, some destructive actions can run without an explicit review. The team is working to make models better at understanding intent and being more careful with destructive actions, but the core rule still stays with the user: review commands before running them.

Recovery

When commands like rm -rf or rmdir /s /q run in a terminal, files are deleted without going to the Recycle Bin or Trash. Cursor can’t restore them since they’re removed at the OS level. Here’s what you can try:

  • HDD: there’s a chance with recovery tools like Recuva on Windows, PhotoRec and TestDisk cross-platform. The less disk writing since deletion, the higher the chance. Try not to actively use that drive before you attempt recovery.
  • SSD with TRIM: recovery is almost impossible since the controller likely already cleared the blocks.
  • Cloud backups: check Time Machine on Mac, File History on Windows, and OneDrive, iCloud, Google Drive, Dropbox.
  • Code: if you had a git remote GitHub or GitLab, your sources are there and you can git clone them back.

Settings for next time

In Cursor Settings Cmd+Shift+J > Agents > Terminal:

  • Auto-Run Mode: switch to Ask Every Time or Use Allowlist instead of Run Everything
  • Turn on File-Deletion Protection and External-File Protection
  • For unfamiliar tasks, Plan mode is useful. The agent writes a plan first, you review it, then it runs

And basic data hygiene that helps in any situation: use git and push regularly to a remote for code, and keep a separate backup of Documents and Pictures to an external drive or cloud.

Let me know if any of the recovery options work.