If you are working with a corrupted file, you are likely to encounter a system message stating that you have file corruption. Additionally, issues while accessing, opening or transferring files could also indicate a possible file corruption.
Talking about what caused the corruption, it is very likely that files in the USB drive got affected by a malicious application. Besides malwares, abruptly removing the USB drive or a sudden power loss while performing read/write operation are well known causes for a file to be corrupted.
Once you are sure that the file is corrupted, recovering it should be the first school of thought. Although the data can be recovered, be advised that once corrupted, the chances of getting them back are pretty slim. Regardless, we have tried our best to gather useful methods on recovering corrupted files from a USB drive.
Recover Corrupted Files from USB Drive
Now that you know some causes on how a file can get corrupted, let us now see how you can recover them. The first thing you can do is check if the data blocks on your drive are corrupted. To do this, you can try performing a disk scan.
Scan USB Drives
You can use the chkdsk command to scan both internal and external storage devices for errors. Once the scan is complete, it creates a status report about your disk based on its file system. Furthermore, it lists, corrects and tries to recover data on the disk.
- Press the Windows + R key to open Run.
- Type cmd and press Ctrl + Shift + Enter to open the Command prompt as admin.
- Type
chkdsk <volume>: /r
. Replace <volume> with the USB drive letter.
You can also scan your USB flash drive from Windows Explorer.
- Press Windows + E to open File Explorer.
- Click on This PC.
- Right-click on the USB drive you want to scan.
- Go to Properties.
- Navigate to the Tools tab and click on Check.
- Select Scan drive.
Repair File Attributes
A file getting corrupted can mean multiple things. In some cases, it could be that the corruption causes the file attribute to change, which simultaneously results in the file to be hidden. To fix this you can try running the ATTRIB command.
The attrib command can display, set or remove file attributes. In our case, we will clear file attributes on the USB drive containing the corrupted file.
- Press the Windows + R key to open Run.
- Type cmd and press Ctrl + Alt + Enter to open Command Prompt as admin.
- Type
ATTRIB -H -R -S /S /D X:*.*
and press Enter.
Once the command runs, you should be able to see the corrupted files on the flash drive.
Restore Previous Version
Windows has a special backup feature that is available on all Windows versions after Windows 7. You can restore your USB drive if you have previously enabled this feature. It creates a history of file details at certain times.
Using this restore point, Windows restores corrupted files or even folders.
- Open File Explorer.
- Right-click on the USB flash drive and select Properties.
- Go to the Previous Version tab.
- Select the latest version of the USB drive and select Restore.
Use Recovery Software

If none of the solutions works, you can try using a recovery tool. Recovery tools use complex algorithms and advanced programming to recover corrupted files from a storage device and should work in most cases.
One thing to keep in mind is that you need to be wary when downloading hard disk recovery software. There are cases where the recovery application itself contains malware, corrupting your entire system.
Some Preventive Measures
If you are able to recover corrupted files from the USB flash drive, we recommend that you perform necessary measures to prevent things like such from happening again.
The first thing you should know is abruptly removing the USB flash drive could corrupt the files or the USB drive itself. Therefore, make sure that you remove the USB drive only after right-clicking the flash drive and ejecting it.
Scan USB Flash Drive
One primary precaution you could perform time and again to prevent files from getting corrupted is scan the USB device. When you scan your drive, the system goes through the files and folders and checks for any malicious activity that could potentially affect your USB drive.
- Press the Windows + E to open File Explorer.
- Go to This PC.
- Right-click on the USB drive and click on Show more options.
- Click on Scan with Microsoft Defender.
- Select Scan now.
Windows Defender will start the scanning process and give you a report about the details of the scan. Make sure that you perform these scans every now and then.
If you have antivirus installed on your PC, you can also use this application to scan your USB drives.
Check Drive Status
You can check the status of the storage device using S.M.A.R.T. Self-Monitoring, Analysis, and Reporting Technology (SMART). It monitors storage devices connected in your system and determines whether the device is failing.
- Insert the USB flash drive into the PC
- Press the Windows + R key to open Run.
- Type cmd and press Ctrl + Shift + Enter to open the Command prompt as admin.
- Type
wmic diskdrive get model, status
and press Enter.
Here, you will see the list of storage devices connected to the system and its status. OK means the device does not have any issues. The status will display Pred Fail if there is any issue with the device.
If it indicates Pred Fail, we recommend that you backup files from these USB flash drives.
Format USB Flash Drive
Formatting the USB drives not only removes all the data on your storage device but also sets it to the state it was when you took it out of the package. By doing this, the system will clear all the memory blocks and reset them, eliminating any risks of possible data corruption.
However, make sure that you backup files in your USB drives before formatting it.
- Open This PC.
- Right-click on the USB drive and select Format.
- Select the File System as Fat32 or NTFS.
- Click on Start to begin the formatting process.