If you see “The disk is write protected” when running chkdsk, the drive’s write-protect switch or attribute is blocking the check. This guide explains why it happens and gives the exact steps to remove write protection and run chkdsk successfully.
What Write Protection Means for Chkdsk
Chkdsk (Check Disk) scans a drive for file system errors and bad sectors. To fix problems, it must write changes to the disk. When a drive is write-protected, Windows refuses any write operation, so chkdsk cannot repair anything. The write protection can come from physical hardware, a registry setting, or a read-only attribute on the volume.
Why Is My Drive Write Protected?
Common causes include:
- Physical switch: Many SD cards and USB flash drives have a small slider on the side. If it’s in the “Lock” position, the drive is read-only.
- Registry setting: Windows has a “WriteProtect” value in the registry that can force all removable drives to be read-only.
- Disk attribute: The disk itself may have the read-only attribute set, often due to a previous error or third-party software.
- File system corruption: A corrupted file system can sometimes cause the drive to mount as read-only.
How to Remove Write Protection and Run Chkdsk
Follow these steps in order. Stop when the write protection is gone.
- Check the physical switch. Remove the SD card or USB drive and look for a small slider. Move it to the unlocked position (usually away from the “Lock” label). Reinsert the drive and try chkdsk again.
- Clear the read-only attribute with DiskPart. Open Command Prompt as administrator (search “cmd”, right-click, “Run as administrator”). Type
diskpartand press Enter. Then typelist diskto see all drives. Identify your drive by size (be very careful—selecting the wrong disk can damage your data). Typeselect disk X(replace X with the number of your drive). Then typeattributes disk clear readonlyand press Enter. Exit DiskPart withexit. - Edit the registry (if DiskPart didn’t work). Press Win+R, type
regedit, and press Enter. Navigate toHKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\StorageDevicePolicies. If the key doesn’t exist, right-click on Control, choose New > Key, and name itStorageDevicePolicies. Inside it, create a DWORD (32-bit) value namedWriteProtectand set its value to0. Restart your computer. - Run chkdsk again. Open Command Prompt as administrator and type
chkdsk X: /f(replace X with your drive letter). If the drive is your system drive (C:), Windows will ask to schedule the check at next reboot—type Y and restart. - If chkdsk still says write protected, the drive may be failing or have a hardware lock. Try a different USB port or card reader. If it’s an SD card, try a different adapter.
What If the Drive Is Still Write Protected?
If none of the above works, the drive might be physically damaged or have a firmware-level write protection. Some high-endurance SD cards have a permanent write-protect flag after excessive wear. In that case, backup any data you can (if the drive is readable) and consider replacing it. For internal hard drives, check if the drive is set to read-only in the BIOS/UEFI—some enterprise drives have a write-protect jumper on the back.
Chkdsk on a Write-Protected System Drive (C:)
If your system drive is write-protected, you cannot run chkdsk from within Windows. You need to boot from a recovery environment:
- Restart your PC and press the key to enter boot options (often F12, Esc, or Del).
- Select “Repair your computer” or “Troubleshoot” > “Advanced options” > “Command Prompt”.
- In the command prompt, run
chkdsk C: /f.
If the drive is truly write-protected at the hardware level, even this won’t work. In that case, the drive may be failing—back up data immediately if possible.
Frequently Asked Questions
Why does chkdsk say “The disk is write protected” even though I have no lock switch?
Many USB drives don’t have a physical switch, but the registry or disk attribute can still be set. Follow the DiskPart and registry steps above to clear it.
Can I run chkdsk on a write-protected drive in read-only mode?
Yes, you can run chkdsk X: without the /f flag—it will only scan and report errors, not fix them. But that won’t repair anything. You need write access to fix errors.
Will removing write protection void my warranty or harm my drive?
No, clearing the read-only attribute is a standard maintenance step. However, if the drive is failing, forcing writes could cause further damage. Always back up important data first.
Is there a way to bypass write protection on a microSD card?
If the physical switch is broken, you can try the DiskPart method. Some cards have a tiny notch that can be taped over, but that’s a temporary fix and not recommended. If the card is permanently locked, it’s likely at end-of-life.
Why does chkdsk run automatically at boot and then say “write protected”?
This can happen if the dirty bit is set but the volume is mounted read-only, often due to a hibernation file or a pending reboot. Try disabling hibernation (powercfg /h off) and restarting, then run chkdsk manually.
Can I use third-party software to remove write protection?
Some drive manufacturers provide formatting tools that can clear write protection, but they are brand-specific. The built-in Windows methods are usually sufficient and safer.
Related
Method: the standard formula for this calculation, rounded as each result states. See how the calculators work or report an error.
More cards in this drawer
- Poco C51 Airtel Prepaid Locked Variant India?
- Jenkins vs GitHub Actions: Which CI/CD Fits Your Team?
- Turn Off Backup Encryption in iTunes?
- Campus Tech Innovation Hubs: What They Are
- Shared VPS Hosting: Is It Better?
- Disk Defrag Pro: What It Does and Whether You Need It