Clear, practical technology insights BSOD Code Lookup · Windows Error Code Lookup · Wi-Fi Troubleshooting · PC Troubleshooting Checklist

How to Format a Write–Protected Pen Drive: Step-by-Step

Learn how to Format a Write–Protected Pen with clear steps, useful examples, and practical tips. Complete the task correctly and avoid common mistakes.

Table of Contents

This updated guide explains how to Format a Write–Protected Pen Drive: Step-by-Step through clear steps, practical examples, and important checks that help prevent common errors.

Method 1 of 3:

Using Diskpart (Windows)

  1. Format a Write–Protected Pen Drive: Step-by-Step — Using Diskpart (Windows) screenshot 1
    Toggle the switch on the USB drive. If your USB drive has a physical write-protection switch on its exterior, it might be in the wrong (locked) position. Try toggling the switch before you continue with this method.
    • In some instances, a pen drive can be locked using security software that prevents permission changes on a flash drive. If this is the case, you may not be able to remove write-protection from the USB drive.[1]
  2. Format a Write–Protected Pen Drive: Step-by-Step — Using Diskpart (Windows) screenshot 2
    Insert the pen drive into an open USB slot. You can use any available USB slot on your PC.
  3. Format a Write–Protected Pen Drive: Step-by-Step — Using Diskpart (Windows) screenshot 3
    Right-click the Start
    Format a Write–Protected Pen Drive: Step-by-Step — Using Diskpart (Windows) screenshot 4
    menu. It's usually at the bottom-left corner of the screen. This displays a menu.
  4. Format a Write–Protected Pen Drive: Step-by-Step — Using Diskpart (Windows) screenshot 5
    Click Run. It's at the bottom of the menu that appears when you right-click the Windows Start menu. This opens Run in a new window.
  5. Format a Write–Protected Pen Drive: Step-by-Step — Using Diskpart (Windows) screenshot 6
    Type diskpart into Run and press ? Enter. This opens Diskpart in the Command Prompt.
  6. Format a Write–Protected Pen Drive: Step-by-Step — Using Diskpart (Windows) screenshot 7
    Type list disk and press ? Enter. A list of all drives, including your pen drive, will appear. Each drive is labeled "Disk (number)", and each number is unique to that drive.
    • You should be able to identify your USB drive by how much space it has listed under "Size". For example, if your USB drive is a 32 GB drive, it should say "32 GB" or close to that below "Size" in the Command Prompt.
  7. Format a Write–Protected Pen Drive: Step-by-Step — Using Diskpart (Windows) screenshot 8
    Type select disk # and press ? Enter. Replace # with the number of your pen drive (i. e. "select disk 3"). This selects the USB drive in Diskpart.
  8. Format a Write–Protected Pen Drive: Step-by-Step — Using Diskpart (Windows) screenshot 9
    Type attributes disk clear readonly and press ? Enter. This should remove write-protected status from the drive.
  9. Format a Write–Protected Pen Drive: Step-by-Step — Using Diskpart (Windows) screenshot 10
    Type clean and press ? Enter. This should remove the data from the drive. Once it's removed, you'll be able to set it up for use.
  10. Format a Write–Protected Pen Drive: Step-by-Step — Using Diskpart (Windows) screenshot 11
    Type create partition primary and press ? Enter. This creates a partition on the USB drive.
  11. Format a Write–Protected Pen Drive: Step-by-Step — Using Diskpart (Windows) screenshot 12
    Type format fs=fat32 or format fs=ntfsand press ? Enter. This formats the drive in a format that is readable on any operating system. If the USB drive storage is smaller than 32GB, type "format fs=fat32". If the drive is greater than 32GB, type "format fs=ntfs".[2]
  12. Format a Write–Protected Pen Drive: Step-by-Step — Using Diskpart (Windows) screenshot 13
    Type exit and press ? Enter. This returns you to the standard command prompt. The drive should now be available for data storage and other uses.
Method 2 of 3:

Using the Registry Editor (Windows)

  1. Format a Write–Protected Pen Drive: Step-by-Step — Using the Registry Editor (Windows) screenshot 14
    Toggle the switch on the USB drive. If your USB drive has a physical write-protection switch on its exterior, it might be in the wrong (locked) position. Try toggling the switch before you continue with this method.
  2. Format a Write–Protected Pen Drive: Step-by-Step — Using the Registry Editor (Windows) screenshot 15
    Open the Windows Registry Editor on your PC. Here's how:
    • Press ? Win+S to open the search bar.
    • Type regedit into the search field.
    • Click Registry Editor in the search results.
    • Click Yes to run the app.
  3. Format a Write–Protected Pen Drive: Step-by-Step — Using the Registry Editor (Windows) screenshot 16
    Go to the Control folder. Use the following steps to navigate to the Control folder in the system registry. You should see several more folders inside the Control folder.
    • Click the HKEY_LOCAL_MACHINE folder.
    • Click the SYSTEM folder.
    • Click the CurrentControlSet folder.
    • Click the Control folder.
  4. Format a Write–Protected Pen Drive: Step-by-Step — Using the Registry Editor (Windows) screenshot 17
    Click the StorageDevicePolicies folder (if it exists). If you see this folder in the left panel (under the "Control" folder), double-click it to display its contents in the right panel. If you don't see this folder, perform the following steps to create it:[3]
    • Right-click a blank area of the right panel to open the context menu.
    • Select New and then Key on the menu.
    • Type StorageDevicePolicies and then click the blank area to save the new key.
    • Click StorageDevicePolicies in the left panel to open it.
    • Right-click a blank area in the right panel and select New > DWORD .
    • Type WriteProtect and then click anywhere to save the DWORD.
  5. Format a Write–Protected Pen Drive: Step-by-Step — Using the Registry Editor (Windows) screenshot 18
    Double-click WriteProtect in the right column. A dialog window will appear.
  6. Format a Write–Protected Pen Drive: Step-by-Step — Using the Registry Editor (Windows) screenshot 19
    Enter "0" as the "Value Data" amount and click OK. Enter the numerical zero without the quotes.
  7. Format a Write–Protected Pen Drive: Step-by-Step — Using the Registry Editor (Windows) screenshot 20
    Close Registry Editor and restart your PC. Changes you make in the Registry Editor usually require a restart to take effect.
  8. Format a Write–Protected Pen Drive: Step-by-Step — Using the Registry Editor (Windows) screenshot 21
    Connect the pen drive to the PC and open File Explorer. You can open the File Explorer by pressing ? Win+E or by right-clicking the Start menu and selecting File Explorer .
  9. Format a Write–Protected Pen Drive: Step-by-Step — Using the Registry Editor (Windows) screenshot 22
    Right-click the pen drive and select Format. Your options for erasing and reformatting the drive will appear.
  10. Format a Write–Protected Pen Drive: Step-by-Step — Using the Registry Editor (Windows) screenshot 23
    Select your formatting preferences and click Start. This should delete the contents of the pen drive and prepare it for use.[4]
    • If this method did not work for you, try the "Using Diskpart (Windows)" method.
Method 3 of 3:

Using Disk Utility (Mac OS X)

  1. Format a Write–Protected Pen Drive: Step-by-Step — Using Disk Utility (Mac OS X) screenshot 24
    Toggle the switch on the USB drive. If your USB drive has a physical write-protection switch on its exterior, it might be in the wrong (locked) position. Try toggling the switch before you continue with this method.
  2. Format a Write–Protected Pen Drive: Step-by-Step — Using Disk Utility (Mac OS X) screenshot 25
    Insert the write-protected pen drive into a USB slot on your Mac.
  3. Format a Write–Protected Pen Drive: Step-by-Step — Using Disk Utility (Mac OS X) screenshot 26
    Open Finder
    Format a Write–Protected Pen Drive: Step-by-Step — Using Disk Utility (Mac OS X) screenshot 27
    . It's the first icon on the Dock, which is usually at the bottom of the screen.
  4. Format a Write–Protected Pen Drive: Step-by-Step — Using Disk Utility (Mac OS X) screenshot 28
    Click the Applications folder. It should be in the left panel. Some icons will appear in the right panel.
  5. Format a Write–Protected Pen Drive: Step-by-Step — Using Disk Utility (Mac OS X) screenshot 29
    Double-click the Utilities folder. It's in the right panel.
  6. Format a Write–Protected Pen Drive: Step-by-Step — Using Disk Utility (Mac OS X) screenshot 30
    Double-click Disk Utility. It's the hard drive icon with a stethoscope in the right panel. This opens a tool you can use to format drives.
  7. Format a Write–Protected Pen Drive: Step-by-Step — Using Disk Utility (Mac OS X) screenshot 31
    Select your pen drive in the left panel. Some info about the drive will appear in the right panel.
  8. Format a Write–Protected Pen Drive: Step-by-Step — Using Disk Utility (Mac OS X) screenshot 32
    Click the Erase tab in the right panel. It's near the top of the panel.[5]
  9. Format a Write–Protected Pen Drive: Step-by-Step — Using Disk Utility (Mac OS X) screenshot 33
    Enter a name for the drive (optional). You can keep the default name if you wish.
  10. Format a Write–Protected Pen Drive: Step-by-Step — Using Disk Utility (Mac OS X) screenshot 34
    Select a file system type from the "Format" menu. If you want your pen drive to be compatible with both PCs and Mac, select MS-DOS (FAT) (pen drives under 32GB) or ExFAT (drives over 32GB). Otherwise, choose your desired Mac filesystem type.
  11. Format a Write–Protected Pen Drive: Step-by-Step — Using Disk Utility (Mac OS X) screenshot 35
    Click the Erase button. It's at the bottom-right corner of the active window. Your Mac will reformat the write-protected pen drive and change the sharing and permissions status to 'read and write.[6]"
    • If this process does not make your drive usable, the issue is likely mechanical and you should replace the pen drive.

FAQ

What is the easiest way to Format a Write–Protected Pen Drive: Step-by-Step?

Start with the requirements in this guide, then follow each step in order. Check the result after every major change so problems are easier to identify.

Can beginners follow these instructions?

Yes. The process is organized into practical steps, and you can repeat any step before moving forward.

What should I check if the method does not work?

Confirm your software or device version, permissions, settings, file format, and internet connection when the task depends on online services.

Discussion

Reader Comments 0

Sign in with email or Google to join the discussion.