I have a 2011 MacBook Air with OS X Mountain Lion (I've upgraded from Lion). And ever since upgrading my escape key randomly stops working. And it's not that the keyboard on the laptop would be damaged as the same happens if I use Apple's Bluetooth keyboard. So I'm guessing it's a software issue.

Also in some cases pressing ctrl+esc achieves the same thing as just esc so I'm 100% it's not a hardware problem.

Does anybody have any idea what this might be all about and how to fix it?

edit: the escape key stops working completely but it starts working again after I restart the computer.

edit2: this usually happens after the computer wakes from sleep. So it's not like that is just stopps working in the middle of using it, but rather after I put it to sleep (or just close the lid) and then open it again.

Has nobody got the same issue? Is there a better place to ask OS X related questions than Super User maybe?

This question came from our site for computer enthusiasts and power users.

Stops working, as in "does not respond to any pressing"? Or works intermittently?
–
user479Sep 25 '12 at 15:41

The first one. Then it works OK when I restart the whole computer.
–
Jan HančičSep 26 '12 at 6:36

You may have a hardware problem. I'd make a full backup if you haven't already, and take it to your local Genius Bar.
–
user479Sep 26 '12 at 15:57

2

Have you tried using a different (empty/pristine) user account and tried to reproduce the issue there? It's possible some software runs in the background and breaks things for you.
–
Daniel BeckOct 2 '12 at 9:30

10 Answers
10

If this problem happens in every application then it is indeed a system wide problem. If it only happens in one application it's an application problem.

This problem might also come from another (modifier) key getting stuck.

To check if the Esc key is ignored by the system itself or if another key is stuck use the Keyboard Viewer:

Go to Apple → System Preferences...

→ Keyboard

Enable Show Keyboard & Character Viewers in menu bar

Then when the problem happens again display the keyboard viewer and check if any keys are stuck. If not try using the esc key there and see if it displays as being pressed. If not then you probably have a driver problem.

You could then try installing your system on another drive and try to reproduce the issue on a clean install.

Could you improve your or joes post by listing the version of TotalFinder that causes this bug / interaction? Is it perhaps a known issue or fixable by the TotalFinder people (for bonus points)
–
bmike♦Jan 16 '13 at 13:10

Thanks! I disabled and re-enabled Visor from TotalFinder and it works! Saved me tons of trouble :)
–
NorrisJan 27 '13 at 13:32

Thanks for pointing this out. I never would have made the connection between my esc key problem and the TotalFinder Visor. Disabled 'Hide on ESC' and now I have my esc key back!
–
drebabelsFeb 6 '13 at 7:38

I hate suggesting this, but it should fix your problem. I too had a weird glitch from upgrading my mac OS. (mine was that i couldn't empty the recycle bin normally- i had to use console commands) The apple genius bar was lost, google turned up nothing, and no "expert" had any idea.

I know a clean install isn't an answer to the problem, but it's a means to a resolution of it...

Feel your frustration, let me know if you try this and if it works :)

(apple will do a clean install free of charge, if you're uncomfortable doing it)

Perhaps, if you dont want anything as radical as a clean install right away, you could install on a fresh external hard drive. Boot from that, and see if the problem is there. I think though, that this type of issue will show up or not with a new user account, so I agree to try Daniel Beck's idea first.
–
David DelMonteOct 2 '12 at 18:26

agreed.. I tried that with my issue without success.. external drive is a great idea.. good call :)
–
Ryan HollingsworthOct 2 '12 at 18:43

I should have said, that if this works, the OP will need to do a clean install afterwards..
–
David DelMonteOct 2 '12 at 20:29

Hmm, didn't know you can install OSX on an external drive and then boot from it. Will look into it. Clean install might not be such a bad idea, as the upgrade also messed with my PHP that I had. I'll just have to find the time now :)
–
Jan HančičOct 3 '12 at 8:49

As others have said, there's probably some application conflict that's causing the issue (since you said it's happening with the built-in keyboard and BT keyboard). I was having this problem, too, with the same symptoms (happening after waking up from sleep, reboot solves the issue).

In my case I believe it's related to my use of TotalFinder, specifically the Visor feature of it. Bringing up the Visor and then hitting escape seems to recover from the failure until my Mac sleeps again. If you disable the Visor or uninstall TotalFinder, the escape key wont become lost in the first place.

Note that in order to solve this, you might not have to disable the Visor feature completely. I only disabled the option to 'Hide on ESC' and now I can switch windows between my terminal apps without sacrificing the option key

I wouldn't do a drive wipe and clean install just yet. I would first boot into safe mode. Do this by holding down the Shift key as soon as you hear the Apple "chime". See if you have the problem then. If the escape key works reliably, it is likely a driver or software issue that is interfering. You can remove apps or third-party drivers to try to figure out which one(s) are the cause.

If it still happens in safe mode, it might be time to do a drive wipe and reinstall OS X from scratch.

The escape key on my Macbook Air was not working at all. I realized that the problem was that the Speakable Items Utility had assigned the Escape Key as the "Listening Key." Turning off Speakable Items (under Accessibility panel in System Preferences) seems to have fixed the problem.

DON"T REINSTALL YET:
I had this problem. The keyboard viewer did not register "esc" presses. Turned out it was from turning on speech commands while playing chess. To fix it, I went to System Preferences --> Accessibility --> Speakable Items --> Listening Key. Then I changed the listening key to something other than esc, and the problem went away immediately.