TL;DR — Quick Summary
Zellij is a modern terminal multiplexer with built-in layout system, floating panes, plugins, and intuitive keybindings. Learn setup, layouts, and workflows.
Zellij is a terminal multiplexer that takes the power of tmux and wraps it in a modern, discoverable interface. Written in Rust, it provides split panes, tabs, persistent sessions, and a WebAssembly plugin system — all with sensible defaults that work immediately without configuration.
Prerequisites
- Linux, macOS, or WSL on Windows
- A modern terminal emulator (Alacritty, WezTerm, kitty, iTerm2)
Installation
# Rust/Cargo
cargo install --locked zellij
# macOS
brew install zellij
# Arch Linux
sudo pacman -S zellij
# Nix
nix-env -i zellij
# Pre-built binary
bash <(curl -L zellij.dev/launch)
# Verify
zellij --version
Quick Start
# Start new session
zellij
# Start named session
zellij -s dev
# Attach to existing session
zellij attach dev
# List sessions
zellij list-sessions
# Start with a layout
zellij --layout compact
Keybinding Modes
Zellij uses modes to avoid keybinding conflicts with terminal applications:
| Mode | Shortcut | Purpose |
|---|---|---|
| Normal | Default | Type normally |
| Pane | Ctrl+p | Split, resize, move panes |
| Tab | Ctrl+t | Create, switch, rename tabs |
| Resize | Ctrl+n | Resize current pane |
| Move | Ctrl+h | Move panes around |
| Scroll | Ctrl+s | Scroll through output, search |
| Session | Ctrl+o | Detach, manage sessions |
| Locked | Ctrl+g | Lock Zellij — pass all keys through |
The status bar at the bottom always shows available keys for the current mode.
Layouts
Create reusable workspace layouts with .kdl files:
// dev-layout.kdl
layout {
tab name="Code" focus=true {
pane split_direction="vertical" {
pane size="70%" command="nvim" {
args "."
}
pane split_direction="horizontal" {
pane command="bash"
pane command="bash" {
args "-c" "git log --oneline -20"
}
}
}
}
tab name="Server" {
pane command="npm" {
args "run" "dev"
}
}
tab name="Shell" {
pane
}
}
Launch: zellij --layout dev-layout.kdl
Floating Panes
# In pane mode (Ctrl+p)
# Press w to toggle floating panes
# Press f to create a new floating pane
# Floating panes overlay your layout — perfect for quick tasks
Configuration
Config file: ~/.config/zellij/config.kdl
// config.kdl
keybinds {
normal {
// Example custom keybindings
}
}
theme "catppuccin-mocha"
default_layout "compact"
default_shell "bash"
pane_frames false // Remove pane borders for cleaner look
Comparison
| Feature | Zellij | tmux | GNU Screen |
|---|---|---|---|
| Language | Rust | C | C |
| Discoverable UI | Built-in status bar | None | None |
| Config format | KDL | Custom | Custom |
| Layout system | KDL files | Custom | Basic |
| Floating panes | Yes | Popup (3.3+) | No |
| Plugin system | WASM | None | None |
| Default usability | Excellent | Requires config | Requires config |
| SSH persistence | Yes | Yes | Yes |
Real-World Workflow
You SSH into a production server and need to monitor logs, run commands, and edit configs simultaneously. Start zellij -s ops, create a tab with split panes: one for journalctl -f, one for htop, one for your shell. Disconnect from SSH — the session persists. Reconnect and zellij attach ops — everything is exactly where you left it.
Summary
- Zellij is a modern terminal multiplexer with built-in discoverability via the status bar
- Mode-based keybindings (pane, tab, resize, scroll) avoid conflicts with terminal apps
- KDL layout files define reusable workspace configurations with panes, tabs, and auto-commands
- Floating panes provide overlay terminals for quick tasks without disrupting your layout
- Sessions persist across SSH disconnections — reattach with
zellij attach - WebAssembly plugin system extends functionality with third-party integrations