Skip to content

tmux

The default prefix is Ctrl+b. All key bindings below assume it unless noted. Commands prefixed with $ run in a shell; commands prefixed with : run in tmux command mode (Ctrl+b : to open the prompt).

Sessions and Windows

Action Session Window
βž• New tmux new -s <name> Ctrl+b c
πŸ“‹ List tmux ls / Ctrl+b s Ctrl+b w
✏️ Rename Ctrl+b $ Ctrl+b ,
❌ Close tmux kill-session -t <name> / : kill-session Ctrl+b &
πŸ”€ Attach / switch tmux attach -t <name> Ctrl+b 0–9 / Ctrl+b n / Ctrl+b p
πŸ” Attach or create tmux new-session -A -s <name>
πŸšͺ Detach Ctrl+b d
πŸ”ƒ Toggle last active Ctrl+b l

Panes

Action Binding
➑️ Split horizontally (side by side) Ctrl+b %
⬇️ Split vertically (top / bottom) Ctrl+b "
πŸ”€ Switch to pane by direction Ctrl+b ↑ ↓ ← β†’
πŸ” Switch to next pane Ctrl+b o
πŸ”ƒ Toggle last active pane Ctrl+b ;
πŸ”’ Show pane numbers / jump Ctrl+b q, then number
↔️ Move pane left / right Ctrl+b { / Ctrl+b }
πŸͺŸ Convert pane to window Ctrl+b !
❌ Close current pane Ctrl+b x

Misc

Action Command
Enter command mode Ctrl+b :
Enable mouse : set mouse on
List all key bindings Ctrl+b ?

Sources