Skip to main content
MuxTab and Tab refer to the same object. See the Tab Object documentation for the complete API reference.
The MuxTab object represents a tab managed by the WezTerm multiplexer. This is the same object as the Tab object in these documentation pages.

Common Methods

Here are some of the most commonly used methods:
  • tab:tab_id() - Get the tab’s unique identifier
  • tab:window() - Get the containing window
  • tab:active_pane() - Get the active pane
  • tab:panes() - Get all panes in the tab
  • tab:panes_with_info() - Get panes with layout information

Title Management

  • tab:get_title() - Get the tab title
  • tab:set_title(title) - Set the tab title

Layout Control

  • tab:set_zoomed(zoomed) - Zoom or unzoom the active pane
  • tab:get_size() - Get the tab dimensions
  • tab:rotate_clockwise() - Rotate panes clockwise
  • tab:rotate_counter_clockwise() - Rotate panes counter-clockwise

Activation

  • tab:activate() - Make this tab active

Example Usage

local wezterm = require 'wezterm'

wezterm.on('update-status', function(window, pane)
  local tab = pane:tab()
  if tab then
    local panes = tab:panes()
    local title = string.format('%s [%d]', tab:get_title(), #panes)
    window:set_right_status(title)
  end
end)
For complete documentation of all methods and properties, see the Tab Object page.