How to format a write protected sd card​?

Formatting an SD card is a common task for many users who need to reset the card, remove corrupted files, or prepare it for a different use. However, encountering a write-protected SD card can be frustrating, as it prevents any modifications, including formatting. Write protection can be enabled via physical switches or software settings, adding an extra layer of security but also an extra step in the formatting process.

Write protection on an SD card prevents any data from being written, modified, or deleted. This feature is beneficial for protecting important data from accidental deletion or corruption. Write protection can be enabled via:

Physical Switch: Many SD cards have a small switch on the side that can be moved to enable or disable write protection.

Software Settings: Some operating systems and devices can enable write protection via software settings, requiring different methods to disable it.

Identifying the Type of Write Protection

Before proceeding with formatting, it’s crucial to identify whether the write protection is physical or software-based.

Physical Write Protection

Inspect the SD Card: Look for a small switch on the side of the SD card. If the switch is in the “Lock” position, the card is write-protected.

Toggle the Switch: Move the switch to the “Unlock” position to disable write protection.

Software Write Protection

Check for Errors: Sometimes, the SD card may appear write-protected due to errors or corruption. Run a check disk utility to identify and fix errors.

Registry and Command Prompt: On Windows, write protection can be enforced through the registry or by using the Command Prompt.

Steps to Format a Write-Protected SD Card

Once you’ve determined the type of write protection and disabled it, you can proceed with formatting the SD card. Below are detailed steps for Windows, Mac, and Linux users.

Formatting on Windows

Disable Write Protection via Command Prompt:

Open Command Prompt as an administrator.

Type the command diskpart and press Enter.

In the Diskpart window, type list disk to display all connected drives.

Identify your SD card and note its disk number.

Type select disk X (replace X with your SD card’s disk number) and press Enter.

Type attributes disk clear readonly and press Enter. This command will disable write protection.

Type exit to close Diskpart.

Format the SD Card:

Open File Explorer and locate your SD card.

Right-click on the SD card and select “Format”.

Choose the file system (FAT32. exFAT, or NTFS) and ensure the “Quick Format” option is checked.

Click “Start” to begin the formatting process.

Formatting on Mac

Disable Write Protection:

Open Terminal.

Type diskutil list to display all connected drives.

Identify your SD card and note its identifier (e.g., disk2).

Type sudo diskutil unmountDisk /dev/diskX (replace X with your SD card’s identifier) and press Enter.

Type sudo diskutil repairDisk /dev/diskX to repair the disk, which may resolve the write protection issue.

Format the SD Card:

Open Disk Utility from the Applications > Utilities folder.

Select your SD card from the list of drives.

Click the “Erase” tab.

Choose the desired file system (Mac OS Extended, FAT32. exFAT).

Click “Erase” to format the SD card.

Formatting on Linux

Disable Write Protection:

Open a Terminal window.

Type lsblk to list all connected drives.

Identify your SD card and note its device name (e.g., /dev/sdb).

Type sudo hdparm -r0 /dev/sdb (replace /dev/sdb with your SD card’s device name) to disable read-only mode.

Format the SD Card:

Type sudo mkfs.vfat -n ‘LABEL’ /dev/sdX (replace LABEL with your desired volume label and /dev/sdX with your SD card’s device name) for FAT32 file system.

For exFAT, install the necessary utilities first: sudo apt-get install exfat-utils and then type sudo mkfs.exfat /dev/sdX.

Confirm the action and wait for the process to complete.

Troubleshooting Tips

Sometimes, despite following the steps, the SD card may still be resistant to formatting due to persistent write protection or errors. Here are some troubleshooting tips:

Check the SD Card Adapter: If you’re using an SD card adapter, ensure the adapter’s switch is not set to “Lock”.

Use Another Device: Try inserting the SD card into another device or card reader to rule out device-specific issues.

Software Tools: Utilize specialized SD card formatting tools like SD Formatter by the SD Association, which can sometimes bypass stubborn write protection.

Firmware Update: Check if your device or card reader has a firmware update that might resolve compatibility issues.

Replace the SD Card: If all else fails, the SD card may be physically damaged, and replacing it might be the only solution.

About us and this blog

Panda Assistant is built on the latest data recovery algorithms, ensuring that no file is too damaged, too lost, or too corrupted to be recovered.

Request a free quote

We believe that data recovery shouldn’t be a daunting task. That’s why we’ve designed Panda Assistant to be as easy to use as it is powerful. With a few clicks, you can initiate a scan, preview recoverable files, and restore your data all within a matter of minutes.

Subscribe to our newsletter!

More from our blog

See all posts