Drives & data

USB drive is write protected

Write protection is usually a software flag or a physical switch rather than damage, and it can normally be cleared without losing data.

Difficulty
Easy
Time
10–20 minutes
DIY cost
$0–$0
Pro cost
$50–$100

Symptoms

  • 'The disk is write-protected' message when copying files
  • Physical lock switch present on the drive's side
  • Can read files but can't delete, rename, or add new ones
  • Message appears on every computer the drive is tried on

Likely causes

  • CommonPhysical write-protect switch is enabledSome SD cards and USB drives have a small lock switch that's easy to bump.
  • CommonRead-only attribute or disk flag set in softwareWindows can mark a whole drive read-only after certain errors.
  • PossibleDrive is nearly full and misreporting as protectedSome drives throw this error when they run out of usable space.
  • PossibleFailing flash memory defaulting to read-only for safetySome drives lock themselves read-only once they detect wear.

What to do

  1. Check the side of the drive or SD card adapter for a physical lock switch and slide it to unlocked.
  2. Open Command Prompt as administrator, run 'diskpart', select the disk, and run 'attributes disk clear readonly'.
  3. Check available free space in case the drive is reporting protection due to being full.
  4. Try the drive on a different computer to see if the lock follows the drive or is specific to one PC.
  5. If the drive was flagged read-only after errors, back up its data since this can signal early failure.
  6. If nothing clears the protection and the drive shows other errors too, treat it as failing and replace it.

Tools and parts

  • Access to Command Prompt or Terminal

When to call a pro

If clearing the flag fails and the drive is old, back up what you can and retire it rather than fighting a hardware fault.

Safety

Generally low risk

Generally low risk for a careful person. Stop if anything looks different from what this guide describes.

Related guides

Operator provides AI-generated troubleshooting information. It can be wrong. For safety-critical, electrical, gas, structural, medical, automotive safety, or other high-risk problems, consult a qualified professional.