SEARCH

How-To Geek

Map Any Key to Any Key on Windows 7 / XP / Vista

If you are tired of the way certain keys on your system work, such as the Caps Lock key, you can re-map them to function as a different key by using a registry hack. But there should be an easier way, right?

This is where SharpKeys comes into the picture: It’s a small utility that will let you easily map one key to another key easily, or even turn the key off, without having to enter the registry at all.

For instance, I used the key mapping to just turn off my Caps Lock key, since I never use it.

image

You can click the Add button to bring up the Add New Key Mapping dialog, where you can either select the keys to map from the lists, or just click the Type Key button and press the key manually (which I find much more intuitive)

image

Once you are done, click the Write to Registry button and you’ll be told to log off or reboot for the changes to take effect.

image

If you want all the technical details on how the registry keys work, you can read about how to map keys using registry hacks.

Download SharpKeys from Randyrants

Lowell Heddings, better known online as the How-To Geek, spends all his free time bringing you fresh geekery on a daily basis. You can follow him on if you'd like.

  • Published 09/30/07

Comments (68)

  1. Ali Karbassi

    I’ve been wondering how you could do this on a macbook. I just hooked up my new mac keyboard and my “home” and “end” keys don’t do what they are suppose to do.

    Any help?

  2. mark schneider

    Great tip I HATE caps lock

  3. Tom

    @Ali – Try DoubleCommand – doublecommand.sourceforge.net
    or uControl – http://www.gnufoo.org/ucontrol/

    It should be noted that you can do this on WinXP using AutoHotKey, but it sounds like this would be handy for those who do not want an app running in the background.

  4. nate

    hopefully this’ll work with bootcamp so i dont keep hitting the ‘windows’/apple key for ctrl

  5. Bill Boulden

    I map caps lock to Escape. It is fantastic for using Vi and Vim- the escape key is the key you’ll hit more frequently than any other yet it’s the most out of the way- mapping caps lock to it puts it in a very accessible spot on the mirror image side of Enter.

  6. Someone curious

    Well it can work fine for me, I think Ctrl+Backspace is worth Backspace

  7. Mark

    Sharp Keys is SWEET!

    And HowToGeek.com rocks. My two items on today’s to-do list were to:

    1 – Once and for all disable the Caps Lock, Insert and Windows keys, and,
    2 – Find out where the “Up One Level” icon is hiding in Vista’s Explorer.

    Twice now Google has lead me to HowToGeek.com. Twice now I’ve received good advice. Thanks for the website, I’m going to be seeing what else you have around here.

  8. The Geek

    @Mark

    Glad we could help!

  9. Mark

    FYI – I decided to turn my Pause/Break key into a Caps Lock key. SharpKeys doesn’t have a listing for Pause/Break, so I used the “Type Key” option and SharpKeys told me that the Pause/Break key was the Num Lock key. Like a fool, I believed it and proceeded along.

    Long story short, my brand new computer wouldn’t boot into Windows and I had to use the power button. Then some kind of warning came up, asking me if I wanted to do a system restore. I told it “no” and eventually my computer came back to life. Pretty scary, I have just spent the last 48 hours loading applications and transferring data from my old computer to my new one and I was afraid I was going to have to use the system restore CD that came with the computer.

  10. Mike Heath

    Hi Randy,

    I downloaded SharpKeys with the main purpose of remapping AltGr to Alt. However, when I click Type Key and then press the AltGr key, I get a dialogue saying ‘You’ve entered a key that SharpKeys doesn’t know about. Please check the SharpKeys website for an updated release’. But I have the latest release (2.1.1) so what am I doing wrong?

    Mike

  11. Chun-Yu Lin

    Too bad it can’t recognize the function key (Fn) on my Lenovo x61 tablet pc. I was hoping to switch Fn & Ctrl. I still like Ctrl to be at the corner, not the Fn key…

  12. vin

    on my laptop w and W was not working, so I mapped one of the lesser used keys to be w while I wait for my new keyboard to arriave. Now I just have to get use to typing the other key mapped instead for w :)

    thanks

  13. Dave

    I downloaded SharpKeys hoping to swap the Alt and Windows keys on the left side of my keyboard. I put an Apple keyboard on an XP machine, and while the keyboard works fine with the system, the Alt key is in a different physical location on a standard Apple keyboard. So instead putting my left thumb on the key just to the side of the spacebar and hitting the Tab key to switch apps, it needs to go to one key over — old habits are hard to break.

    Unfortunately, SharpKeys can’t remap the Windows key; or at least I was unable to figure out how to get it to do it.

  14. ecards

    Great app – I’m using this to make it easier to program my Harmony remote since I can’t get it to emulate the Windows key!

  15. Mark

    Is there a way to do this on an as-needed basis? Can I turn it on/off at will?

    I have to enter the answers to multiple choice questions frequently. The choices are always A/B/C/D or E/F/G/H (or sometimes A/B/C/D/E). It difficult to stare at the user’s test answer sheet, and using the QWERTY keyboard to peck out their response.

    It would be easier to map A=1; B = 2; C = 3; D = 4, and then Q= E; W= F; E = G and R = H so the answer keys are always my left hand, pinky through pointer finger.

    Can this app be used to turn this feature on /off at will?

    Thanks!

  16. Bjorn

    “Too bad it can’t recognize the function key (Fn) on my Lenovo x61 tablet pc. I was hoping to switch Fn & Ctrl. I still like Ctrl to be at the corner, not the Fn key… ”

    I’ve got the exact same problem. Im looking to buy a new laptop, but I cant stand having the Function (Fn) key on the bottom left where the Ctrl key is supposed to be.

    Is it at all possible to make this switch?

  17. devalias

    I’m having the same problem. I want to swap ctrl and fn. any ideas?

  18. Jeff Root

    On thinkpads, the fn key is managed by the embedded controller chip. The OS loads an ACPI config table at boot time that sets up event handlers for these keys.

    So fn does not produce a scancode at all, and thus a simple keyboard remapping is not possible.

    However, if you really want this to work, you’d have to build an ACPI event handler that emits the scancode for Ctl whenever fn is pushed (I’ve done similar things under Linux, not sure how to do this for Windows). Getting the Ctl key to act as the fn key seems much harder; I _think_ you’d have to intercept the scancode and (somehow) detect which fn modifier key (e.g., sleep key) is also pressed, then run the corresponding ACPI handler directly.

    Not really easy at all. I wouldn’t say impossible, but darn near.

  19. Almino

    Okay my F-keys are always set to doing only functions like Volume, Lighting etc.. Ex. i have to press Fn + F1 to open the help menu, cause it i only press F1 it turns my Wireless off. I want to be able to press just F1 and get the Help menu but be able to press Fn + F1 to turn wireless off?

    Is that possible with this?

  20. Joao

    doesnt disable ALT TAB

    0 to 10, I vote 1

  21. Ryan

    My computer is a laptop so I don’t have a keypad for numbers. When I turn the keylock on it makes the Fn numbers on the keyboard work instead of the letters. That’s useless and frankly annoying. I want to bind a .wav file to the key so whenever I press “Num Lk” it plays the sound effect. I’m confident that this program will successfully remap it. However, I use iTunes as my default music player, including for .wav files, and I want to keep it that way. Is there a way I can bind this sound effect to the key and have it play like a normal windows sound effect (like the beep when you click on a window that can’t be accessed because you have its options window open), which is to say: not through iTunes? It would be tremendously amusing if I got this set up.

  22. Megan

    Hi—

    I recently bought a Lenovo tablet, and I downloaded SharpKeys to switch the page forward and page back keys located near the arrow-keypad (on the bottom-right corner of the keyboard) to home and end, respectively, but instead I got an error saying, “You have entered a key that SharpKeys doesn’t know about. Please check the SharpKeys website for an updated release,” but I downloaded the program three days ago, and it was the most up-to-date version. It said that both keys were 00_100. Any ideas for what to do?
    Thanks!

  23. emman

    this diesn’t work on windows 7 even if you are using compatibility or running it as an admin..

  24. greg

    works on windows 7 for me and an apple keyboard.

  25. Milander

    …and the number one rule gets blown out of the water again (and for no good reason).

    Rule 1: Don’t f**k with the registry.

    (The cavet is, of course, – unless you know what you are doing – and if you need a piece of software to do it for you then obviously you don’t).

  26. t

    If you’re worried about messing with the registry just save a backup before you make any changes to it.

  27. David

    Sadly the only key I needed help with was one which wasn’t recognised by the Sharpkeys programme.
    My keyboard has a split space bar and the left-hand half is a delete key,
    It was this key I pressed and was not recognised – is there any hope of an update to cure this?
    Many thanks,
    David Edwards

  28. kornnut

    I stumbled upon this website looking for ways to assign specific programs to currently unused function keys.

    For example, this product will allow you to set the calculator and various other items as any key you like. Is there a way to tell it to use a program I tell it to instead of just the defaults listed?

  29. Brandon

    sharpkeys doesn’t work with my Apple keyboard on Windows 7. I’m still looking for a way to get some of the media keys working.

  30. Eugeny

    Unfortunately, do not work for Fn key at the laptop.

  31. ash

    Hi,I want to change the alt/tab combination so that it no longer changed programs or windows when pressed together. However i want the keys to do their normal function when presses seperatly.
    This is for gaming purposes; can anyone explain how to do this using sharpkeys?

  32. Ann

    Hi–

    my spacebar doesn’t work, and i was wondering if i can use sharpkeys to map the function “space” to another key on my keyboard.

    thank you in advance.

  33. Jac

    Is it possible to use sharpkeys to create a second tab key? I want a tab on the right hand side as well as the left.

  34. rocky

    Is there any program to map multiple key or key combination to a single key

  35. AngieArtery

    Wow, thank you. I had a real major problem. After cleaned my laptop with a paper towel many of my important letter keys messed up. Thank you so much for this program :).

  36. rjd

    Just wat i was looking for.Too bad. Shud work for Lenovo’s function key.

  37. Gene

    Chun-Yu Lin and others are right. It doesn’t work for the Fn key on Lenovo’s. Why on earth Lenovo thinks that the Fn key is more important than the Ctrl key is beyond me. Has anyone found a real solution for Lenovo?

  38. Gene

    Ok good news for Lenovo users. Reboot and go into the BIOS and there is an option in config to swap the Fn and Ctrl keys. I just did it on my new T510

  39. Jamus

    Any ideas how to change “Esc” key to “Alt + F4″?

  40. lordton aka anton

    hello ! is there any way i can change caps lock to sleep\power button (the one in the list is not working by some reason((( )
    please help((

  41. wizlawz

    i am looking for a way to map keys for gameing, especially those online games that dont recognise gamepads/ controllers

    for instance IE: in order to hit say with a left hand punch and right hand much using both mouth buttons, i would like to map it to 1 mouse button, or say for example to equip dual wield weps i have to use ctrl-1 and ctrl-2 INSTEAD i would likre to have them both mapped to ctrl-1 instead, or something to that affect is this possible with this app? (if this is not what im looking for plz direct in the right direction)

    thank you for yuor moment in time

  42. jon

    I have used SharpKeys to swap my CAPS LOCK and my left CTRL keys under Win 7. Strangely, while tapping the new CAPS LOCK key now does alter the Caps Lock LED, using the new CTRL key does not allow me to do a CTRL-C to copy or a CTRL-V to paste. I just get a “C” or a “V” instead. The right CTRL key still works OK. It is as if the left [re-mapped] CTRL has simply stopped doing anything at all.

    CTRL-C sometimes works when I am remoting into other computers (but they also have the same keys swapped); sometimes it works if I press CTRL and then C VERY QUICKLY, as if something is monitoring the new CTRL key and allowing it to be a CTRL function if I do it within the first 1/4 sec, but not afterwards.

    Very strange. Any thoughts?

  43. jon

    It turns out that all of this bizarre behavior was due to a bad keyboard!

  44. red

    Try keytweak.

  45. Thoad

    …works perfect on windows 7 x64 (log off), would be great if possible to safe profiles… 6 letter keys just remapped to num pad keys for warcraft 3 tft :p good luck my windows password don’t need those letter keys!

  46. alicie

    HELP

    when i click on the download for this program I get a list of comments !

    Is it still available ?

    I’m newly on win 7 and i would like to change my keyboard that I’ve had with the program “Keytweak” since years, but I saw that this one was more recent.

    Thanks for a reply

  47. Lorreta

    Do you have to download this program? And if I do download it, is it possible to change the ” key to @ cause on my keyboard they are swapped round. Help will be much appreciated :) thank you!

  48. bdk

    @Gene

    Thank you very much for your BIOS tip. That saved me from early retirement due to finger strain on my left hand.

    Cheers.

  49. BRF

    I’ve been a ThinkPad user for over a decade and I have recently purchased my first non-Lenovo laptop and the reversed Ctrl/Fn keys have been driving me nuts so I downloaded this as soon as I read the description. But then I read though the comments and had to laugh at myself since it seems everyone else wants to do it the other way around. :)

  50. YJS

    Hi, there. I came across there to find this can be my redemption finally.
    I have been looking for solutions to this :
    How can I remap “SHIFT+SPACE” combination to “NOTHING” (Meaning: Disable SHIFT+SPACE).

    This combination is used in Chinese IME and really annoying if we don’t use it. Anybody can help on this ? I am not programmer so I can not code the scriot my self. :-(
    BIG THANKS!

  51. David B.

    I successfully used Sharp Keys on my Windows 7 machine. My new keyboard setup is quite different from my last laptop, and I kept using the wrong keys. Remapped my DEL and INS keys and PAGE UP/PAGE DOWN keys. Too bad the actual physical delete key is a different shape — I was able to pop off the PAGE UP AND PAGE DOWN and swap them along with my remap. Love it.

  52. Raul

    Hello, my enter key is broken, can i use this utility to chance the “q” key to now be enter?

  53. got a b a cunt

    y dose the net treat me like a cunt, all the programs what say they can fix what u need, don’t do it,
    when will pepole hunt down the coning cunts and chop them into cubes, it makes me sick cause if
    i done “””” the i can fix it bollocks””””” just give me your money for nothing the police would hunt
    me down and nick me for false ads i would be in nick, but here we are being tricked be a bunch of
    cunts and we have to put up with it, if u get my meaning, this won’t be posted so i am wasting my time
    writing this, but still i am only a cunt anyway dose anyone else feel the same or is it just me.

  54. Your motha :O

    Hei, if you going to juse this u going to get a problem whit JAVA, it wont work and only way to repair it is to uninstall sharpkey and reinstall java, JUST A WARNING !!!

  55. Surrealnirvana

    Some kid poured water on my laptop. I was able to save my PC before it fried but a few of the keys. no big deal since they were keys I never use. but the “end” button for some reason got stuck acting like it was being pressed. it made my PC near unusable, which is unfortunate since I use it for collage. Thanks to this program I will be able to no fall behind in my studies while I wait till payday(one month away for me) to buy a new external one.

  56. Tim

    when i want to turn off “alt+tab” and choose “type key” and type it, it just simply switches to the next app leaving me feeling stupid. what should i do? can’t find the alt+tab on the list! what should it look like?

  57. not cool

    This isn’t working for windows vista! when i try to disable my power and sleep buttons on my keyboard it does nothing! :\

  58. elia

    Thanks a lot :)
    no more ‘pc goes to hibernate’ by mistake !!!!!

  59. Pascale

    I am playing this game that uses the left shift key, and since I am stuck playing on a tiny notebook with a super small shift key in an inconvenient location, my pinky finger was getting very sore, so I looked all over the net to find how to remap keys. I used Sharpkey to remap the shift key onto the ‘f’ key and it worked perfectly fine when I type in any software, but or some reason, my game doesn’t recognize it, it still only responds to the left shift key. So frustrating!

  60. ElmerBeFuddled

    Hi The Geek,

    Is it possible on a MS 600 keyboard to swap the ” ¬ ” character (to the left of ‘1’) for the division ” Ă· ” character. I’m struggling with this but it would probably help if I knew and understood the character codes!

    Hope you can help

    TIA
    Elmer

  61. Simon077

    I want to remove alt and tab, but i dont see how i can do that without using alt or tab as an actual binding, and i use them both so its not worth removing either, is there a way i can remove alt+tab without removing alt or tab?

  62. Milva

    My 18 month daughter somehow someway managed to have both of my period keys once pressed to take me to my chess game….I have Windows Vista…PLEASE HELP ME……I cannot use the calculator and it is driving me crazy….THANKS

  63. Matt penner

    This worked great for me. Loaded it on a MacBook Air in Windows 7 on Boot Camp. Allowed me to remap the Mac right Option (Alt) key to the Application Menu (or Context Menu, Menu Key, whatever you call it).

    I saw someone state they couldn’t do this. What you need to do is map the Special Right-Alt key to the Special Applications function.

  64. lhsetzer

    The keyboard with my new HP Pavilion has the ” and @ keys reversed. I hope to use this utility to switch them back to what they are supposed to be. I’ll keep you posted. jThis could also be a Windows feature? Some other keys are misplaced, too.

  65. miserable

    hi,after pressing Fn+spacebar key my screen become larger then usual??how to reverse this effect??
    pls..help me help me..urgent..thx

  66. Lecramstar

    Hey.

    I was wondering if anybody could help me.
    Here’s my problem, my Escape key broke down to water damage.
    So I downloaded this program to remap the Escape button to the F1 button.

    It works generally, exept when I’m In-game.
    How can I fix this, so it will also be working in games?

    Thanks in the advance!

  67. Iulian

    Big question here … i used this program to change my laptop keyboard back as it went crazy (Q = scroll lock, escape = alt+tab) and it worked.

    A few weeks later i tried to use it on my desktop, as it had the SAME SPECIFIC problem, and on it it didnt work.

    I have both win 7 on them.. so .. any ideas ?

  68. cruel

    hi. can i make a commad like: “stop playing music in winamp” or “start” etc. ?
    i have the hotkeys liek this but there is no working driver for win7 to use it :(

Enter Your Email Here to Get Access for Free:

Go check your email!