How to Erase My Entire Hard Drive with Command Prompt

By Jedadiah Casey

Microsoft Windows features a powerful command line utility called "diskpart" that is capable of many different functions for hard drives. Some of the included functions include partitioning, formatting, clearing and assigning different areas of the hard drive in a computer. Operations done with "diskpart" can be either destructive or non-destructive. You can erase your entire hard drive with the command prompt by booting from the Windows installation disc and running the "diskpart" utility.

Boot the computer from the Windows installation disc.

Click "Next" at the first prompt.

Click "Repair your computer."

Click "Next."

Click "Command Prompt."

Type "diskpart" without quotes, then press "Enter."

Type "list disk" without quotes, then press "Enter."

Type "select disk 0" without quotes and replacing "0" with the actual number of the drive you wish to erase.

Type "clean" without quotes, then press "Enter." The disk is now completely erased.

Restart the computer.

×