Format Hard Drive Partition with DiskPart Command Line

Format disk is necessary before using and sometimes you need to format disk partition in a terminal for it to work properly.

It can happen, that some other operating system formatted your disk (or USB drive) and now you don't see it on My computer. In that case, use DiskPart.

1. Start CMD (Windows Terminal): click Windows button, type 'cmd' and push Enter.

2. In the command line type:


3. Check available disks

DISKPART> list disk

4. Select a disk, you want to format (eg. 3)

DISKPART> select disk 3

5. Clean the selected disk


6. Create a primary partition

DISKPART> create partition primary

7. Select first partition

DISKPART> select partition 1

8. Format the partition (to eg. fat32)

DISKPART> format fs=fat32 quick

9. Exit the DiskPart


Your disk is now properly formatted.