Cursor deletes files and folders from my Mac, including app settings, and I've had to set up my Mac from scratch twice (setting up Siri, Touch ID, etc.), even though no specific commands were issued by an agent

Where does the bug appear (feature/product)?

Cursor IDE

Describe the Bug

Hello,

I am encountering a very unusual and highly disruptive issue that I am struggling to understand.

This morning, for the first time, I experienced a bug where, upon launching an agent, I noticed that my VS Code theme suddenly disappeared and was replaced by the default Cursor theme. A few seconds later, I received a macOS popup indicating that my iCloud Keychain was inaccessible. Shortly afterward, all my folders completely disappeared from my Mac.

I then restarted my computer and was forced to go through the full onboarding process again, as if the machine were new: setting up Touch ID, configuring privacy settings, etc. I had to re-clone my GitHub repositories, relaunch an agent, and I encountered the exact same issue again.

As a result, I performed a full factory reset of my Mac and carried out a clean installation of Cursor. However, during this new interaction with the tool, the same issue occurred once more.

For context, I am using a MacBook Pro M4 Pro with 48GB of RAM and 1TB of storage. The device is less than two years old and has never shown any issues before. I would also like to note that when interacting normally with VS Code (outside of Cursor agents), I have not experienced any similar problems.

This situation is extremely concerning. Although I do have a backup from one week ago that I could use for restoration, it is deeply troubling to see thousands of documents disappear without any clear reason. Additionally, this issue renders Cursor completely unusable, despite the fact that I renewed my subscription just two days ago.

I would appreciate your assistance in identifying the root cause of this issue as soon as possible.

Steps to Reproduce

  1. Start from a clean or freshly initialized macOS environment (issue also reproduced after full factory reset).

  2. Install Cursor (latest available version).

  3. Open Cursor and configure it normally (e.g., theme, extensions, GitHub repositories).

  4. Clone one or more GitHub repositories into the workspace.

  5. Launch an agent within Cursor.

  6. Observe that, after launching the agent:

    • The active VS Code theme abruptly switches to the default Cursor theme.
  7. Within a few seconds:

    • A macOS system popup appears indicating that the iCloud Keychain is inaccessible.
  8. Immediately after:

    • Local folders and files on the Mac begin to disappear or become inaccessible.
  9. Restart the machine.

  10. Upon reboot:

    • The system behaves as if it were newly initialized (onboarding process, Touch ID setup, privacy settings, etc.).
  11. Reinstall or reopen Cursor, re-clone repositories, and relaunch an agent.

  12. Observe that the issue occurs again under the same conditions.

The issue has been reproduced even after a full factory reset and clean installation of macOS and Cursor.

Operating System

MacOS

Version Information

Version: 3.12.17 (Universal)
VS Code Extension API: 1.128.0
Commit: 0fb762053c34788bb7760d5673f8a6d4c8589d50
Date: 2026-07-17T02:53:53.006Z (2 days ago)
Layout: Agent Window
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

Does this stop you from using Cursor

Yes - Cursor is unusable

Hey @louisbrulenaudet , I’m sorry about the lost data. A few quick things.

First, until we’ve looked at this together, I’d pause running agents in that project and restore from your week-old backup (or Time Machine, if it was on). A deletion like this usually skips the Trash, so ~/.Trash probably won’t have your files.

One question that will help most: what is your agent’s Auto-Run setting, and is it allowed to run terminal commands automatically (for example, an option like “Run Everything”)? An agent can only run commands without asking when Auto-Run is turned on for that, so that setting is the key piece here. As a safeguard in the meantime, I’d switch Auto-Run off, and only “trust” a project when Cursor prompts you if it’s one you fully control.

Working out the rest means going through things specific to your setup (your settings, the repositories you cloned, and some config files inside them), so could you email us at [email protected]? We’ll walk through exactly what to check and get to the bottom of it there. Best to keep those specifics out of the public thread.

Exact same issue happened to me, I using Mac Intel 2019.

The same issue has happened to me twice — first on July 29/2026 and again on August 3. In both cases, my Mac appeared to create a fresh user environment with the same username, and my previous files were no longer displayed. I can provide the logs if it helps to figure out the issue.

Same happend to me 3rd time. All apps were deleted and even all data, mac notes, keychain, etc all were deleted everytime. Even today, all our github reposirories were also showing bot commits on my name as well.

Do you think this limitation only affects the IDE, or does it also apply to the CLI? This is an important point, as it would allow us to use the CLI to consume the quotas (similar to what we can do with Claude Code) and avoid wasting them. Depending on the subscription tier, this could become quite costly.

I honestly don’t even know where to begin.

Finding this thread is both a relief and incredibly frustrating because for the last week I’ve been questioning whether I was losing my mind. Everyone kept telling me it had to be something I did, but after reading this, I’m no longer convinced I was the only one.

My timeline has been an absolute nightmare:

  • July 28: My development folder suddenly disappeared along with my Desktop files while I was working. I had no idea what had happened and assumed it was some strange macOS issue.

  • July 29: It happened again. At that point I completely erased my iMac and performed a clean installation of macOS because I no longer trusted the machine.

  • August 4: After spending hours reinstalling everything, setting up my development environment again, restoring tools, cloning repositories, configuring my machine, and getting back to work… it happened again.

  • Today: I’m still trying to understand what happened and whether months of my work are gone forever.

This wasn’t just a few project files disappearing.

My entire development folder was wiped. My Desktop was empty. Even applications like Google Chrome and other installed software were gone. After restarting, macOS behaved like it had never been configured before. I had to go through the welcome screens again, set up Touch ID, privacy permissions, and everything else from scratch.

Do you have any idea how exhausting it is to spend an entire day rebuilding your machine, only for it to happen again?

The worst part came afterward.

Once I reinstalled macOS, I cloned my repositories from GitHub expecting to continue development, only to discover that many repositories appeared to contain much older code than what I had been working on. Multiple branches were suddenly pointing to the same older commit, and months of development appeared to be gone. Even more confusing, I found what looked like automated or bot-generated commits around the same timeframe, almost as if the repositories had been force-pushed or reset to an older state. I still don’t know what caused it, but it has left several of my repositories in an unexpected state.

This has easily been one of the most stressful experiences I’ve had as a developer. Countless hours of work, multiple macOS reinstalls, rebuilding my environment over and over again, and now facing the possibility that months of development may be unrecoverable. It’s mentally draining, financially damaging, and honestly devastating.

I’m begging the Cursor team to treat reports like this with the highest priority. If there is even the slightest possibility that agents, terminal execution, Auto-Run, or any other component could contribute to destructive behavior, it needs immediate investigation.

And to everyone reading this: if you’ve experienced anything remotely similar, please reply. Even if you think it’s unrelated. Development folders disappearing, Desktop files being wiped, applications being removed, macOS behaving like a fresh installation, or repositories appearing to revert to older states—I want to know I’m not the only one dealing with this.

At this point I just want answers. I’m more than willing to provide logs, diagnostics, system information, or anything else that helps identify the root cause, because I genuinely don’t want another developer to go through what I’ve been through.

Thanks to everyone who’s added their experience here, and I’m sorry for how disruptive this has been. What several of you are describing (local files, apps, and settings disappearing, and macOS asking you to set the machine up again) is not expected, and we want to understand it with real data from an affected machine.

Because this depends on your specific setup, logs, and repositories, the best place to dig in is privately. Could each of you email [email protected] and include as much of this as you have:

  1. Your Cursor version (Cursor menu > About Cursor) and your macOS version
  2. The folder you had open as your workspace when it happened (your home folder, a broad folder like ~/Documents, or a specific project folder)
  3. Whether Auto-Run (automatic terminal command execution) was on
  4. If you still have it: the agent chat and terminal history from that session, plus the output of ls -la ~ and a look inside ~/.Trash right afterward
  5. The repositories you had cloned, and whether you re-clone the same ones each time

@SH_App_Team and @a1cedcda9b2212c169e0, you also mentioned repositories showing older commits and commits you don’t recognize. That’s separate from the local file changes and worth looking at closely, so please also include (in the email, not publicly) the affected repo, the exact author name and email shown on those unexpected commits, and roughly when they appeared.

A few safety steps while we look, and sorry to be cautious: pause running agents in those projects, back up anything you still have, and if possible hold off on another full reinstall, since that erases the logs that would help us pinpoint the cause. If Cursor asks you to trust a project, only trust ones you fully control.

@louisbrulenaudet on your question: I wouldn’t treat the CLI as safer than the IDE here, since both can run agent and terminal commands. Happy to go deeper once we have the logs.

Same is happening to me. Happened four times now.

Yesterday, I experienced a serious issue with Cursor that resulted in the loss of all the files on my Mac.

It started with a message saying, “Keychain login cannot be found to store…”. It repeatedly asked for my iCloud password and then prompted me to reset the keychain to its default settings. After I restarted my Mac, everything was gone—my wallpaper, all of my files, and the project outputs that I had spent hundreds of dollars generating.

I have tried everything I could to recover the data, but unfortunately I do not have any backups.

To make matters worse, when I switched to my Windows laptop and opened Cursor, my laptop immediately restarted. Fortunately, no data was erased on Windows, but it is extremely concerning that simply launching Cursor causes the system to restart. If it had erased my Windows data as well, I would have considered taking legal action because of the amount of valuable work that would have been lost.

Please help me recover my data if there is any possibility of doing so. If recovery is not possible, I at least need assistance in identifying why Cursor is causing my Mac and Windows laptops to restart whenever I open the application, and how to prevent it from happening again.

@Nikhilreddyu - A few things in order of what matters most.

On recovery: if you can, stop using that Mac for anything heavy right now, since continuing to write to the disk lowers the chance of getting anything back. Then check, in this order: Time Machine (if you ever set up a backup drive or network target), iCloud Drive at icloud.com (if Desktop and Documents syncing was ever on), and ~/.Trash. If those are empty and there was no backup, the honest answer is that full recovery may not be possible, but a reputable local data-recovery service is the best remaining option while the disk is left untouched.

So we can dig into the cause with you, please email [email protected] with:

  • Your Cursor version and macOS version
  • The exact keychain message you saw, and roughly when it appeared relative to the loss
  • The folder you had open as your workspace, and whether Auto-Run was on
  • If they still exist: your Cursor logs (in Cursor: Developer: Open Logs Folder, then zip the folder) and anything in ~/Library/Logs/DiagnosticReports named Cursor* or Electron*

On the Windows laptop restarting when you open Cursor: that looks like a separate issue from the file loss, and it’s not something that would erase data on its own. It usually points to a graphics-driver level crash. When you’re ready, updating your GPU drivers and launching once with cursor --disable-gpu is the usual fix. Include your Windows version in that same email and we’ll look at it alongside the rest.

I know this is a lot. Send that email and we’ll take it from there.

Hey guys, some good news: I was able to narrow down what seems to be triggering the issue on my Mac.

Thanks, Mohit, for the suggestions. I tested different setups and found that the “Keychain not found” error consistently returns when I use my previous Conda environment containing the npm/Node packages.

I created a new Conda environment without those packages and ran the backend, and everything worked normally. When I switched back to the old environment, the error returned.

I suspect something in the npm/Node packages may have been compromised, although I can’t confirm that yet. Could you try reproducing this on your side and see if you find anything?

If the “Keychain not found” behavior tracks exactly with the environment holding those npm/Node packages, it points to something in one of those packages running code on your machine, not Cursor itself. That fits a wave of npm supply-chain compromises going around lately.

Because this class of package can steal credentials, treat that Mac and anything you signed into on it as exposed and do this first:

  1. Rotate credentials from a clean device - GitHub tokens/SSH keys (the likely cause of the unexpected “bot” commits others saw), npm tokens, cloud keys, and any .env secrets used in that project.
  2. Rebuild clean - delete node_modules and reinstall from a lockfile pinned to versions from before this started, instead of reusing the old environment.
  3. Reinstall any affected apps from the official source, since this class of malware tampers with local app files.

To help pinpoint the exact package, email [email protected] the package.json + lockfile from that old environment (keep the package names out of the public thread until it’s confirmed) and we’ll help you track down the culprit.