How to lock or unlock the hard drive

Updated: 10/30/2017 by Computer Hope

Computer hard driveNote: The commands below only work in versions of Windows prior to Windows XP. To lock or unlock a hard drive in Windows XP or later versions of Windows, use BitLocker or a third-party software program designed for locking and unlocking drives.

You need to open a command prompt window to unlock or lock the hard drive. In Windows, click the Start button and enter cmd in the Search field, then press the Enter key.

To unlock the hard drive

unlock x:

The x represents the letter of the hard drive that you want to unlock. For example, if you needed to unlock the C: drive, you would type unlock c:

To lock the hard drive

lock x:

The x represents the letter of the hard drive that you want to lock. For example, if you needed to lock the C: drive, you would type lock c: at the command prompt.

Additional information