How to format disk using CMD

How to format disk using CMD

Why do we need to format a disk?

The disk we use today mostly comes in HDD and SDD many times this disk is not able to do many things at once. Many times we have to change their format after doing many things due to bad sectors in many files. The disk is unable to work due to bad sectors, many times you see this type of popup on your desktop screen ( windows was unable to format the disk ).


Most of the new computers/ laptop comes with a DOS-based operating system. Then you install the operating system(windows) where you need a hard disk or a flash drive. At that time you need to format your Pendrive or harddisk for the booting process.

But if for some reason your Pendrive or hard disk is not able to format by windows then you must try this method.

First step:- You need to insert your Pen-drive / hard drive into another PC.

Second step:- Then go to start menu and type ” CMD ”. open the cmd by Run as administrator.

Third step:- When the command prompt opens, type the first command diskpart then hit enter.


Fourth step:- Wait for a few seconds now type the second command. ” list disk ” then hit enter.


Fifth step:- Here you can see your all harddrive and Pendrive on cmd menu. Now follow this command to select the device ” select disk 1 ” (in my case: my disk is 1)


Sixth step:- Now type next command ” clean ” then hit enter.


Seventh step:- Now type this command ” create part pri ”for creating partition then hit enter.


Eight step:- Now type” active ”then hit enter.


Final step:- Now the time of original format command. If you are using a disk under 32GB then the command is” fs=fat32 ”or if you are using drive bigger than 100GB then type” fs=ntfs ” here I am using USB under 32GB so i am using command ” fs=fat32 label=usb quick ” then hit enter.


Now type exit and hit enter after then again type exit and again hit enter. Now go to this pc and after that trying to format the drive by right click command. Here is your drive is ready to work.

Let see all the command in a row:-

  1. diskpart
  2. list disk
  3. select disk
  4. clean
  5. create part pri
  6. active
  7. fs=fat32 label=usb quick for 32 GB or fs=ntfs label=usb quick under 100GB
  8. exit

Check out our previous post on Windows problems here:-

Share now

Leave a Reply

Your email address will not be published. Required fields are marked *

Translate ยป