Skip to main content

How to Hide Drives In Windows Using CMD

  1. Open Command Prompt as Administrator. This can be done by searching “cmd” in Start Menu search and then running it as Administrator.
  2. opening command prompt
  3. Now type “diskpart” inside “CMD” and hit “Enter”.
  4. Now type “list volume” and hit “Enter”. This will list all the disk drives on your computer.
  5. Now choose the volume you want to hide. Then type “select volume x” and hit Enter. Replace x with the volume number you want to hide. The volume numbers are written in the column “Volume ###”.
  6. Now type “remove letter y” and hit Enter. Replace y with the drive letter. The drive letter can be found in the “Ltr” column.
hide drives windows cmd
Your drive would be hidden till now. If it is still being displayed, then try restarting your PC.


Getting Back The Hidden Drive Using CMD
  1. Open CMD, type diskpart, then list volume, and then select volume x, as you did while hiding the drive.
  2. Now instead of typing “remove letter y”, you need to type “assign letter y” and hit the Enter key. Change y with the letter you want to assign to this drive. For security and integrity, type the same letter which was assigned to this drive earlier.
show drive cmd
That’s it. You will start to see the drive in Windows Explorer as soon as you do this. If it’s not there, try restarting your PC.
NOTE DiskPart is a very powerful tool. If you mistype any command, you may lose your information or you might end up corrupting your Windows installation. Proceed with caution. We will not be responsible for anything that follows.

Comments