Many people use flash drives to transfer files from one place to another. The flash drive is a great tool to have, as it enables this. However, a somewhat common occurrence is that the files you put on your flash drive become corrupt.
This of course means that the files won’t work as intended. Now, naturally, that isn’t what we want. That begs the question: How do you fix files that get corrupted when copied to a flash drive?
The most common fix to the issue is to recover the files by restoring a corrupt folder to its previous version. This requires that you have so-called file history or a previous restore point on your computer, but most people do. Of course, this isn’t the only viable fix to the issue, and in some cases, other solutions are required.
Now that you know the most common way to fix this issue, continue reading to find out more solutions. A few things to mention before we get to the solutions: when you remove a flash drive from a computer, don’t just yank it out of there.
Instead, right-click the device in the bottom right of your desktop, where your programs are bunched up, and select “safely remove hardware”. This will prevent future issues.
Other things to keep in mind are to replace flash drives every now and then since they don’t last forever, and also make sure to always have backups of your files on your computer before you put them on a flash drive.
1. Scan the Flash Drive For Errors
You can try to scan the flash drive for file errors within it, and then try to repair them. This doesn’t always work, mind you, but it’s certainly worth trying. To do this, simply follow the steps below.
- Insert your flash drive with the corrupt files into a USB port on your computer
- Go to the file explorer and look for a removable disk on the left-hand side, next to your hard drives
- Right-click it and select Properties
- Click on the Tools tab
- Click on Check and then follow the steps
And you’re done. Remember to safely eject the flash drive when you want to remove it from your computer.
2. Recover Files Using Command Prompt
Another potential solution is to use the ATTRIB command in the command prompt. This essentially tells your computer to store files in a particular manner on your drive, using the drive’s different read/write attributes.
So, let’s go through the particulars. Follow the steps below to try this fix.
- Type cmd in the Windows search bar, then right-click the program and select Run as administrator
- Copy and paste this line of text into the black window and then press Enter: ATTRIB -H -R -S /S /D X:*.*
Now, you’re done. This can sometimes help in repairing files, but it’s mostly useful in protecting the issue from occurring in the future. I would pair this solution with solution number 1.
3. Check Your Computer For Malware and Viruses
Malware and viruses can easily corrupt your files, so if this is happening in spite of your ejecting the hardware safely and taking other precautions, you should consider scanning your computer and clearing out malware.
Quite frankly, you should probably scan for malware and viruses either way, it won’t hurt your computer. If you don’t have any AV program installed, such as McAfee or Norton, you can use Windows defender.
Run virus scans every so often to ensure that your files and computer are needlessly in danger.
4. Restore Previous Versions of Folders
As I mentioned briefly before, you can try using the restore function to try to restore the files to their original state, before they were corrupted. This should fix them, as long as you have taken precautions so that it doesn’t happen again.
To restore the previous versions of your folder with the corrupt files, follow the steps below.
- Right-click the folder with the corrupted files when you have connected your flash drive to your computer
- Select Properties
- In the tabs at the top of the new window, select Previous Versions
- If there are any previous versions registered, they will show up in the space in the middle of the window. Click on the earlier version
- Select Restore at the bottom-right
The print screen above is from an example folder. As I mentioned previously, the old versions of the folder will be listed for you if they’re available.
5. Enable Better Performance In Device Manager
Users have reported that they solved their issue using a function in the device manager, called “enable better performance”. If you want to try this solution, feel free to follow the steps below.
- First, search for device manager in the Windows search bar and then click it
- Double-click Disk drives, and right-click on your connected flash drive
- Select Properties
- Click the Policies tab, then tick the Better performance box
After this, restart your computer. You’re done! Try putting some files on the flash drive to see if it worked.
6. Format Your Flash Drive
If the flash drive doesn’t work properly, you should try to format it to fix this. When you format a drive, you prepare it for file storage. Put your files somewhere else, before formatting the flash drive, as it will delete the root folder and file system table.
- Go into the file explorer by clicking the yellow folder icon, then select This PC on the left
- Under Devices and drives, right-click your connected flash drive and select Format
- In the file system drop-down menu in the next window, select FAT32 if you have an older operating system, and exFAT if you have Windows 10 or 11.
- Select the default alternative for Allocation unit size
- Under Volume label, select your flash drive
- Select Quick format under Format options, then follow the steps after pressing Start
FAT32 and exFAT are simply the file systems used on your flash drive. FAT32 is the default option for most flash drives, and exFAT is the optimal file system for USB flash drives.
7. Reinstall Flash Drive Drivers
Faulty drivers can be the cause for corrupting files, as they are pivotal for any device to work properly. That’s why should try to reinstall your flash drive’s drivers. This can be done easily through the device manager. Follow the steps below.
- First, search for device manager in the Windows search bar and then click it
- Double-click Disk drives and then right-click your flash drive
- Select Uninstall drivers
- Remove the flash drive, then restart your computer
- After restarting, insert the flash drive again and let the computer install the drivers
8. Insert Flash Drive Correctly
Another thing that can mess with the files on your flash drive, is an incorrect insertion of the flash drive in one of your computer’s USB ports. When you plug the device in, confirm that it’s connected properly. A loose flash drive may well corrupt the files that you put on it.
You can also try connecting the flash drive through another USB port on your computer. Sometimes, single ports can be faulty and lead to issues.