How to disable the Windows key

Windows Key

ask pc gamer

Ask PC Gamer is our weekly question and advice column. Have a burning question about the smoke coming out of your PC? Send your problems to

Look, See? I am a PC Gamer. I am impressed—really!—by the knowledge the Windows key does all that. However, due to my empirical knowledge of how aggravating the Windows key is to my PC Gaming I will continue to remove the Windows key from my keyboards. —Klimek Shannon

OK, so that wasn't a question, but it brings one up. That was a response to my post from last week, in which I offered a few of my favorite Windows shortcuts and tricks. While the Windows key can be useful for the highly efficient PC gamer, Klimek points out that it can also be the cruelest key of them all. Accidentally dumping yourself to the desktop in the middle of a competitive game is worse than accidentally hitting Insert and typing over a sentence. Thankfully, there are ways to disable it.

As commenters pointed out, some keyboards (like the one pictured) include a button to disable the key. On my Thermaltake keyboard, the left Windows key is replaced with an Fn key, so I don't worry about it. If you're out of luck with your keyboard, though, you can still disable the key in Windows 7 with a bit of registry editing. Here, directly from Microsoft support, is how to do it:

  1. Click Start, click Run, type regedt32, and then click OK.
  2. On the Windows menu, click HKEY_LOCAL_ MACHINE on Local Machine.
  3. Double-click the System\CurrentControlSet\Control folder, and then click the Keyboard Layout folder.
  4. On the Edit menu, click Add Value, type in Scancode Map, click REG_BINARY as the Data Type, and then click OK.
  5. Type 00000000000000000300000000005BE000005CE000000000 in the Data field, and then click OK.
  6. Close Registry Editor and restart the computer.

If you don't want to mess with your registry yourself, which can be dangerous, Microsoft will do it for you with a little download on the support page. Or you can try a different method, with a program that's handy to have anyway, and keep the shortcuts. [The following has been revised thanks to solliddd's great comment.]

AutoHotkey is what you want. Download the program (it's free and open source) and run it, then right click on its icon in the taskbar. Select 'Edit This Script' and it'll open the default script in Notepad. Somewhere between the comments (which are marked with semi-colons) add the following:

~LWin Up:: return
~RWin Up:: return

Now just save the file, right click on AutoHotkey again, and select 'Reload This Script.' Both Windows keys should now do nothing when pressed on their own, but shortcuts will still work. Now you'll never end up looking at the desktop when you meant to crouch. Whew.

Note: Some online games may detect AutoHotkey as a potential cheating application, though I always have it running and have never had a problem. Obviously, if you're creating scripts to automate in-game actions, the game's moderators may not approve. Use it at your own risk!