Updated Nov 23, 2026· 9 min read

Key takeaways

  • Your flash drive asks to be formatted or shows RAW? Learn how to repair a corrupted USB drive step by step for reuse, and when to retire it instead.

As an Amazon Associate we earn from qualifying purchases.

A flash drive that Windows asks you to format, or that shows up as RAW, leaves you with a simple choice: repair it for reuse, or replace it. The repair path makes sense only when the files on the drive are already safe, or when they do not matter. A repair fixes the file system so the drive works again; it does not bring back files, and it does not heal worn memory cells. If the data matters, that work comes first, and only then does the repair begin.

This guide is for anyone with a drive that stopped working after an unsafe removal, a power cut, or a bad write, and who wants a usable drive back rather than a rescue job. One warning belongs up front: a repaired flash drive is not trustworthy for anything important. Use it for files that live somewhere else too, for moving data between computers, or for scratch work. Never let it hold the only copy of something you cannot lose.

How to Choose

Is the Data Safe or Gone?

Before any repair tool touches the drive, answer one question: are the files already safe? If yes, repair away. If no and the files matter, stop. Formatting destroys the directory information a recovery scan needs, so a format done in haste can turn a recoverable drive into a blank one. Copy what you can, or run a recovery pass first, and only then think about repair. A drive with nothing to lose is a free experiment; one holding the only copy of a wedding video or a thesis is not. This guide assumes the first case. When the data is safe, every tool below is low-risk, because the worst outcome is a drive that stays broken.

Logical Damage or a Dying Drive?

Corruption comes in two kinds, and only one is fixable. Logical damage means the file system is scrambled while the memory is fine: Windows asks you to format the drive, it shows as RAW, or files appear with strange names. Physical damage means the memory or the controller is failing: the drive disconnects on its own, freezes mid-copy, shows the wrong capacity, or vanishes from computer to computer. Logical damage responds to the tools in this guide; physical damage does not. Tell them apart before you spend an hour on a repair that cannot work. If the drive keeps dropping off or fails the same way on two computers, it is a hardware problem, and no formatting will save it.

Which Repair Tool Fits the Problem?

Each repair tool matches a different failure, so pick the lightest one. Chkdsk is the gentle option: it checks the file system and repairs errors without erasing anything, so it is the right first move when the drive still opens. Format is next when chkdsk cannot help: it rebuilds the file system from scratch, fixing most logical damage at the cost of everything on the drive. Diskpart clean goes further, wiping the partition table, which helps when the drive shows the wrong size or no partitions at all. Low-level format tools are the last resort when every other fix fails. H2testw is not a repair tool; it verifies the repair by writing across the whole drive and reading it back.

How Much Effort Is the Drive Worth?

A repair is worth the time when the drive is large, new, or expensive, and the fix takes ten minutes. A 256 GB drive that fails once after an unsafe removal is worth a chkdsk and a format. A cheap 16 GB drive that has failed twice is not worth another hour. Weigh the price of a replacement against the time you will spend, and be honest about the odds. A drive that fails again after a repair is telling you something: its memory is worn out, and the next failure is a matter of when, not if. Retire it and buy a replacement. The best repair is sometimes the one you skip in favor of a new drive.

Step-by-Step

First, save the files if they matter. If the drive still opens, copy everything off it now. If it does not open and the files matter, recover them before you repair anything — our guide How to Recover Data from a USB Flash Drive walks through that process, and a format done first can destroy what a recovery scan needs. Begin the repair only once the files are safe or you have accepted that they are gone.

Next, rule out the simple causes. Plug the drive into a different USB port, then into a different computer. Try a rear desktop port rather than a hub. If the drive works elsewhere, the problem is the port, the hub, or the computer, not the drive. If it fails everywhere, the drive is the problem.

Now run chkdsk. Open Command Prompt as an administrator, type chkdsk X: /f (with X as the drive letter), and press Enter. The /f flag fixes file-system errors without erasing data. If chkdsk reports bad sectors or cannot finish, add /r, which scans the whole drive for bad sectors and recovers readable information — this takes longer, so let it run. If chkdsk finishes clean and the drive opens, copy a test file onto it, open it, and move to the verification step at the end.

If chkdsk cannot help, format the drive. Open Disk Management, right-click the drive, and choose Format. Pick exFAT for a drive you will use across Windows and Mac, or NTFS if it will stay on Windows and hold files larger than 4 GB. Untick Quick Format for a full format, which writes to every sector and catches problems a quick format misses. If the format completes, the drive is usable again, though still not trustworthy for important files.

If the format fails or the drive shows the wrong size, use diskpart. Open Command Prompt as an administrator, type diskpart, then list disk, and identify the drive by its size — getting this wrong can wipe the wrong disk, so check twice. Type select disk N (with N as the right number), then clean, which wipes the partition table. Then type create partition primary, format fs=exfat quick, and assign.

For a drive that resists every fix above, a low-level format tool from the drive maker can help. These tools write zeros across the whole drive, clearing stubborn corruption that a normal format misses. Use the tool the maker provides for your drive and follow its prompts. If even a low-level format fails, the controller or the memory is dead, and no software fix will bring it back.

Finally, verify the repair with H2testw. It writes test data to the full capacity of the drive and reads it back, catching fake capacity and bad memory that a format hides. A clean result means the drive is usable for scratch work and file transfers. Errors, or a capacity far below the label, mean the drive is done — retire it, and do not try to repair it twice.

Which One Fits Your Situation

The Drive Asks to Be Formatted

This is the most common case, and the mildest. Windows cannot read the file system, so it offers to format. Run chkdsk first, because it may repair the errors without erasing anything. If chkdsk cannot help and the files are safe, format the drive, choosing exFAT for cross-platform use. A full format is better than a quick one here, since it writes to every sector. After the format, verify with H2testw before trusting the drive with real work.

The Drive Shows the Wrong Size

A 128 GB drive that reports itself as 32 MB, or as unallocated space, has a damaged partition table or a fake capacity. Diskpart clean wipes the partition table so you can create a fresh partition at the full size. If the size is still wrong after a clean, run H2testw to check for fake capacity. A drive still far below its label after a clean is either counterfeit or dying, and neither case is worth more effort.

The Drive Disconnects or Freezes

A drive that vanishes during a copy, freezes File Explorer, or needs unplugging and replugging is almost certainly a hardware problem. Try another port and computer first, since a weak port can cause the same symptoms. If it keeps dropping on every machine, stop repairing — no file-system tool fixes a failing controller or worn memory. Copy off what you can while it still mounts, then retire the drive. Repeated disconnects are a warning, not a puzzle.

The Drive Works Again After Repair

A successful repair is good news with a limit. Use it for files that exist somewhere else too: moving photos between computers, carrying installers, or holding a copy of a backup. Do not use it as the only home for important files, or for a backup with no second copy. Check it again in a month. If it is still clean, it has earned its place as a spare. If errors return, retire it without a second repair.

Common Mistakes

  • Formatting the drive before the files are safe, which destroys the directory information a recovery scan needs.
  • Trusting a repaired drive with the only copy of important files, then losing them when the drive fails again.
  • Using a quick format to “fix” a drive with bad sectors, which hides the problem instead of finding it.
  • Ignoring a drive that reports the wrong capacity, which is often a fake or dying drive rather than a formatting glitch.
  • Repairing the same drive a second time after it fails again, instead of replacing a drive whose memory is worn out.

Frequently Asked Questions

Can a corrupted flash drive be fixed?

Often, yes, when the damage is logical. A scrambled file system, a damaged partition table, or a bad write can usually be repaired with chkdsk, a format, or diskpart. Physical damage is different: worn memory and a failing controller cannot be fixed by software. If the drive disconnects on its own, shows the wrong size after a clean, or fails the same way on two computers, replace it.

Does formatting delete everything on the drive?

Yes. Formatting rebuilds the file system, which removes the directory information pointing to your files. The data may still sit on the memory until overwritten, which is why recovery is sometimes possible after a format. If the files matter, recover first and format second. A quick format skips the sector check, while a full format writes to every sector and catches problems a quick format misses.

Why does Windows ask me to format my drive?

Windows asks to format when it cannot read the file system. The usual causes are an unsafe removal mid-write, a power cut, or a bad sector in the file-system area. The drive may be fine — the prompt only means Windows cannot make sense of what it sees. Run chkdsk first — it often repairs the errors without erasing anything. Format only when chkdsk cannot help and the files are safe.

How do I know the repair actually worked?

Run H2testw after the repair. It writes test data across the full drive and reads it back, catching fake capacity and bad memory that a format hides. A clean result means the drive is usable for scratch work. If H2testw reports errors, or the capacity is far below the label, it is not fixed. Retire it rather than repairing it again, and keep a second copy of anything it holds.

A
affadmin
We compare specs, materials and verified owner reviews before a product earns a spot. Rankings are never paid.
Affiliate disclosure. As an Amazon Associate we earn from qualifying purchases at no extra cost to you. Prices accurate as of the date shown.

More from Amazon

Programs that pair well with the guide above. Offers and eligibility are set by Amazon and may change.

Amazon Business

A free business account with business pricing and bulk-buying tools for work, shop or home office.

Create a business account
Amazon Prime

Free shipping on eligible items, Prime Video and more. Eligible new members can start with a free trial.

Start a Prime free trial
Audible

Audiobooks and podcasts to listen to on the go. Eligible new members can start with a free trial.

Try Audible free
Amazon Music Unlimited

Ad-free music streaming. Eligible new subscribers can start with a free trial.

Try Music Unlimited free

As an Amazon Associate we earn from qualifying purchases.