zterm

Keyboard shortcuts

Every chord this build binds, on each platform. zterm bindings prints the same table for the build you have installed. It lists the defaults only and says config=defaults in its header, so it does not show what your own file changes.

zterm has three levels: a window holds tabs, and a tab holds panes. The shortcuts follow that shape. Panes are the innermost level and the cheapest to reach, windows the outermost and the most deliberate.

On macOS the terminal's shortcuts live on Cmd, which the shell never sees. Everything you type with Control alone goes to the program in the pane, so Ctrl+C still interrupts and Ctrl+R still searches your shell history.

On Linux and Windows there is no spare modifier, so the terminal's shortcuts live on Ctrl+Shift. Where macOS adds Shift to a chord, Linux and Windows add Alt instead, because Shift is already spent.

A few chords break that pattern where a platform convention is stronger than the rule. Splits are Cmd+D on macOS and Ctrl+Shift+\ elsewhere, and full screen is Cmd+Ctrl+F on macOS and F11 elsewhere.

macOS

Chord Action
Cmd+, settings
Cmd+- font_size_down
Cmd+0 font_size_reset
Cmd+1 select_pane {"index":1}
Cmd+2 select_pane {"index":2}
Cmd+3 select_pane {"index":3}
Cmd+4 select_pane {"index":4}
Cmd+5 select_pane {"index":5}
Cmd+6 select_pane {"index":6}
Cmd+7 select_pane {"index":7}
Cmd+8 select_pane {"index":8}
Cmd+9 select_pane {"index":9}
Cmd+= font_size_up
Cmd+[ focus_prev_pane
Cmd+] focus_next_pane
`Cmd+`` next_window
Cmd+A select_all
Cmd+Alt+1 select_window {"index":1}
Cmd+Alt+2 select_window {"index":2}
Cmd+Alt+3 select_window {"index":3}
Cmd+Alt+4 select_window {"index":4}
Cmd+Alt+5 select_window {"index":5}
Cmd+Alt+6 select_window {"index":6}
Cmd+Alt+7 select_window {"index":7}
Cmd+Alt+8 select_window {"index":8}
Cmd+Alt+9 select_window {"index":9}
Cmd+Alt+Down focus_down
Cmd+Alt+Left focus_left
Cmd+Alt+Right focus_right
Cmd+Alt+Shift+[ move_tab_left
Cmd+Alt+Shift+] move_tab_right
Cmd+Alt+Up focus_up
Cmd+C copy
Cmd+Ctrl+= equalize_panes
Cmd+Ctrl+B break_pane
Cmd+Ctrl+Down resize_pane_down
Cmd+Ctrl+F toggle_fullscreen
Cmd+Ctrl+J join_pane
Cmd+Ctrl+Left resize_pane_left
Cmd+Ctrl+Right resize_pane_right
Cmd+Ctrl+S swap_pane
Cmd+Ctrl+Up resize_pane_up
Cmd+D split_right
Cmd+Down next_prompt
Cmd+End scroll_to_bottom
Cmd+F find
Cmd+G find_next
Cmd+Home scroll_to_top
Cmd+J pick_pane
Cmd+K clear_scrollback
Cmd+L scroll_line_up
Cmd+M selection_mode
Cmd+N new_window
Cmd+O pick_link
Cmd+Pagedown scroll_page_down
Cmd+Pageup scroll_page_up
Cmd+Q quit
Cmd+R reload_pane
Cmd+Shift+, reload_settings
Cmd+Shift+= font_size_up
Cmd+Shift+[ prev_tab
Cmd+Shift+] next_tab
`Cmd+Shift+`` prev_window
Cmd+Shift+A select_output
Cmd+Shift+D split_down
Cmd+Shift+Enter zoom_pane
Cmd+Shift+G find_previous
Cmd+Shift+L scroll_line_down
Cmd+Shift+P palette
Cmd+Shift+W close_tab
Cmd+T new_tab
Cmd+Up previous_prompt
Cmd+V paste
Cmd+W close_pane
Ctrl+Tab focus_last_viewed_pane

Linux

Chord Action
Ctrl+Shift+, reload_settings
Ctrl+Shift+- split_down
Ctrl+Shift+1 select_pane {"index":1}
Ctrl+Shift+2 select_pane {"index":2}
Ctrl+Shift+3 select_pane {"index":3}
Ctrl+Shift+4 select_pane {"index":4}
Ctrl+Shift+5 select_pane {"index":5}
Ctrl+Shift+6 select_pane {"index":6}
Ctrl+Shift+7 select_pane {"index":7}
Ctrl+Shift+8 select_pane {"index":8}
Ctrl+Shift+9 select_pane {"index":9}
Ctrl+Shift+= font_size_up
Ctrl+Shift+[ focus_prev_pane
Ctrl+Shift+\ split_right
Ctrl+Shift+] focus_next_pane
Ctrl+Shift+A select_all
Ctrl+Shift+Alt+1 select_window {"index":1}
Ctrl+Shift+Alt+2 select_window {"index":2}
Ctrl+Shift+Alt+3 select_window {"index":3}
Ctrl+Shift+Alt+4 select_window {"index":4}
Ctrl+Shift+Alt+5 select_window {"index":5}
Ctrl+Shift+Alt+6 select_window {"index":6}
Ctrl+Shift+Alt+7 select_window {"index":7}
Ctrl+Shift+Alt+8 select_window {"index":8}
Ctrl+Shift+Alt+9 select_window {"index":9}
Ctrl+Shift+Alt+= equalize_panes
Ctrl+Shift+Alt+A select_output
Ctrl+Shift+Alt+B break_pane
Ctrl+Shift+Alt+Down resize_pane_down
Ctrl+Shift+Alt+Enter zoom_pane
Ctrl+Shift+Alt+G find_previous
Ctrl+Shift+Alt+J join_pane
Ctrl+Shift+Alt+L scroll_line_down
Ctrl+Shift+Alt+Left resize_pane_left
Ctrl+Shift+Alt+Right resize_pane_right
Ctrl+Shift+Alt+S swap_pane
Ctrl+Shift+Alt+Up resize_pane_up
Ctrl+Shift+Alt+W close_tab
Ctrl+Shift+C copy
Ctrl+Shift+Down focus_down
Ctrl+Shift+F find
Ctrl+Shift+G find_next
Ctrl+Shift+J pick_pane
Ctrl+Shift+K clear_scrollback
Ctrl+Shift+L scroll_line_up
Ctrl+Shift+Left focus_left
Ctrl+Shift+M selection_mode
Ctrl+Shift+N new_window
Ctrl+Shift+O pick_link
Ctrl+Shift+P palette
Ctrl+Shift+Pagedown move_tab_right
Ctrl+Shift+Pageup move_tab_left
Ctrl+Shift+Q close_window
Ctrl+Shift+Right focus_right
Ctrl+Shift+T new_tab
Ctrl+Shift+Tab prev_tab
Ctrl+Shift+Up focus_up
Ctrl+Shift+V paste
Ctrl+Shift+W close_pane
Ctrl+Shift+X next_prompt
Ctrl+Shift+Z previous_prompt
Ctrl+, settings
Ctrl+- font_size_down
Ctrl+0 font_size_reset
Ctrl+= font_size_up
Ctrl+C copy
Ctrl+Insert copy
Ctrl+Kp_0 font_size_reset
Ctrl+Kp_add font_size_up
Ctrl+Kp_subtract font_size_down
Ctrl+Pagedown next_tab
Ctrl+Pageup prev_tab
Ctrl+R reload_pane
Ctrl+Tab focus_last_viewed_pane
F(11) toggle_fullscreen
Shift+End scroll_to_bottom
Shift+Home scroll_to_top
Shift+Insert paste
Shift+Pagedown scroll_page_down
Shift+Pageup scroll_page_up

Windows

Chord Action
Ctrl+Shift+, reload_settings
Ctrl+Shift+- split_down
Ctrl+Shift+1 select_pane {"index":1}
Ctrl+Shift+2 select_pane {"index":2}
Ctrl+Shift+3 select_pane {"index":3}
Ctrl+Shift+4 select_pane {"index":4}
Ctrl+Shift+5 select_pane {"index":5}
Ctrl+Shift+6 select_pane {"index":6}
Ctrl+Shift+7 select_pane {"index":7}
Ctrl+Shift+8 select_pane {"index":8}
Ctrl+Shift+9 select_pane {"index":9}
Ctrl+Shift+= font_size_up
Ctrl+Shift+[ focus_prev_pane
Ctrl+Shift+\ split_right
Ctrl+Shift+] focus_next_pane
Ctrl+Shift+A select_all
Ctrl+Shift+Alt+1 select_window {"index":1}
Ctrl+Shift+Alt+2 select_window {"index":2}
Ctrl+Shift+Alt+3 select_window {"index":3}
Ctrl+Shift+Alt+4 select_window {"index":4}
Ctrl+Shift+Alt+5 select_window {"index":5}
Ctrl+Shift+Alt+6 select_window {"index":6}
Ctrl+Shift+Alt+7 select_window {"index":7}
Ctrl+Shift+Alt+8 select_window {"index":8}
Ctrl+Shift+Alt+9 select_window {"index":9}
Ctrl+Shift+Alt+= equalize_panes
Ctrl+Shift+Alt+A select_output
Ctrl+Shift+Alt+B break_pane
Ctrl+Shift+Alt+Down resize_pane_down
Ctrl+Shift+Alt+Enter zoom_pane
Ctrl+Shift+Alt+G find_previous
Ctrl+Shift+Alt+J join_pane
Ctrl+Shift+Alt+L scroll_line_down
Ctrl+Shift+Alt+Left resize_pane_left
Ctrl+Shift+Alt+Right resize_pane_right
Ctrl+Shift+Alt+S swap_pane
Ctrl+Shift+Alt+Up resize_pane_up
Ctrl+Shift+Alt+W close_tab
Ctrl+Shift+C copy
Ctrl+Shift+Down focus_down
Ctrl+Shift+F find
Ctrl+Shift+G find_next
Ctrl+Shift+J pick_pane
Ctrl+Shift+K clear_scrollback
Ctrl+Shift+L scroll_line_up
Ctrl+Shift+Left focus_left
Ctrl+Shift+M selection_mode
Ctrl+Shift+N new_window
Ctrl+Shift+O pick_link
Ctrl+Shift+P palette
Ctrl+Shift+Pagedown move_tab_right
Ctrl+Shift+Pageup move_tab_left
Ctrl+Shift+Q close_window
Ctrl+Shift+Right focus_right
Ctrl+Shift+T new_tab
Ctrl+Shift+Tab prev_tab
Ctrl+Shift+Up focus_up
Ctrl+Shift+V paste
Ctrl+Shift+W close_pane
Ctrl+Shift+X next_prompt
Ctrl+Shift+Z previous_prompt
Ctrl+, settings
Ctrl+- font_size_down
Ctrl+0 font_size_reset
Ctrl+= font_size_up
Ctrl+C copy
Ctrl+Insert copy
Ctrl+Kp_0 font_size_reset
Ctrl+Kp_add font_size_up
Ctrl+Kp_subtract font_size_down
Ctrl+Pagedown next_tab
Ctrl+Pageup prev_tab
Ctrl+R reload_pane
Ctrl+Tab focus_last_viewed_pane
F(11) toggle_fullscreen
Shift+End scroll_to_bottom
Shift+Home scroll_to_top
Shift+Insert paste
Shift+Pagedown scroll_page_down
Shift+Pageup scroll_page_up

What the tables do not say

Close pane closes the smallest thing that makes sense. If the tab has other panes, only the focused pane closes. If it was the tab's last pane, the tab closes too. If that was the window's last tab, the window closes. The x on a pane's chip takes the same path.

Closing goes back to where you were. When the pane or tab you are in closes, by a close key, the x on its chip or exit in its shell, you land in the one you viewed before it, not its neighbour. Each window keeps its own order. A tab opened in the background, such as one an agent opened, is never chosen just because it is newest, and a pane or tab that closes while you are elsewhere leaves you where you are.

Focus Last Viewed Pane goes back by history, not by position. Ctrl+Tab, on every platform, takes you to the pane you were viewing before this one, switching tabs if it has to, and pressed again it brings you back. Focus Previous Pane and Previous Tab move by position on screen instead. It stays in the window, it never picks a tab opened in the background, and with no other pane viewed in the window it does nothing. Because Ctrl+Tab is bound, it never reaches the program in the pane, in any keyboard mode. On macOS it used to arrive there as a Tab.

On Linux and Windows, Ctrl+Tab no longer goes to the next tab. Ctrl+PageDown does, and Ctrl+Shift+Tab still goes to the previous tab. To put Ctrl+Tab back on the next tab, add this line to [keybindings]:

"ctrl+tab" = "next_tab"

Pane numbers count across the whole window, in the order the chips appear on the bar, so the fourth number is the fourth chip whichever tab it belongs to. A number with no pane behind it does nothing, and the same is true of a window number past the number of open windows.

There is no "tab 3" chord. The number keys select panes, and pane numbers run across every tab in the window, so pressing a pane's number switches to its tab as part of reaching it.

Pick a pane is for windows with more than nine panes. Every pane shows a large label, 1 to 9 and then a to z, and the next key you press picks one. Any other key, or Esc, closes the overlay. Panes past z are reachable from the palette's Go to Pane entry, which lists them by name.

Zoom pane draws the focused pane over its whole tab and hides its siblings. The same chord puts them back. The hidden panes keep their numbers, and selecting one of them, or splitting, ends the zoom.

Ctrl+C on Linux and Windows does two things. With text selected it copies, the way Windows Terminal does. With nothing selected it goes to the shell and interrupts the running program as usual.

Keyboard selection places a cursor in the pane and toggles off with the same chord. No chord moves that cursor yet, so the mode is a cursor you can see and not yet drive. It does not open while a full-screen program such as vim or less has the pane, because those programs own the keyboard there.

Select command output and the two prompt chords need shell integration, which is the shell marking where each prompt starts. Without those marks zterm does not take the chord and it reaches the program in the pane unchanged.

Reload page works only in a web pane. Cmd+R on macOS and Ctrl+R on Linux and Windows reload the page in the focused web pane. In a terminal pane zterm does not take the chord, so Ctrl+R still reaches the shell's history search.

Typing returns the pane to the live edge, so a stray scroll chord costs one keystroke to undo.

Find opens a bar along the pane. While it is open, typing edits the query, Enter repeats the last step in the same direction, and Esc closes the bar. Find next and find previous work whether or not the bar has focus.

Open link labels the links in the visible pane, 1 to 9 then a to z, and the next key opens one. It labels three kinds of link: the ones a program declared, the web and mail addresses a program only printed, and the zc ticket aliases described next. When more links are in view than there are labels, the ones nearest the bottom get them. Every link is also clickable at any time: hold Cmd on a Mac, or Ctrl+Shift elsewhere, and click it.

A zc ticket alias is a link. When the zc coordinator is running on this machine with its dashboard on, an alias in a pane's output, such as ACME-13, opens that ticket on the dashboard. Only an alias the coordinator holds is a link, so UTF-8 and ACME-99999 stay plain text. The ticket_links setting turns this off.

Zoom in and zoom out change the text size for this session only. Reset zoom goes back to whatever font_size your settings file says.

Rename a pane by double-clicking its chip on the bar, or from the palette's Rename Pane entry. It has no default chord.

Actions with no default chord

These are in the palette and can be given a chord in your settings file: Close Window on macOS, Quit on Linux and Windows, Next Window and Previous Window on Linux and Windows, Go to Pane, Rename Pane, Permissions.

spawn has no palette row and no default chord either. It opens a new tab running zspawn, the agent launcher, with its own wizard. The agent rows under the + chevron are the same action with a harness named. Bind it to a chord if you want the wizard on a key.

Changing the shortcuts

Chords are set in the [keybindings] table of the settings file. Run zterm config --path to find it. Each line is a chord on the left and an action on the right:

[keybindings]
"ctrl+shift+t" = "new_tab"
"cmd+w" = "close_pane"

The chord is spelled literally and means the same keys on every platform. ctrl+shift+t is Ctrl and Shift and T wherever the file is read. There is no token meaning "this platform's modifier", so a file shared between a Mac and a Linux box lists each platform's chords separately.

The modifiers are ctrl, shift, alt and super, with control, opt, option, cmd, command and win accepted as aliases. Case does not matter. The key is a single character, a named key such as enter, tab, esc, up, down, left, right, home, end, pageup, pagedown, insert or delete, a function key f1 to f20, or a numpad key kp0 to kp9, kpadd, kpsubtract, kpmultiply, kpdivide, kpdecimal, kpenter or kpequal. The plus key itself is written as a trailing double plus, as in "ctrl++".

The action names are the ones in the second column of the tables above, which are also the names zterm bindings prints. A name zterm does not know fails the whole file with a message naming the chord and the nearest real action, and zterm config --check reports it without opening a window.

To turn a default off, bind its chord to unbound. The classic case is Vim's blockwise visual mode on Linux, which needs Ctrl+Shift+V to reach Vim:

[keybindings]
"ctrl+shift+v" = "unbound"

A chord you rebind fires whenever it is pressed. It does not inherit the condition the default carried, so a rebound previous_prompt runs without waiting for shell integration marks.

To see what is bound right now, open Settings and press Enter on the Keybindings row. It lists every chord that does something on this platform: the defaults, then the chords from your [keybindings] table, each marked yours. A default you pointed at another action reads "yours, was ...", one you turned off reads "unbound, was ...", and a line binding a default to what it already does reads "yours, same as built-in". Type to filter by action name or by chord, and press Esc to go back.

Every row there reads "Modify: ...", such as "Modify: Select All". Typing an action's name in the command palette offers the same Modify row beside the action itself, so Return on Select All still selects all and Return on Modify: Select All opens that chord's verbs without going through Settings first.

To change one, press Enter on its row. The verbs, in order: Change This Chord, Reset to Built-in (only when your file already speaks about the chord, and it removes your line), Add Another Chord, and Unbind. Each verb's hint is what it writes, in your file's own spelling. Change This Chord and Add Another Chord both read the next chord you press and show what it would do before anything is written: free, replaces Copy, was unbound, or already this action, nothing to write. Return writes it, except in that last case, where there is nothing to write. Change This Chord also retires the chord you were on in the same write: a default becomes unbound, and a chord only your file bound has its row removed. Esc leaves without writing, so a bare Esc or a bare Return cannot itself be bound. Hold a modifier to bind either. The change is live on the next keypress and the file is edited in place, comments and all.

The command palette

The palette opens on seven groups: Window, Tab, Launch, Pane, Edit, Find, View, each wearing a chevron at its left. Then come Permissions and Settings, then Reload Settings and Quit. Enter on a group lists its actions, including the ones with no chord, under a muted Back row. Enter on that row, or Esc, steps back out.

Type to filter, up and down to move, Enter to run, Esc to close. The search covers every list you can reach from the top level, not only the commands: the launch rows, the settings editor's rows, the Modify rows of the keybindings list, your panes as Go to Pane lists them, and your grants as Permissions lists them, in that order after the commands. Choosing a found row does what choosing it in its own list does. The values under a setting are not searched: the search stops at the Set row and one Return reaches them. The scrolling and prompt chords are in no group, because nobody opens a menu to scroll up a line, but typing scroll or prompt finds them.

Reading zterm bindings

The command's first column spells the terminal's own modifier as cmd+ on every platform, so cmd+t on Linux means Ctrl+Shift+T and cmd+alt+w means Ctrl+Shift+Alt+W. The tables above are spelled out per platform instead. Rows that start with ctrl+, shift+ or a bare key name are literal in both. The settings file is always literal, so copy a row into [keybindings] with the modifier written out.