How to Remove Write Protection From USB Drive (Tested Fixes)

If you are stuck trying to figure out how to remove write protection from usb drives, you know how annoying this error gets. You plug your USB stick into your computer to drop a quick file or copy some photos, and Windows immediately throws up an error box telling you the disk is write-protected.

You try to delete an old folder to clear space, but Windows blocks you. And You try to format the drive, and it won’t let you click past the warning.

It feels like your own flash drive locked you out for no reason.

A lot of people think the drive is completely dead and throw it straight into the garbage. Don’t throw it away just yet.

Most of the time, this happens because Windows glitched during an improper unplug, or a registry key got flipped by a security tool.

Here is what I do on my own desk whenever a flash drive starts acting stubborn.

Check for a Physical Switch on the Drive

Before you open any settings or type commands, pick up the USB drive and look at both sides.

Some older flash drives, micro-SD adapters, and card readers have a tiny mechanical lock switch on the plastic casing. If that switch slides down toward the lock icon, the hardware physically turns off write access to protect data.

  • Look closely at the side edges of the drive or the SD card adapter.

  • If you see a tiny slider pushed down, flick it back up toward the metal contacts.

  • Plug it back in and try making a new folder.

If your USB is just a plain piece of metal or plastic with no buttons, then the lock is purely software. We can fix that with built-in Windows tools.

Clear the Read-Only Lock Using Diskpart

Windows has a built-in command tool called Diskpart that can clear stuck permissions in about thirty seconds. This trick does not delete your files; it just turns off the read-only flag.

  1. Press Windows Key + R, type cmd, and press Ctrl + Shift + Enter to open Command Prompt as administrator.

  2. Type diskpart and hit Enter.

  3. Type list disk and hit Enter.

You will see every drive hooked up to your PC (Disk 0, Disk 1, and so on). Look at the size column to spot your USB. If you have a 16GB stick, it will usually show around 14GB.

DISKPART> list disk

  Disk ###  Status         Size
  --------  -------------  -------
  Disk 0    Online          476 GB
  Disk 1    Online           14 GB  <-- (This is your USB drive)

Make sure you pick the right disk number so you do not touch your main Windows drive:

  1. Type select disk X (put your actual USB disk number instead of X) and hit Enter.

  2. Type this command and hit Enter: attributes disk clear readonly

If Windows clears the flag, you will see a message saying attributes were cleared successfully. Type exit, close the window, and try saving a file onto the drive.

Sometimes, when scanning drives through Diskpart, a lagging PC or slow USB port can cause micro-freezes. If your mouse pointer hitches or skips while working with USB devices, take a look at our hands-on guide on how to fix mouse stuttering in games to track down USB polling and driver lag.

Fix the Windows Storage Registry Key

If Diskpart didn’t do the trick, Windows itself might be forcing all USB drives into read-only mode.

This happens when a third-party antivirus tool, old malware, or a weird Windows update adds an extra security rule to the registry. We can turn that rule off manually:

  1. Press Windows Key + R, type regedit, and hit Enter.

  2. Go down this path on the left side: HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control

  3. Look for a folder called StorageDevicePolicies.

    • If that folder is not there, right-click the Control folder, pick New > Key, and name it StorageDevicePolicies.

  4. Click that folder. On the right side, look for a file named WriteProtect.

    • If it is not there, right-click in the empty space, choose New > DWORD (32-bit) Value, and name it WriteProtect.

  5. Double-click WriteProtect and make sure the value is set to 0.

  6. Hit OK, close the registry, and give your PC a quick restart.

Setting that number to 0 tells Windows to allow normal write access across your USB ports again.

Official flash storage specifications and safe controller standards are outlined by the SD Association, which sets the baseline for how memory controllers protect data when unexpected power losses happen.

When the Flash Drive Is Actually Dying

What if you ran Diskpart, checked the registry, tried the USB stick on another computer or your laptop, and it still says it is write-protected?

In that case, the hardware inside the USB stick has probably reached the end of its life.

Flash memory chips inside thumb drives can only write data a limited number of times. When the memory controller sees that too many cells are wearing out, it locks the drive into permanent read-only mode to keep your existing data safe.

The drive is basically saying: “You can still read your files and back them up, but you cannot write anything new because I am about to die.”

If this happened to you:

  • Copy your files off the USB onto your desktop immediately.

  • Do not waste your time with sketchy third-party formatting tools from random websites; they will just ruin whatever life is left in the chip.

  • Get a new flash drive for your daily work.

If you are dealing with other storage devices acting up, like a hard drive or M.2 drive that vanishes from your system entirely, check our step-by-step breakdown on how to fix ssd not showing up to sort out partition and BIOS detection problems.

Simple Summary

Before you throw a locked USB drive into the waste bin:

  • Make sure there is no physical lock slider on the drive casing.

  • Open cmd as admin and run attributes disk clear readonly inside Diskpart.

  • Check the registry and change WriteProtect to 0.

  • If it stays locked everywhere, pull your important files off right away—the drive has entered permanent hardware protection mode.

Leave a Comment