On Windows 10, when an external drive (USB flash drive, SD card, or secondary drive) stops working due to data corruption or another logical problem, DiskPart can help properly erase everything and start clean with a new partition.
DiskPart is a legacy command-line tool designed to manage drives, partitions, volumes, and virtual disks using Command Prompt, which usually works better than other Windows 10 tools, such as Disk Management and the File Explorer Format feature.
In this Windows 10 guide, we will walk you through the steps to use the DiskPart command-line tool to clean and format a hard drive to fix data corruption and other problems.
Important: These instructions will erase everything on the selected drive, and you cannot undo the changes. If the drive is still accessible, it's recommended to back up the data before proceeding. If you have multiple drives connected to your device, it's recommended to disconnect them to avoid selecting the wrong device.
2023110302