Duplicated Onedrive icon in explorer

Solution 1:

According to Microsoft Forum Moderator Ruizell Rey:

To resolve your concern regarding duplicated OneDrive entry, follow the steps below:

  1. Search for regedit, and then press Enter.
  2. Open HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\​Explorer\Desktop\NameSpace
  3. Check if you have several folders under NameSpace.
  4. If there are several folders, highlight each folder, and then check the name of the Data on the right hand side.

    OneDrive in Registry Editor

  5. If you see multiple folders with OneDrive as the Data, right click on it, and then select Delete.

    Deleting registry key

Important: This section, method, or task contains steps that tell you how to modify the registry. However, serious problems might occur if you modify the registry incorrectly. Therefore, make sure that you follow these steps carefully. For added protection, back up the registry before you modify it. Then, you can restore the registry if a problem occurs. For more information about how to back up and restore the registry, refer to the following Microsoft Knowledge Base article.

How to back up and restore registry and Creating a system restore point.

Solution 2:

I have another solution, since i didn't find the folder ...\Desktop\NameSpace in my registry.

I searched the registry, using the following settings: Search only by Data, text "OneDrive", comparing the whole string. The fourth entry i found was something like this:

HKEY_USERS\[User-ID]\Software\Classes\CLSID\[XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXX]

The only thing i had to change was setting System.IsPinnedToNameSpaceTree to 0, then the wrong entry disappeared.

If you try this, make sure you copy the key and store it before you make any changes. You can set the key value to 1 again, if you picked the wrong entry.