Ghostty Cheatsheet

Configuration File

Use this Ghostty reference while you build software engineering projects, review code, or refresh the syntax you reach for most.

Syntax

One key = value per line. Whitespace around = is ignored, comments are # on their own line, and blank lines are ignored.

# Comments must be on their own line, not trailing.
background = 282c34
foreground = ffffff
font-family = "JetBrains Mono"

# An empty value resets the key to its default.
font-family =

- Keys are case sensitive and always lowercase. Background is not background. - Quotes are optional. font-family = "JetBrains Mono" equals font-family = JetBrains Mono. - Repeatable keys (font-family, font-feature, keybind, config-file, env) append. To replace instead of append, set key = "" first, then set the value. - Every key is also a CLI flag: ghostty --background=282c34. - Values set on the CLI automatically clear values from config files for repeatable keys, so you do not need --font-family="" first.

File locations and load order

$XDG_CONFIG_HOME/ghostty/config.ghostty
$XDG_CONFIG_HOME/ghostty/config
~/Library/Application Support/com.mitchellh.ghostty/config.ghostty   (macOS)
~/Library/Application Support/com.mitchellh.ghostty/config           (macOS)

All existing files load in that order and later values win. config.ghostty is the name since 1.2.3, config is the older name and still works.

Splitting across files

config-file pulls in another file. Paths are relative to the file that contains the directive, or to the current directory for a CLI flag. A ? prefix makes the file optional.

config-file = colors.ghostty
config-file = ?local.ghostty          # ignored if missing
config-file = "?literal-question.conf" # quote to keep a literal ?

config-file entries are processed at the end of the current file, so keys in the included file override keys set before it. This is the opposite of how theme files work, which load first and lose to your own settings.

Cycles are detected and produce a warning. config-default-files = false is a CLI-only flag that skips the default paths entirely.

Options people actually set

KeyDefaultNotes
font-familyembedded JetBrains Monorepeatable, later entries are fallbacks
font-sizeplatform defaultpoints, non-integer allowed
font-feature—-calt disables programming ligatures
themenonebuilt-in name, custom name, or absolute path
background282c34#RRGGBB, RRGGBB, or an X11 color name
foregroundffffffsame formats
background-opacity1.00–1
background-blurfalsetrue, false, macos-glass-regular, macos-glass-clear, or a radius
window-padding-x2one value, or left,right
window-padding-y2one value, or top,bottom
cursor-styleblockblock, bar, underline, block_hollow
cursor-style-blinkunsetunset respects DEC mode 12
scrollback-limit10000000bytes, so 10MB, not lines
scrollbarsystemor never
mouse-hide-while-typingfalse
copy-on-selecttrueor false, or clipboard
confirm-close-surfacetrueor false, or always
shell-integrationdetectnone, detect, bash, elvish, fish, nushell, zsh
macos-option-as-altunsettrue, false, left, right
macos-titlebar-styletransparentnative, transparent, tabs, hidden
window-decorationautoauto, client, server, none
unfocused-split-opacity0.71 disables the dimming
link-urltruecmd or ctrl hover to open URLs
clipboard-paste-protectiontruewarns on unsafe pastes

Reload and inspect

# Reload at runtime: cmd+shift+, on macOS, ctrl+shift+, on Linux
# or bind it yourself:
#   keybind = ctrl+alt+r=reload_config

ghostty +show-config                  # your resolved config, changes only
ghostty +show-config --default --docs # every option with its doc comment
ghostty +validate-config              # parse errors and diagnostics
ghostty +edit-config                  # open in the configured editor

+show-config defaults to --changes-only=true. Blank entries such as font-family = in its output mean the key is defaulting, which is valid syntax and exists so a doc comment has something to attach to.

Offline reference

The full option reference ships with every install, generated from the same source as the website.

WherePath
Markdown and HTML$prefix/share/ghostty/docs
Man pages$prefix/share/man
CLIghostty +show-config --default --docs
Sourcesrc/config/Config.zig in the repo

On macOS $prefix is Ghostty.app/Contents/Resources. Built from source it is zig-out, or whatever you passed to --prefix.