This article explains how to enable or disable “Device discovery” in Developer Mode in Windows 11.
Device discovery in “Developer Mode” in Windows 11 allows your PC to be discovered by other devices and services on the same network. When you enable device discovery, SSH services are also enabled.
This feature lets you get the SSH PIN for pairing with the device by pressing the Pair button, which is exposed immediately after Device discovery is enabled.
This PIN prompt must be displayed on the screen to complete your first Visual Studio deployment targeting the device. When Device discovery is enabled, you make your device visible to other devices on the network through mDNS.
Device discovery in Windows can be helpful. However, enabling it can also pose a security risk, so it is recommended that you only allow it when needed and on trusted networks.
Below are the steps to turn “Device discovery” on or off in Windows 11.
Turn on or off “Device discovery” using the Settings app
As mentioned, users can turn “Device discovery” on or off using the Settings app. Here’s how to do it.
First, open the Windows Settings app.
You can do that by clicking on the Start menu and selecting Settings. Or press the keyboard shortcut (Windows key + I) to launch the Settings app.
When the Setting app opens, click the System button on the left.

Select the “For developers” tile on the System on the right to expand it.

On the System > For developers settings pane, ensure the “Developer Mode” feature is turned on.
Then, select the “Device discovery” tile and toggle the switch button to the On position to enable it.
To disable it, toggle the switch button to the Off position.

You can close and exit the Settings app when done.
Turn on or off “Device discovery” using the Windows Registry Editor
Another way to turn “Device discovery” on or off is to use the Windows Registry Editor.
Here’s how to do that.
First, open the Windows Registry and navigate to the folder key path below.
Computer\HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\debugregsvc\Parameters
Next, double-click the value (REG_DWORD) name on the DebugState key’s right pane to open it.
Then, enter a value 1
to turn on Device discovery in the Developer Mode in Windows 11.
Enter a value 0
to turn off Device discovery in the Developer Mode in Windows 11.
If you do not see the “DebugState” item, right-click a blank area and create a new DWORD (32-bit) registry item.
Then, enter the name “DebugState” and a desired value to enable or disable it.

Warning: Editing the Registry can be risky and, if not done correctly, may cause irreversible damage to your installation. It’s recommended that you back up your PC before proceeding.
Save your changes and restart your computer.
That should do it!
Conclusion:
- Enabling Device discovery in Developer Mode allows your PC to be discovered by other devices and services on the same network, enabling SSH services as well.
- In Windows 11, users can turn on or off Device discovery using either the Settings app or the Windows Registry Editor.
- It is recommended to only allow Device discovery when needed and on trusted networks due to potential security risks.
- When proceeding with changes in the Windows Registry, it’s crucial to back up your PC and proceed with caution to avoid irreversible damage to your installation.
Leave a Reply