USB became write-protected after trying to install Windows on BOOTCAMP

Solution 1:

Partition or Erase the disk rather than the partition: in the Disk Utility sidebar, choose ‘Kingston DataTr…’ rather than ‘WinInstall’ and try your operation again.

Solution 2:

Open Terminal

  1. diskutil list to find the device /dev/diskXX (/dev/disk3, etc)
  2. diskutil eject /dev/disk3
  3. sudo dd if=/dev/urandom of=/dev/rdisk3 bs=10m

Be patient it may take a while. This should write random data to the Flash drive, effectively wiping it. You should then be able to remove it and re-insert and re-format it however you wish.

Some Flash drives have a write protect hardware switch, make sure that is not engaged.

Reboot try this again if it fails. It should not fail. Unless the disk is bad or it's one of those fake USB drives that claim to have more storage than it really does. Scammers selling fake USB drives, etc.