Install guide · macOS
Install tmux on macOS
Run brew install tmux in Terminal. That installs tmux 3.8, the current release, on Apple Silicon and Intel Macs. This guide also covers MacPorts, a no-dependency binary, building from source, and the macOS setup people trip over: PATH, the clipboard, the Option key and colors.
On this page
Install tmux on macOS in one line
Quick answer
How do I install tmux on a Mac?
brew install tmux
tmux -V
tmux 3.8No Homebrew yet? Install it first (one command). Then type tmux to start your first session.
Every method below gives you the real tmux. They differ in which version you get, whether they work on Intel Macs, and how you update.
| Method | Version (28 Oct 2026) | Apple Silicon | Intel | Update with |
|---|---|---|---|---|
| Homebrew | 3.8 | Prebuilt | Builds from source | brew upgrade tmux |
| MacPorts | 3.8 | Yes | Yes | sudo port upgrade tmux |
| Static binary | 3.7c | Yes | Yes | download again |
| From source | 3.8 or master | Yes | Yes | rebuild |
Versions from formulae.brew.sh, ports.macports.org and the tmux-builds releases page, checked 28 October 2026.
Install tmux with Homebrew
Homebrew is the package manager most Mac developers already have. Its tmux formula tracks upstream closely: it shipped 3.8 within days of the release.
Install Homebrew (skip this if you have it)
Terminal/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"The installer asks for your password and installs Apple's Command Line Tools if they are missing. At the end it prints two "Next steps" lines that add
brewto your PATH. Run them, or the next step fails withcommand not found: brew.Install tmux
Terminalbrew install tmuxHomebrew also installs the four libraries tmux needs: libevent, ncurses, utf8proc (correct widths for emoji and other wide characters) and jemalloc (tmux uses it on macOS since 3.7c to avoid a
callocbug).Check it worked
Terminaltmux -V tmux 3.8 which tmux /opt/homebrew/bin/tmuxOn an Intel Mac,
which tmuxshows/usr/local/bin/tmux. Now runtmux new -s work; the status line at the bottom means you are in. Press Ctrl+b d to detach andtmux attachto come back. More on sessions →
Apple Silicon and Intel: the paths are different
Homebrew installs to /opt/homebrew on Apple Silicon (M1 and later) and to /usr/local on Intel. That matters when you copy a path from a blog post into a script, a launchd file or your config.
eval "$(/opt/homebrew/bin/brew shellenv)"tmux is at /opt/homebrew/bin/tmux. Prebuilt bottles exist, so brew install tmux takes seconds.
eval "$(/usr/local/bin/brew shellenv)"tmux is at /usr/local/bin/tmux. Homebrew has stopped building bottles for Intel Macs (Intel macOS is a Tier 3, unsupported configuration, and Homebrew plans to drop it from September 2027 per its support tiers page). brew install tmux still works, but it compiles tmux and its libraries, which needs the Command Line Tools and takes a few minutes. MacPorts or the static binary avoid that.
Not sure which you have? Run uname -m: arm64 is Apple Silicon, x86_64 is Intel.
Upgrade tmux with Homebrew
brew update && brew upgrade tmux
tmux kill-server
tmux -VThe kill-server step matters. An upgrade replaces the file on disk, but a tmux server that is already running keeps running the old version, and a new client may refuse to talk to it with server exited unexpectedly or protocol version mismatch. Save your work, run tmux kill-server (this closes every session), then start tmux again. Why, and how to check which version your server runs →
To try unreleased changes, brew install --HEAD tmux builds the current master branch. It reports its version as next-3.9.
Install tmux with MacPorts
If you use MacPorts instead of Homebrew, tmux 3.8 is in the ports tree. MacPorts still supports Intel Macs fully.
sudo port selfupdate
sudo port install tmux
tmux -V
tmux 3.8MacPorts installs into /opt/local/bin; its installer adds that to your PATH. Upgrade later with sudo port selfupdate && sudo port upgrade tmux, then tmux kill-server. Pick one package manager for tmux: if both are installed, whichever comes first in your PATH wins, and which -a tmux shows every copy.
Download a ready-made tmux binary (no Homebrew)
The tmux project publishes ready-to-run binaries for macOS and Linux in a separate repository, github.com/tmux/tmux-builds. Each archive holds a single tmux file that needs nothing beyond a standard macOS install. This is handy on a locked-down Mac, a shared machine without admin rights, or an Intel Mac where Homebrew would compile. On 28 October 2026 the newest stable build there is 3.7c; 3.8 had not been published yet.
curl -LO https://github.com/tmux/tmux-builds/releases/download/v3.7c/tmux-3.7c-macos-arm64.tar.gz
tar -xzf tmux-3.7c-macos-arm64.tar.gz
mkdir -p ~/.local/bin && mv tmux ~/.local/bin/
~/.local/bin/tmux -V
tmux 3.7cAdd export PATH="$HOME/.local/bin:$PATH" to ~/.zprofile so tmux works on its own. If you downloaded the archive with a browser and macOS refuses to open the file, remove the quarantine flag with xattr -d com.apple.quarantine ~/.local/bin/tmux; curl downloads do not get that flag.
Build tmux from source on macOS
Build from source when you want a release before your package manager has it, a patched build, or the development branch. You need Apple's Command Line Tools, Homebrew (or MacPorts) for the libraries, and about a minute.
1. Install the compiler and libraries
xcode-select --installbrew install pkgconf libevent utf8proc jemallocThe tmux README lists the requirements: libevent 2.x, ncurses, a C compiler, make, pkg-config and a yacc (macOS ships bison, which works). macOS already includes ncurses. On macOS, tmux 3.8's configure also insists on a decision about two libraries: it uses utf8proc and jemalloc automatically when pkg-config finds them, and otherwise stops with must give --enable-utf8proc or --disable-utf8proc (and the same for jemalloc). Installing both, as above, is the right answer.
2. Download, build and install
curl -LO https://github.com/tmux/tmux/releases/download/3.8/tmux-3.8.tar.gz
tar -xzf tmux-3.8.tar.gz
cd tmux-3.8
./configure --enable-utf8proc --enable-jemalloc
make
sudo make install
/usr/local/bin/tmux -V
tmux 3.8make install puts tmux in /usr/local/bin and the man page in /usr/local/share/man. To install without sudo, run ./configure --enable-utf8proc --enable-jemalloc --prefix="$HOME/.local" and skip the sudo. If configure says "libevent not found", the pkg-config it found is not Homebrew's: check which pkg-config and your PATH. Static linking is not possible on macOS (--enable-static is refused).
Build the development version from Git
brew install autoconf automake
git clone https://github.com/tmux/tmux.git
cd tmux
sh autogen.sh
./configure --enable-utf8proc --enable-jemalloc && make
./tmux -V
tmux next-3.9Building from Git needs autoconf and automake on top of the libraries above, as the README says. We ran the same tarball and Git builds on Linux (where only the library names differ); see the Linux source build.
Set up tmux for macOS
tmux works out of the box, and since 3.8 the mouse is on by default. These are the macOS-specific things worth setting once.
Copy to the macOS clipboard
In iTerm2, Ghostty, kitty and WezTerm you usually need nothing: tmux's default set-clipboard external sends copied text to the terminal with an OSC 52 escape sequence and the terminal puts it on the clipboard. In iTerm2, turn on Settings → General → Selection → Applications in terminal may access clipboard first. If your terminal does not handle OSC 52 (Terminal.app historically has not), pipe copies to pbcopy instead:
# Every copy command in copy mode also goes to the macOS clipboard
set -s copy-command 'pbcopy'That one line covers mouse selection, Enter and the other default copy keys, because they all run copy-pipe-and-cancel, which uses copy-command. You do not need reattach-to-user-namespace any more: tmux 2.6 (2017) added the fix for clipboard access itself, so delete that wrapper from old configs. More in the copy mode clipboard guide.
Make Option work as Meta (Alt)
Bindings such as M-Left and word jumps in the shell need the Option key to send Meta. Terminal.app: Settings → Profiles → Keyboard → Use Option as Meta key. iTerm2: Settings → Profiles → Keys → Left Option key: Esc+. Ghostty: add macos-option-as-alt = true to its config.
True color
iTerm2, Ghostty, WezTerm, kitty and, since macOS 26 Tahoe, Terminal.app can show 24-bit color. If color themes in Neovim look washed out inside tmux, tell tmux your terminal supports RGB and restart the server:
set -as terminal-features ",xterm-256color:RGB"tmux 3.8 uses tmux-256color by default, and macOS 14 Sonoma and later include that terminfo entry. On older macOS, Homebrew's build defaults to screen-256color instead. Details in true color config.
iTerm2 control mode (tmux -CC)
tmux -CC new -A -s mainIn iTerm2, -CC turns tmux windows and panes into native iTerm2 tabs and splits, while the session still survives disconnects. new -A -s main attaches to the session main or creates it. Setup and caveats are in the iTerm2 + tmux guide; Ghostty users see Ghostty + tmux.
Start a tmux session when you log in (launchd)
Optional: have macOS start a detached session at login so tmux attach -t main always has something to attach to. Save this as ~/Library/LaunchAgents/app.tmux.session.plist and change the path to /usr/local/bin/tmux on Intel:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key><string>app.tmux.session</string>
<key>ProgramArguments</key>
<array>
<string>/opt/homebrew/bin/tmux</string>
<string>new-session</string><string>-d</string><string>-s</string><string>main</string>
</array>
<key>RunAtLoad</key><true/>
<key>AbandonProcessGroup</key><true/>
</dict>
</plist>launchctl bootstrap gui/$(id -u) ~/Library/LaunchAgents/app.tmux.session.plisttmux new-session -d starts the server and returns at once, and AbandonProcessGroup stops launchd from cleaning up the server when that first process exits. Remove it with launchctl bootout gui/$(id -u)/app.tmux.session. If you want your sessions back after a reboot too, use tmux-resurrect and tmux-continuum.
Troubleshooting tmux on macOS
zsh: command not found: tmux
tmux is installed but not on your PATH, which almost always means Homebrew's shell setup is missing. Add eval "$(/opt/homebrew/bin/brew shellenv)" (Apple Silicon) or eval "$(/usr/local/bin/brew shellenv)" (Intel) to ~/.zprofile and open a new terminal. brew list tmux tells you whether it is installed at all. More causes in PATH troubleshooting.
server exited unexpectedly or protocol version mismatch after brew upgrade
Your old tmux server is still running the previous version. Run tmux kill-server (this ends every session) and start tmux again. To check first, compare tmux -V (the client) with tmux display -p '#{version}' (the server). See upgrading tmux.
configure: error: must give --enable-utf8proc or --disable-utf8proc
tmux's build on macOS refuses to guess about Unicode support. Install utf8proc and jemalloc (brew install utf8proc jemalloc) and run ./configure --enable-utf8proc --enable-jemalloc. The same applies to the jemalloc error.
Copy and paste does not reach the macOS clipboard
In Terminal.app add set -s copy-command 'pbcopy' to ~/.tmux.conf and reload. In iTerm2, allow clipboard access (Settings → General → Selection). To paste the macOS clipboard into tmux, use Cmd+V as usual. With tmux 3.8's default mouse on, a drag selects inside tmux; to make a normal terminal selection instead, hold Option while dragging in iTerm2. More clipboard fixes.
Colors look wrong, or programs say 'tmux-256color': unknown terminal type
Programs inside tmux (less, vim, top) cannot find the tmux-256color terminfo entry, which macOS only includes from 14 Sonoma. Add set -g default-terminal "screen-256color" to ~/.tmux.conf and run tmux kill-server. For washed-out themes, add the terminal-features line from True color.
brew install tmux is slow or compiles everything
You are on an Intel Mac (or an old macOS) for which Homebrew no longer has prebuilt bottles, so it builds from source. Let it finish, or use MacPorts or the static binary.
How do I install tmux on macOS using Homebrew?
Open Terminal and run brew install tmux, then check it with tmux -V (it prints tmux 3.8). If brew is not found, install Homebrew from brew.sh first and run the two PATH lines it prints.
Does tmux work on a Mac?
Yes. macOS is one of the platforms the tmux project supports directly, on both Apple Silicon and Intel. It runs in any terminal app: Terminal, iTerm2, Ghostty, WezTerm, kitty or Alacritty.
How do I uninstall tmux on macOS?
Run tmux kill-server, then brew uninstall tmux (or sudo port uninstall tmux). For a source build, run sudo make uninstall in the source folder. Your ~/.tmux.conf stays until you delete it.
Next steps
Keep learning
Something wrong or out of date on this page? Email hello@tmux.app and we will fix it.