Option Commands
set-option
Set an option value:set
Flags:
-g: Set global option (server-level)-w: Set window option-s: Set server option-p: Set pane option-a: Append to string options (array options)-u: Unset option (revert to default)-F: Expand formats in value-q: Suppress errors
show-options
Display option values:show
Flags:
-g: Show global options-w: Show window options-s: Show server options-A: Show all options (including defaults)-v: Show only the value-H: Show option type and metadata
Option Scopes
From options-table.c:25-32, tmux organizes options by scope:Server Options
Server options affect the entire tmux server. Set withset -s or set-option -s.
Key server options:
Session Options
Session options affect individual sessions. Set withset -g for global or set -t session: for specific sessions.
Key session options:
Window Options
Window options affect individual windows. Set withset -w or setw.
Key window options:
Pane Options
Some options can be set at the pane level (per-pane basis):Option Types
From options-table.c:34-111, tmux options have different types:String Options
Number Options
Flag Options (Boolean)
Choice Options
Color Options
Style Options
Style options combine multiple attributes:Array Options
Array options can have multiple values:Format Variables
Many options support format variables that are expanded at runtime:#{session_name}- Session name#{window_index}- Window index#{window_name}- Window name#{pane_index}- Pane index#{pane_title}- Pane title#{pane_current_command}- Current command in pane
Command Aliases
From options-table.c:294-306, command aliases allow shorthand for common commands:Option Inheritance
Options inherit from broader scopes:- Pane options inherit from window options
- Window options inherit from session options
- Session options inherit from global options
- Global options use built-in defaults
Viewing Options
Unsetting Options
Revert an option to its default value:Common Configuration Patterns
Status Line Configuration
Window Status Configuration
Terminal Configuration
Mouse Configuration
Some options only take effect for new sessions, windows, or panes. Changes to
default-terminal, for example, only affect newly created sessions.