Skip to content
Emacs icon

Emacs shortcuts for Mac

154 shortcuts · 17 categories

Emacs is a text editor that is popular among programmers and is known for its extensibility and customizability. Download Emacs

Hover a shortcut to add it to Pie Menu

Mac keyboard shortcuts for Emacs

Registers

  • Jump to point saved in register^ x  r  j
  • Save value of point in register^ x  r  space
  • Insert register contents into buffer^ x  r  i
  • Save region in register^ x  r  s

Info

Rectangles

  • Prefix each line with a string^ x  r  t
  • Blank out rectangle^ x  r  c
  • Open rectangle, shifting text right^ x  r  o
  • Yank rectangle^ x  r  y
  • Kill rectangle^ x  r  k
  • Copy rectangle to register^ x  r  r

Shells

  • Start a shell in window *shell*shell
  • Filter region through a shell commandcontrol u  alt |
  • Run a shell command on the regionoption |
  • Execute a shell command asynchronouslyoption &
  • Execute a shell commandoption !

Transposing

  • Transpose sexps⌃ (control) + ⌥ (option) + t Add →
  • Transpose linescontrol x t
  • Transpose words⌥ (option) + t Add →
  • Transpose characters⌃ (control) + t Add →

Buffers

  • Kill a buffer^ x  k
  • List all buffers^ x b
  • Select another buffer^ x  b

The Minibuffer

Case Change

Formatting

  • Set face⌥ (option) + o Add →
  • Set prefix each line starts with^ x .
  • Set fill column to arg^ x f
  • Fill paragraph⌥ (option) + q Add →
  • Put exactly one space at point⌥ (option) + space Add →
  • Delete all white space around point⌥ (option) + \ Add →
  • Join line with previous (with arg, next)⌃ (control) + ⌥ (option)Add →
  • Delete blank lines around point^ x o
  • Move rest of line vertically down⌃ (control) + ⌥ (option) + o Add →
  • Insert newline after point⌃ (control) + o Add →
  • Indent for comment⌥ (option) + ; Add →
  • Indent region rigidly arg columns^ x tab
  • Indent sexp (mode-dependent)⌃ (control) + ⌥ (option) + q Add →
  • Indent region (mode-dependent)⌃ (control) + ⌥ (option) + \ Add →
  • Indent current line (mode-dependent)⇥ Add →

Marking

Killing and Deleting

  • Replace last yank with previous kill⌥ (option) + y Add →
  • Yank back last thing killed⌃ (control) + y Add →
  • Kill through next occurrence of 'c' char⌥ z c
  • Copy region to kill ring⌥ (option) + w Add →
  • Kill region⌃ (control) + w Add →
  • Delete sexp to end⌃ (control) + ⌥ (option) + k Add →
  • Delete sexp to beginning⌥ (option) + ⌃ (control) + k Add →
  • Delete sentence to end⌥ (option) + k Add →
  • Delete sentence to bebinning^ x del
  • Delete line to end⌃ (control) + k Add →
  • Delete line to beginning⌥ (option) + ⌃ (control) + k Add →
  • Delete word forward⌥ (option) + d Add →
  • Delete word backward⌥ (option) + ⌫ Add →
  • Delete character forward⌃ (control) + d Add →
  • Delete character backward⌫ Add →

Motion

Error Recovery

  • Redraw garbaged screen⌃ (control) + l Add →
  • Restore a buffer to its original contentsrevert-buffer
  • Undo an unwanted change^ x u
  • Recover files lost by a system crashrecover-session
  • Abort partially typed or executing command⌃ (control) + g Add →

Getting Help

  • Get mode-specific information^ h m
  • Describe a function^ h f
  • Describe the function a key runs^ h k
  • Apropos: show commands matching a string^ h a
  • Scroll help window⌃ (control) + ⌥ (option) + v Add →
  • Remove help window^ x 1
  • Enter tutorial^ h t
  • Show help⌃ (control) + h Add →

Files

  • Toggle read-only status of buffer^ x q
  • Write buffer to a specified file^ x w
  • Replace this file with the file you really want^ x v
  • Insert contents of another file into this buffer^ x i
  • Save all files^ x s
  • Save a file back to disk^ x s
  • Read a file into Emacs^ x f

General

  • Exit Emacs permanently^ x c
  • Suspend Emacs (or iconify it under X)⌃ (control) + z Add →
  • Execute extended command⌥ (option) + x Add →

Download Keyboard Cheat Sheet for Emacs for Mac

Do you want all keyboard shortcuts for Emacs in one pdf?

Cheat sheet

Community shortcuts for Emacs

Be the first to share — open Pie Menu → Emacs → Share Config

View community page →
Pie Menu

Get started with Pie Menu today.

The convenience of shortcuts without the memorization!