1 – If you’re using Windows 8 or 8.1, press the Windows+S key to open a “Search” box. If you’re using Windows 7 or Windows Vista, just click the Start button and a search box will automagically appear.
2 – Type diskpart into the search box.
3 – Right-click on diskpart.exe, then click Run as administrator. The Diskpart utility should open.
4 – Type list disk, then press the Enter key. This should display a list of all drives that are connected to your computer, and it should look something like the screenshot below:
5 – Examine the list of drives to determine the Disk # of the drive you wish to format.
As a general rule, the listed size of a given drive will be slightly smaller than its actual size. In my case, I’m using a 4GB drive so the one I’m looking for is Disk 7 since 3824MB is slightly less than 4GB.
Important: Be absolutely certain that you have identified the correct drive before continuing. Selecting the wrong drive will result in the wrong drive being formatted and you’ll lose all data that’s stored on that drive.
6 – Once you have determined the disk # of the drive you want to format, type select disk # into the Diskpart utility and press the Enter key. Be sure to replace the # sign with the actual number of the drive. For example, for my drive I would type the following:
select disk 7
You should receive a confirmation that the drive to be formatted has been selected.
7 – Type clean, then press the Enter key. You should receive a confirmation that the drive has been cleaned.
8 – Type create partition primary, then press the Enter key. You should receive a confirmation that the partition has been created.
9 – Type select partition 1, then press the Enter key. Again, you should receive a confirmation message.
10 – Now, you’re ready to format the drive. Type format fs=ntfs label=USB quick and then press the Enter key. After a delay (the length of the delay will depend on the size of the drive), you should receive confirmation that the drive has been formatted.
You’re done! Click the X in the upper right-hand corner of the Diskpart window to close it. Your USB flash drive should now show up in Windows Explorer.