Stop Windows auto-joining a particular Wi-Fi network — via Microsoft Learn
Keep a network saved (password and all) but only connect to it when you choose — handy for a phone hotspot or a slow guest network that Windows keeps grabbing.
Takes effect right away
Command
Run in an administrator Command Prompt / Terminal window.
netsh wlan set profileparameter name="MyHotspot" ConnectionMode=manualUndo
netsh wlan set profileparameter name="MyHotspot" ConnectionMode=autoReplace MyHotspot with the profile name fromnetsh wlan show profiles. The relatedautoSwitch=yesparameter lets Windows move to a more preferred network when one appears.
Sources
- netsh wlan — set profileparameter — by Microsoft Learn
- Source reviewed
- 2026-11-02
- Link checked
- 2026-11-02
- Tested hands-on
- Not by Oddbyte.Me
Oddbyte.Me hasn't tried this on every Windows build, so keep the undo handy.