4 Ways to Disable USB Ports on Your Device
1. Disable USB ports through the Registry
The method is very easy and is done by modifying your registry and changing the value related to the operation of the USB ports. All you have to do is click on the Start menu, then click on Run (you can use the Windows + R shortcut), then type regedit and press Enter. Then click on HKEY_LOCAL_MACHINE, then SYSTEM, then CurrentControlSet, then Services, then USBSTOR. Then you click on Start twice and change the value to 4.
To restart the USB ports, repeat the same steps but change the value to 3. (4 to disable the ports, and 3 to enable them), and it is important to note here that this method disables the operation of flash drives or storage spaces, not the keyboard and mouse connected to the device via USB. But it disables the operation of storage devices like flash drives.
2. Disable USB ports through Device Manager
You can easily disable and enable the USB ports on your device through Device Manager, by right-clicking on My Computer, selecting Properties, then clicking on Device Manager, then searching for the USB ports as shown in the image below and right-clicking on them and selecting Disabled to disable them, then anytime you want to enable them again, right-click and select Enable.
3. Prevent file transfer to flash drives
You can prevent file transfer and writing to flash drives by modifying the registry. All you have to do is download this file. Then unzip it and you will find two files. DisableUSBWrite file to stop writing to flash drives. And EnableUSBWrite file to enable writing to flash drives. Note that you must restart the device to activate the command.
4. Network Administrator tool to control disabling and enabling USB on network devices.
The Intelliadmin USB Drive Disabler tool is a unique tool that allows you to stop and start USB ports on your device. Not only that, but it also allows you to disable and enable USB ports on other devices on the network. This tool is part of the Network Administrator program, which allows you to control making some changes to the devices on your internet network, including disabling and enabling USB ports. You can download the program, or download the USB Drive Disabler tool from this page.
All you have to do is click on Select Action, then select USB Drive Disabler, then choose the network devices you want to disable USB ports on or even select your device. Then Click to Start. But for Windows 7 users, if remote control of network devices doesn’t work for you, you should refer to this article from the official website.