I'm so used to using C-a for the home key (based on my being an emacs nerd) that it bothers me that this is the combination that screen uses to start commands. Can I bind something else to it?


The C-a combination can be remapped from the .screenrc file, with the bind command.

This website should be a huge help to you: http://www.softpanorama.org/Utilities/Screen/screenrc_examples.shtml

  • Sorry - do you mean the escape command?
    – Greg
    Apr 12 '16 at 23:19
  • it may be almost 10 years late, but pointing to help file is frowned upon in Stack Exchange, perhaps the mods weren't so mean back then!!
    – vfclists
    Feb 18 '19 at 2:56

From my own .screenrc :

# replace Ctrl-A with Ctrl-O
escape ^Oo
  • I use Ctrl-Z personally, because that's the least frequently used key in Emacs, at least for me.
    – Teddy
    Oct 24 '09 at 21:43
  • 6
    But Ctrl-Z is used in the shell to suspend jobs - so not ideal imo.
    – GodEater
    Oct 28 '09 at 9:17
  • is that thebest combo though? ctrl a, is normally left hand, this messes a user up to moving it to either two hand, or right hand. cant you find something closer to the a key? Mar 18 '16 at 17:58

From screen's man page related to the -e option:

       -e xy
            specifies the command character to be x and the character generat-
            ing a literal command character to y (when typed after the command
            character).   The default is "C-a" and `a', which can be specified
            as "-e^Aa".  When creating a screen session, this option sets  the
            default  command character. In a multiuser session all users added
            will start off with this command character. But when attaching  to
            an  already  running session, this option changes only the command
            character of the attaching user.  This  option  is  equivalent  to
            either the commands "defescape" or "escape" respectively.

  • Sigh... when in doubt, check the man page. :-/ Aug 22 '09 at 14:40
  • 1
    Could you put an example of invocation?
    – ssice
    Jan 12 '13 at 18:56

It helps to go through the menu. :-/

I changed it by hitting F9, and selecting "change escape sequence."

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.