Advertisement

How to Completely Uninstall OneDrive in Windows 11

You can now uninstall OneDrive in Windows 11, as in early March 2024, Microsoft released a new technical support document confirming that. Company's official website outlines the process of disabling and deleting the OneDrive cloud service account for Windows 10/11 users. The documentation now includes detailed instructions on how users can disable, hide, or completely remove the OneDrive service from their computers if they no longer wish to use it.

Advertisеment

OneDrive is a cloud storage service introduced by Microsoft in 2007. In 2014, it was renamed from SkyDrive to OneDrive due to trademark issues. By default, the Documents and Pictures folders are synchronized with OneDrive in Windows 11 when user access settings are configured.

To uninstall OneDrive from Windows 11 or 10, do the following.

Uninstall OneDrive in Windows 11 (official method)

  1. Open the Settings app by pressing Win + I, or with any other method you like.
  2. Navigate to Apps > Installed apps.Settings > Installed apps
  3. In the program list on the right, scroll down to Microsoft OneDrive and click the three dots next to it.Windows 11 Uninstall OneDrive
  4. Now select Uninstall.
  5. In the next dialog, click Uninstall one more time to confirm the removal. If you're prompted for an administrator password or confirmation, type the password or provide confirmation.Confirm removal
  6. The OneDrive will now be removed.

You are done!

Previously, Microsoft's documentation did not provide as much information on disabling OneDrive, but now users have the freedom to manage the service on their PC. This includes the ability to delete the OneDrive folder, disable synchronization, cancel a subscription, and sign out of the service.

Additionally, the dedicated support page officially confirms that OneDrive can be deleted in Windows 11, whereas previously this option was only mentioned for Windows 10.

In addition, you can use winget to uninstall OneDrive in Windows 11.

Remove OneDrive with Winget

  1. Press the Win+X keys on the keyboard (or right-click the Start button).
  2. Select Terminal(Admin) to open the Terminal app elevated.Open Terminal As Admin
  3. Type the following command, and press Enter to execute it: winget uninstall onedrive.Uninstall OneDrive with Winget
  4. Wait for the winget to finish the removal and you are good to go.

You are done.

💡If you aren't familiar with winget, its name means  "Windows Package Manager". The app is a powerful command-line utility that aims to simplify the installation, removal, validation, and retrieval of detailed information for various applications. Winget can help you with searching, downloading, installing, upgrading, and configuring software on each of your PCs with ease. By working in console, winget allows automating app installation.

The reviewed methods will uninstall OneDrive for the current user. This is because the OneDrive per-user client is installed into each user's profile the first time they sign in to Windows. Its files will be placed to the %localappdata%\Microsoft\OneDrive folder. To completely remove OneDrive from your computer, you'll need to sign in as each user and uninstall it.

However, here's a inconvenience. Every time you create a new user account, you'll have to uninstall OneDrive for that user again and again. When you new user signs in, Windows 11 will run the command C:\Windows\System32\OneDriveSetup.exe /thfirstsetup automatically without user's consent. Luckily, there's a way to prevent the app from self-installing. It requires a Registry modification.

Prevent OneDrive from Installing for New Users

To stop OneDrive from installing for new users in Windows 11, do the following.

  1. Open the Registry editor (type regedit.exe in the start menu).
  2. Select HKEY_LOCAL_MACHINE in the left panel.Select Hkey Local Machine
  3. In the Registry editor's menu, select File > Load Hive.Load Hive
  4. In the open file dialog, paste the C:\Users\Default\NTUSER.DAT file path.Paste Path To Ntuser Dat
  5. Now, specify any name for the "folder" in the Registry tree on the left to mount the Default profile file. For example, name it Default_profile.Hive Mount Name
  6. Now, navigate to HKEY_LOCAL_MACHINE\Default_profile\SOFTWARE\Microsoft\Windows\CurrentVersion\Run.Mounted Hive Run Key
  7. Right-click and delete the OneDriveSetup startup entry in the right pane.Prevent OneDrive From Installing For New Users
  8. To apply the changes you made, unload the branch by putting selection on the Default_profile folder on the left, and selecting the File -> Unload Hive menu item.Unload Hive

That's it! Now the OneDrive client will not be installed when new users sign in.

Saving your time

To save your time, you can automate the above steps with three console commands. Say, you can put them to a batch file, and run. Or execute them manually one by one in Terminal opened as Administrator. Here the commands:

reg load "hklm\Default_profile" "C:\Users\Default\NTUSER.DAT"
reg delete "hklm\Default_profile\SOFTWARE\Microsoft\Windows\CurrentVersion\Run" /v "OneDriveSetup" /f
reg unload "hklm\Default_profile"

Finally, if you, your system administrator or computer vendor have preloaded OneDrive by running its installer as Administrator, the situation is quite different. Instead of being installed to the user profile, OneDrive will be installed to the c:\Program Files (x86)\Microsoft OneDrive folder. To get rid of it in such a case, you'll have to run a special command

Completely Uninstall OneDrive for All Users

To remove OneDrive installed to Program Files for all users, do the following.

  1. Press the Win + R keys on the keyboard.
  2. Type or copy-paste the following command into the Run dialog: C:\Windows\System32\OneDriveSetup.exe /uninstall /allusers, and hit Enter.Uninstall OneDrive For All Users
  3. Wait for the OneDrive to be uninstalled.

That's it.

Last but not least, you may want to disable OneDrive from appearing anywhere in the Windows user interface. Windows 11 provides a special group policy for that. In addition, you can disable it startup entry, and even hide the icon from the navigation pane in File Explorer.

If you change your mind, you can restore the OneDrive app with ease. Microsoft offers an installer for that.

Reinstall OneDrive

To restore and reinstall the earlier removed OneDrive app in Windows 11, do the following.

  1. Go to the OneDrive release notes site.
  2. There, click the Download OneDrive for Windows link. Download OneDrive App Installer
  3. Save the OneDriveSetup.exe file to any folder on your computer, and run it.Run The Installer
  4. You will now see the installer user interface with a progress bar, so wait for it to finish.
  5. When OneDrive installation has finished, you can enter your Microsoft Account credentials to set up the file sync.Reinstall OneDrive

That's it.

Now, let's review how to disable OneDrive integration with the operating system without removing the app. It will remain installed, but will not interfere with your PC activity. Here's how.

Disable OneDrive in Windows 11

  1. Press Win + R and type gpedit.msc;  press Enter.
  2. In the Local Group Policy Editor that opens, browse to Computer Configuration\Administrative Templates\ Windows Components\OneDrive.
  3. Double-click the Prevent the usage of OneDrive for file storage policy in the right pane.Prevent The Usage Of OneDrive For File Storage
  4. Select Enabled in the next dialog, click Apply and OK. You can now close the gpedit app.Disable Onedrive

That was easy. But gpedit.msc is missing in certain editions of Windows 11, such as Home. In this situation you can apply a direct registry tweak that configures the policy.

Disable OneDrive with a Registry Tweak

To disable OneDrive integration with Windows 11, do the following.

  1. Run regedit.exe by pressing Win + R and typing regedit.exe in the Run box.
  2. There, navigate to the HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows key in the left panel.
  3. Right-click the Windows folder on the left, and select New > Key from the context menu. Name the new key OneDrive.Create New Key Under Policies Windows
  4. Now right-click the OneDrive key you just created, and select New > DWord (32-bit) Value. Name the new value DisableFileSyncNGSC.Create New Dword Value DisableFileSyncNGSC
  5. Double-click DisableFileSyncNGSC to open it and set its data to 1.Disable OneDrive In Windows 11 Registry Tweak
  6. Restart the computer to apply the change.

That's it! From now on, OneDrive will disappear from anywhere in File Explorer.

In addition, you can want to remove it from startup processes to free up system resources and make the startup a little bit faster. This can be easily done with the Task Manager inbox app.

Remove OneDrive from Startup

  1. Launch the Task Manager app with the Ctrl + Shift + Esc shortcut.
  2. Switch to the Startup apps page.
  3. Find OneDrive in the list of apps, and right-click it.
  4. Select Disable from the menu.Disable OneDrive Startup

This will immediately disable OneDrive from running along Windows.

By default, OneDrive is set to start automatically when the user signs in to his account in Windows 11. In case if the user is using OneDrive, it will directly fetch the latest files from the cloud, or notify about them when the conditions do not allow to download them. If the user is not signed to OneDrive, it will any put its icon to the system tray in the taskbar, and will eventually show a prompt to sign in to it.

By disabling the Startup entry, you'll stop OneDrive from that.

Besides the system tray, OneDrive exists in the left area of File Explorer, the area called Navigation Pane. You can remove its icon from there with another Registry tweak.

Remove OneDrive from Navigation Pane

If you need to hide the OneDrive icon from the Windows navigation pane, do the following.

Firstly, create a REG_DWORD registry parameter System.IsPinnedToNameSpaceTree with a value of 0 in the branch HKEY_CLASSES_ROOT\CLSID\{018D5C66-4533-4307-9B53-224DE2ED1FE6}.

Secondly, sign out from your Windows account, and sign-in back. Voila, the OneDrive icon will disappear.

That's it!

Support us

Winaero greatly relies on your support. You can help the site keep bringing you interesting and useful content and software by using these options:

If you like this article, please share it using the buttons below. It won't take a lot from you, but it will help us grow. Thanks for your support!

Advertisеment

Author: Sergey Tkachenko

Sergey Tkachenko is a software developer who started Winaero back in 2011. On this blog, Sergey is writing about everything connected to Microsoft, Windows and popular software. Follow him on Telegram, Twitter, and YouTube.

Leave a Reply

Your email address will not be published.

css.php
Using Telegram? Subscribe to the blog channel!
Hello. Add your message here.