# history-file

Source: https://libtmux.org/en/tmux/latest/catalog/options/history-file/

> If not empty, a file to which tmux will write command prompt history on exit and load it from on start.

option tmux3.7c

If not empty, a file to which tmux will write command prompt history on exit and load it from on start.

* Scope

  server

* Type

  Text

* Set

  [`set-option`](https://libtmux.org/en/tmux/latest/manual/set-option/) `-s history-file value`

* Read

  [`show-options`](https://libtmux.org/en/tmux/latest/manual/show-options/) `-s history-file`

## Description[#](https://libtmux.org/en/tmux/latest/catalog/options/history-file/#description)

If not empty, a file to which `tmux` will write command prompt history on exit and load it from on start.

## Releases[#](https://libtmux.org/en/tmux/latest/catalog/options/history-file/#releases)

* [tmux 3.7c](https://libtmux.org/en/tmux/3.7c/catalog/options/history-file/) : present
* [tmux 3.2a](https://libtmux.org/en/tmux/3.2a/catalog/options/history-file/) : present

## Source[#](https://libtmux.org/en/tmux/latest/catalog/options/history-file/#source)

* Defined in

  [`options-table.c:426`](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/options-table.c#L426)

* C source reference

  [`options_table`](https://libtmux.org/en/tmux/latest/reference/c-variable-options_table/)

* CLI Manual

  [Original manual entry](https://libtmux.org/en/tmux/latest/manual/full/#options-history-file)

## Used by[#](https://libtmux.org/en/tmux/latest/catalog/options/history-file/#used-by)

Library documentation that names this option.

* Rust

  [`options.generated.HISTORY_FILE`](https://libtmux.org/en/rs/latest/reference/options-generated-history_file/)

* Go

  [`tmux.Server.SetHistoryFile`](https://libtmux.org/en/go/latest/reference/tmux-server-sethistoryfile/), [`tmux.ServerOptionValues.HistoryFile`](https://libtmux.org/en/go/latest/reference/tmux-serveroptionvalues-historyfile/)
