How to permanently remove data from a disk, USB flash drive, or memory card using CMD alone—without the need for programs
We must make sure that all of our data is deleted or wiped clean when we switch computers or want to sell an external hard drive, USB memory stick, or memory card so that the person we are selling it to cannot recover it. However, a recent study found that two-thirds of the storage devices sold manually were not properly erased by users. G Given the significance of the subject, we will describe how to permanently delete data from a card, USB memory stick, or hard drive so that it cannot be recovered using third-party tools.
We can permanently remove files from your Windows hard drive using some of the greatest programs. But many people might not be aware of it, Windows has a built-in tool that lets us permanently remove data from a disk, memory, or card.
The program in question is called Cipher, and it is a command-line tool that allows you to permanently erase all of the data that has been erased from your hard drive. The first step in using Cipher is to launch a CMD window with administrator rights (run as administrator).
In order to scan and track the folder or drive we wish to delete, we should type the cipher command followed by /w when we are in front of the CMD command line. For instance, we would use the following command to retrieve files from our disk, USB, or connected card:
/W:F Cipher
where F stands for the letter of the drive that is connected to the computer and from which we wish to permanently remove the data.
The cipher tool will make three passes over the unused or unallocated space on the specified device or volume. The first pass will overwrite all spaces with zeros, the second pass will overwrite all spaces with zeros, and the third and final pass will overwrite random numbers. This ensures that the space freed up when files and folders are deleted will be overwritten, permanently erasing the data we deleted from the disk and making it unrecoverable.