The “media is write protected” message usually means Windows can read an external hard drive but will not let you change or delete files. These steps check the drive’s physical lock, Windows settings, and file system while avoiding actions that could erase data.
What You’ll Need
- A Windows PC with an administrator account.
- The external hard drive and its USB cable; try another port or cable if available.
- A backup drive or enough space elsewhere to copy important files before repair attempts.
Step-by-Step
- Protect important files first. If you can open the drive, copy irreplaceable files to another device before changing settings. Do not format the drive, initialize it, or run a command that says it will clean or erase the disk. If the drive clicks, disconnects repeatedly, or contains files that have become inaccessible, stop repeated repair attempts and consider professional data recovery.
- Check for a physical write-protect switch. Some external enclosures, portable drives, and SD-card adapters have a lock switch. Disconnect the device, move the switch to the unlocked position, reconnect it, and try creating a test folder. Many ordinary USB hard drives do not have a switch; do not force the enclosure open.
- Reconnect and test the connection. Safely eject the drive if possible, unplug it, then reconnect it directly to a different USB port. Avoid an unpowered hub during testing. A faulty cable, hub, or port can cause confusing errors. If practical, test the drive on another computer. If it is writable there, the restriction is likely specific to the original Windows setup.
- Check that the drive is not full and note its file system. In File Explorer, right-click the drive and choose Properties. Check the free space and the file system shown on the General tab. A full drive cannot accept new files, though that normally produces a different message. If the file system is NTFS, permissions may also be relevant; exFAT is commonly used for removable storage and does not use the same NTFS permission model.
- Clear the disk’s read-only attribute with DiskPart. Search for Command Prompt, choose Run as administrator, and enter
diskpart. At the DiskPart prompt, runlist disk. Identify the external drive by its capacity; do not guess, since selecting the wrong disk can affect another drive. Enterselect disk N, replacing N with the correct disk number, then runattributes disk. If it reports read-only, enterattributes disk clear readonly. Runattributes diskagain to check, then enterexittwice to close DiskPart and Command Prompt. This changes an attribute; it does not recover a failing drive or override every kind of protection. - Check for a read-only volume. If the disk attribute was already clear, open an administrator Command Prompt and run
diskpart, thenlist volume. Identify the volume by its drive letter and size, enterselect volume Nusing the matching number, and runattributes volume. If the volume is marked read-only, enterattributes volume clear readonly, then verify withattributes volume. Use care when selecting; do not select a volume based only on its number. - Review permissions if the drive is NTFS. In File Explorer, right-click the drive or the affected folder, choose Properties, and open Security. Check whether your Windows account has permission to write or modify. If access is denied, use the permissions controls only if you own or administer the files; changing permissions can affect other users. If the Security tab is unavailable or the drive is exFAT, this is not the likely fix.
- Check for file-system errors after backing up. Open File Explorer, right-click the drive, choose Properties, select Tools, and under Error checking choose Check. Follow Windows’ prompts. You can also run
chkdsk X: /fin an administrator Command Prompt, replacing X with the drive letter. Close programs using the drive first. Check Disk can modify file-system structures; do not run repair commands on a drive with valuable unbacked-up data if you suspect hardware failure. - Test writing again. Reopen the drive and create a small test folder or copy a nonessential file to it. If that works, safely eject the drive. If the message returns, note whether it happens with one folder, every folder, or on multiple computers; that helps distinguish permissions, Windows policy, and drive failure.
Common Mistakes
- Selecting the wrong disk in DiskPart: Confirm the capacity and disconnect other removable drives if identification is unclear. Never run
clean,format, or partition commands as a write-protection fix. - Formatting before copying files: Formatting can erase access to stored data and is not a first-line solution. Back up first and use it only when you deliberately want to erase and reuse the drive.
- Assuming every problem is read-only: A full disk, damaged file system, failing hardware, or folder permissions can prevent writing for different reasons.
- Changing permissions indiscriminately: Do not grant broad access or take ownership of files you do not own. This can cause unintended access or disrupt shared files.
Tips
- Use the drive’s Properties window to confirm the correct drive letter and file system before running commands.
- Keep at least one separate copy of important files. A second copy on the same external drive is not a backup.
- If the drive works on another computer, focus on the original PC’s policy, permissions, or security software rather than repeatedly repairing the disk.
- When finished, use File Explorer’s Eject option before unplugging to reduce the chance of file-system damage.
Troubleshooting
DiskPart says access is denied or the attribute will not clear: Confirm Command Prompt was opened as administrator, and check whether a physical lock is engaged. A work-managed PC may have removable-storage restrictions set by its administrator; contact them rather than trying to bypass policy.
The command succeeds, but writing is still blocked: Check the volume attribute, permissions on the specific folder, free space, and whether the drive is write-protected on another computer. Security software or organizational policy may also restrict removable storage.
Windows asks to format the drive, or it appears as RAW: Do not format if you need the files. Stop writing to the drive and seek recovery help or use a reputable recovery process that saves recovered files to a different disk.
The drive disconnects, makes unusual noises, or reports errors repeatedly: Stop using it, especially if the data matters. Repeated scans and repairs can worsen a failing drive. Replace it if it is unreliable after recovery or testing.
Frequently Asked Questions
Can I remove write protection without formatting?
Often, yes. Check the physical lock and clear a read-only disk or volume attribute first. Formatting is not required for those fixes.
Will clearing the read-only attribute delete my files?
No. The DiskPart attribute command is intended to change the read-only flag, not erase files. Still, back up important data before troubleshooting.
Why can I open files but not save or delete them?
Read access can remain available when a disk or volume is read-only, your account lacks write permission, or a system policy blocks changes.
What if the drive is write-protected on every computer?
Check its physical switch and attributes. If neither explains it, the drive may be failing or enforcing its own protection. Recover important files and contact the manufacturer or a data-recovery specialist.
Is it safe to run CHKDSK?
It can repair file-system errors, but it changes disk structures. Back up first; if the drive may be physically failing or files are not backed up, stop and seek recovery advice before running it.
Related
General steps for current mainstream versions; menus can differ by device and version. See the disclaimer or report an error.
More in this bed
- How to Schedule Work Profile Android Phones
- How to Use Microsoft Copilot on Mobile
- How to Enable ChatGPT Plugins and Use Them
- How to Print PowerPoint Slides With Notes
- Fix This App Was Blocked for Your Protection in Windows
- Windows Backup and Restore Stuck? What to Do