How to Fix OneDrive Closing When Clicking Unlink This PC
Question details
The user is trying to unlink their OneDrive account to change the local folder location, but clicking the unlink button causes the application to crash or close unexpectedly.

- Product
- OneDrive
- Device & OS
- not provided
- Scenario
- Attempting to unlink a OneDrive account from a PC in order to move the local sync folder to a different drive (e.g., from Drive C to Drive B).
- Observed behavior
- OneDrive abruptly closes instead of disconnecting the account, preventing the user from successfully changing the folder location.
Ensure your destination drive is securely connected to your computer and that your Windows user account has full read and write permissions for the new drive location.
Reset the OneDrive Client
Resetting the OneDrive application clears local temporary data and can resolve unexpected crashes when interacting with account settings.
A sudden closure or crash is often caused by corrupted cached data within the application. Executing a built-in reset command forces OneDrive to rebuild its configuration without deleting your synced files.
Press the Windows key + R simultaneously on your keyboard to open the Run window.
Type '%localappdata%\Microsoft\OneDrive\onedrive.exe /reset' into the box and press Enter or click OK.
Wait a few minutes. If the OneDrive cloud icon does not reappear in the system tray, open the Start menu, search for OneDrive, and launch it manually.
Right-click the OneDrive icon in the system tray, go to Settings, select the Account tab, and click 'Unlink this PC'.

Reinstall Microsoft OneDrive
If resetting does not resolve the crash, reinstalling OneDrive ensures that any corrupted installation files are completely replaced.
Set Up the New OneDrive Folder Location
Once you successfully unlink the account, follow the correct sequence to move your local folder to the new drive.
Experience Hassle-Free Cloud Syncing with WPS Office
If you frequently encounter sync crashes or setup issues with Microsoft OneDrive and Office, consider switching to WPS Office. It provides a lightweight, reliable built-in cloud storage system (WPS Cloud) and serves as a powerful, free alternative to Microsoft Office, fully supporting all your standard document formats.
- 1. Download and Install: Get the free WPS Office suite from the official website and run the quick installer.
- 2. Sign in to WPS Cloud: Create or sign in to your WPS account to automatically activate 1GB of free cloud storage.
- 3. Sync Documents Automatically: Save your documents directly to WPS Cloud to access them effortlessly across all your devices.

Frequently Asked Questions
Will unlinking my OneDrive account delete my local files?
No. Unlinking your PC from OneDrive simply stops the syncing process. Your files will remain safely in the local OneDrive folder on your computer, as well as in the cloud.
How do I change the location of my OneDrive folder?
You must first unlink your account by going to OneDrive Settings > Account > Unlink this PC. When you sign back in, click 'Change location' on the folder setup screen to choose a new drive or directory.
Can I have multiple OneDrive accounts on the same PC?
Yes, you can run multiple OneDrive accounts if one is a Personal account and the others are Work or School accounts. However, you cannot run two Personal OneDrive accounts simultaneously on the same Windows user profile.
What should I do if my target drive isn't recognized by OneDrive?
Ensure the drive is formatted correctly (NTFS is recommended for Windows) and that you have full administrative read/write permissions for that drive. External drives that frequently disconnect are not recommended for OneDrive sync folders.




