Don't want the data in USB drive or SD Card to be modified, you can write-protect them. Follow these steps to enable Disk Write Protection.
USB drives and SD cards are one of the most common ways to store and transfer data. One of the best things is that these drives come in a wide range of storage capacity all the while being small and portable. Not to mention they are faster and cheaper. When you store something in a USB drive or SD card, you can modify the data as and when needed. This is pretty helpful because you can write, modify, or delete data as needed.
However, if you don't want the data to be modified, you enable disk write protection. When enabled, the USB drive or SD card won't let you write new content, modify or remove the existing data. As you can guess, the write protection feature is very helpful when you want to protect the contents of a thumb drive or SD card from being modified.
So, without further ado, let me show how you can enable disk write protection on USB and SD Cards in Windows.
1] Physical Disk Write Protection
Often times, some thumb drives and SD cards contain a physical switch for disk write protection. When you toggle the switch, it restricts any operating system from writing or modifying the data on the drive. Of course, you can read or copy the data without any hindrance.
For regular USB or thumb drives, there will be a little toggle at the side. Take a look at the below image for reference. Move the toggle switch to lock or unlock the drive. When you lock the drive, it is write-protected. Depending on the USB drive, the toggle switch location can be different. Take look at the manual if you are unsure.
Just like with the Pen Drives, the SD cards can also have a physical write protection toggle. You will typically see the toggle on the side of the card. Take a look at the below image for reference. Move the toggle to lock or unlock the SD card. When you lock the card, it is write-protected.
Keep in mind that the small SD cards. i.e, the ones used in mobile phones will have no physical write protection locks.
When there is no physical write protection lock, you can use the software one. Follow the second method for that.
2] Via Diskpart Command
Note: Before proceeding, plug in the USB or SD Card.
Keep in mind that the below method is only applicable to your system. When you plug in the USB drive or SD card in another system, they can be written or modified like normal.
The Diskpart tool in Windows can make any removable drive write-protected. All you have to do is select the disk and give the command. Let me show you how.
1. First, search for "Command Prompt" in the start menu, right-click on the result and select "Run as Administrator" option.
2. The above action will open Command Prompt with admin rights. In the Command Prompt window, execute the below command to launch the Diskpart utility.
3. After opening the diskpart tool, execute the below command to list all disks in the system.
4. From the list of disks, find your thumb drive or SD card. You can easily recognize it by the disk size. Once found use the below command while replacing <diskNumber> with the actual disk number associated with the disk.
select disk <diskNumber>
Once you replace the disk number the command will look something like this:
select disk 2
5. After selecting the disk, use the below command to write protect USB or SD card.
attributes disk set readonly
6. Close the Command Prompt window.
That is it. You've successfully enabled disk write protection using Diskpart command. From now on, any writing operations or modifications will be blocked by Windows.
Disable Write Protection
When you want to revert back. i.e, disable write protection, use the below command.
attributes disk clear readonly
As you can see enabling disk write protection in Windows is nothing hard. As I said before, you should keep in mind that when using the Diskpart method, the write protection is only applicable to your system. When the USB drive or SD Card is plugged into another system, it can be written like normal.
If you are looking for enhanced protection then I recommend you try Bitlocker, a built-in Windows encryption tool. It will completely encrypt and password protects your drive.
Hope that helps. If you are stuck or need some help, comment below and I will try to help as much as possible. If you like this article, do check out how to format USB drive from Command Prompt and how to create partitions in USB drive.