Resolving Duplicate OneDrive Icons in Windows File Explorer
Windows File Explorer sometimes displays redundant OneDrive entries in the navigation pane. This behavior occurs because the system registers distinct CLSIDs (Class IDs) for personal and professional OneDrive accounts, leading the Shell Namespace to render multiple shortcuts.
The Root Cause
The Shell Namespace treats navigation items as dynamic system objects. These are defined within the Windows Registry under HKEY_CLASSES_ROOT\CLSID\. Simply deleting the registry keys often fails because the OneDrive client monitors its configuration and automatically restores missing entries upon launch. The display properties for these objects are controlled by the Attributes binary value within the ShellFolder subkey.
Suppressing Redundant Entries
Rather than deleting the registry key, you can modify the Attributes bitmask to hide the specific entry while preserving the underlying functionality. To hide the corporate or secondary OneDrive icon, follow these steps:
- Open the Registry Editor (
regedit) and navigate to:HKEY_CLASSES_ROOT\CLSID\{04271989-C4D2-F137-CD4A-E7469C02C97A}\ShellFolder - If you encounter permission errors, right-click the
ShellFolderkey, select Permissions, navigate to Advanced, and take ownership of the key, granting your user account "Full Control." - Locate the
AttributesDWORD value. Typically, the default value is0xf080004d. - Update the value to
0xf090004d. This addition of the0x00100000flag instructs Windows to hide the icon from the user interface. - Restart the Windows Explorer process via Task Manager or log out and back in to apply the changes.
Automated Registry Update
You can automate this configuration using a registry script. Save the following text as a .reg file and execute it to apply the hidden attribute automatically:
Windows Registry Editor Version 5.00
[HKEY_CLASSES_ROOT\CLSID\{04271989-C4D2-F137-CD4A-E7469C02C97A}\ShellFolder]
"Attributes"=dword:f090004d
This method ensures the icon remains hidden even if the OneDrive cleint attempts to repair its registry settings, as the modified bitmask is treated as a valid configuration by the system.