There's an option in Terminal.app -> Preferences -> Settings -> Keyboard but it allows me only to set both option keys as meta keys. iTerm.app has such an option but don't like that application.

  • Would a solution that changed the system key mapping be acceptable? You could remap the right option key to do whatever else you choose, system wide.
    – bmike
    Aug 11, 2011 at 13:58
  • That wouldn't help since I need the option key functionality.
    – blargh
    Aug 11, 2011 at 14:15
  • If the programmers of Terminal app added this functionality - it's hidden with a preference you'd have to set manually in the plist. You're probably out of luck and will have to choose another program (have you looked at both iTerm and iTerm 2) - but it's a great question and logical need for people that want a meta key. Emacs user, by chance?
    – bmike
    Aug 11, 2011 at 14:19

2 Answers 2


If you aren't totally set on using Terminal, I believe that iTerm2 has a setting to just use one of the option keys as meta. If you are, is there a setting to maybe use the Esc key as meta? I know that it's more convenient to use the option key, but the Esc key might be easier to set.

  • Yeah, I'm using the Esc key as meta key currently (I think it's set as meta key per default?) and hate it. It's not only hard to reach, but its function is also slightly different. For example: In irssi if you want to switch between channels you can keep alt pressed while choosing your channel via the number keys. Using Esc you'd have to press it every single time before pressing a number key.
    – blargh
    Aug 11, 2011 at 14:33
  • Yeah, I only mention Esc because I've had better luck getting it to work with a few of the command line programs I use.
    – bringel
    Aug 11, 2011 at 20:44
  • 1
    "Meta key" specifically refers to a modifier key, like Control, Shift, Option and Command. The Esc key is never "the Meta key". The Meta key can either cause an ESC to be written preceding the character you type or it can set the high bit of the character byte; however, modern terminals usually use UTF-8 or other encodings that require all eight bits, so usually the ESC prefix is used. Terminal only supports sending the ESC prefix. So, typing ESC before another character is simply sending the meta escape sequence to the tty and doesn't require configuration (at least, not in Terminal).
    – Chris Page
    Aug 12, 2011 at 1:50

I have built a solution myself and it doesn't require abandoning Terminal.app in favour of iTerm 2.

It is a simple status bar app that runs in the background and rewrites all left Alt + $KEY key events to two key events in rapid succession, Esc, then $KEY; however, it only does this if Terminal.app is in focus.

You can find the source for the app here. You'll need Xcode to build it.


You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .