If you share your computer with others, an easy way to protect your sensitive information from prying eyes is to hide certain folders or files. But how to hide the local drive?
In Windows, you can hide any file or folder by checking the “Hidden” checkbox in the file properties. Since this method is not very reliable and takes a lot of time, Especially if you have multiple files or folders that you want to hide, the best way is to move all the files/folders to another drive and then hide the entire drive.
In Windows 10, you can hide an entire local drive in My Computer or File Explorer using various methods, such as Disk Management Console, Registry Editor, Command Prompt, or Group Policy.
In this article, you will find detailed instructions on how to prevent a local drive from appearing in Windows Explorer. (Instructions apply to all Windows versions)
How to Hide Local Drive in File Explorer and My Computer in Windows 10
- Hide the disk in Disk Management.
- Hiding a drive using the command line.
- Hiding the drive using the registry editor.
- Hide Drive using Group Policy.
Method 1: How to Hide Local Drive in Disk Management Console.
In the Disk Management console, we can partition drives, assign drive letters, and hide memory drives with sensitive information. To hide a local drive, go ahead and remove its drive letter using disk management:
1. click on Windows key + R To launch the Run window, type diskmgmt.msc and select OK.
2. Right click on the drive or partition you want to hide Change the drive letter and paths.
3. Select the drive letter and click on it Turn off button.
4. A window will appear with a warning message, select Yes to confirm.
5. After going to File Explorer, you will notice that the drive is no longer there.
To show a disk in Disk Management:
1. Go to this location again when you want to view the contents of the disk disk management again, right click on the hidden drive and select Change the drive letter and paths.
2. Select in the window that opens Add.
3. Provide Assign the following driver letter If selected from the drop-down menu, select the preferred drive letter (eg “E”) and click OK continue.
Method 2: How to hide a local disk or partition using the command line.
The next way to hide a specific local drive is to remove its drive letter using the DISKPART utility at the command line (or PowerShell).
1. click on Windows key + R To launch the Run window.
2. Type cmd and press Ctrl + Shift + Enter to open Command line as administrator.
3. In the Command Prompt window, type the following commands in order:
4. Your screen will now show all the drives and partitions on your computer with the drive letter assigned to them.
5. Pay attention Volume number Select the drive/partition you want to hide the drive letter and issue the following command to select that Volume. *
*Note: where”#” indicates the volume of the drive you want to hide. For example, to hide drive “E” in “volume 5”, enter the following command:
6. Now type the following command to remove the drive letter from the selected folder to hide it:*
*Note: where”X:” indicates the drive letter of the selected folder to be hidden. For example, if you want to hide the drive “E:” in the folder “5”, enter the following command:
7. Finally write Exit to close the DISKPART utility and you’re done! The selected drive is no longer visible in Explorer.
To display a disk in DISKPART:
To display the disk/partition and view its contents, proceed as shown below and reassign the drive letter.
1. It’s open Command line as administrator.
2. Enter the following commands in order:
3. Pay attention Volume number the disk/partition you want to display.
4. Type the following command and click to select the hidden volume Enter. *
*Note: where”#” indicates the volume number of the disk/partition you want to display. (eg volume “5” in this example).
5. Finally, issue the following command to reassign the drive letter:*
*Note: where”X:” indicates the drive letter you want to assign to the hidden volume. (for example, the letter “E:” in this example).
6. At this point, the hidden drive will be displayed in File Explorer.
Method 3: How to hide a local drive in the registry.
Registry Editor is another effective tool for hiding local drives from prying eyes.
Important: Making the wrong registry changes can seriously damage your device and require you to reinstall Windows. Therefore, be careful when making changes to the registry editor and always back up the registry before making any changes.
1. click on Windows and R buttons to open Running command window.
2. Type regedit and beat Enter: *
*Note: If you see a User Access Control (UAC) warning box asking for permission, click on it Yes.
3. In the registry editor, navigate to the following path:
4. Right click to the space on the right and select new > A DWORD (32-bit) value.
3. Name the new value NoDrives and press Enter.
4a. Double click when newly created NoDrives select the value and select Ten In the basic options.
4b. Now change the value data to the number corresponding to the drive letter according to the table below and click OK.*
For example, to hide the “E:” drive, enter “16” in the “Value data” field.
*Note: See the table below to find value information for each drive letter.
5. When finished, close the registry editor and restart your computer to apply the changes. *
1. To undo the change and display the drive letter, open the registry editor again and turn off the NoDrives The DWORD value in the registry shown above and restart your personal computer.
2. Note that this method may not be the best way to hide a local drive, as users can access the contents of the disk using other methods, for example, by entering the hidden drive letter (if they know it) in the address bar of File Explorer. or in the Run dialog box.
Method 4: How to hide local drive in Group Policy Editor. *
The last way to hide a local drive in Windows is to use the Group Policy Editor*.
*Notes: This method is only valid for Windows 10 Pro/Enterprise/Education and Windows Server editions.
1. press at the same time Windows + R Buttons to open the Run command window.
2. Enter in the text field of the dialog box gpedit.msc and beat Enter To open the Group Policy Editor.
3. In the Group Policy Editor, navigate to the following path.
- User Configuration -> Administrative Templates -> Windows Components -> File Explorer
4. On the right side double click to open Hide these displayed drivers in My Computer politics.*
* Information: This policy setting allows you to remove icons representing selected hard drives from My Computer and File Explorer. Additionally, the drive letters representing the selected drives do not appear in the default Open dialog box.
4. Select in the new window that opens Enabled and from the drop-down menu below options, select the drive letter* you want to hide. Click when done Please apply and OK.
*Note: If you don’t see the drive letter you want to hide, use one of the methods above because group policy doesn’t allow hiding all drives/letters. (Yes, this is another good job from MS!)
5. Close the Group Policy Editor.
6. Register now File Explorer to verify that you no longer see the drive you hid. (if you don’t see a change, close and reopen File Explorer) *
1. Just install to display the drive Hide these displayed drivers in My Computer policy for Not configured.
2. Note that this method may not be the best way to hide a local drive, as users can access the contents of the drive using other methods, such as typing the hidden drive letter (if they know it) in File Explorer. line or in the Run dialog box. In addition, these policy settings do not prevent users from using other programs to access the disk and its contents.
That’s it! Which method worked for you?
Let me know if this guide helped you by leaving a comment about your experience. Please like and share this guide to help others.