Configuration File
Ghostty uses a simple text-based configuration format. The configuration file is located at:- Linux/BSD:
$XDG_CONFIG_HOME/ghostty/configor~/.config/ghostty/config - macOS:
~/.config/ghostty/config
The configuration file uses a simple
key = value format. Lines starting with # are comments.Basic Configuration Structure
Loading Configuration
Default Configuration Files
By default, Ghostty loads configuration from the XDG config path:Additional Configuration Files
Use theconfig-file directive to load additional configuration:
How do I prevent errors if a config file doesn't exist?
How do I prevent errors if a config file doesn't exist?
Prepend a
? character to suppress errors:What order are config files loaded?
What order are config files loaded?
Configuration files are loaded after the configuration they’re defined in. Later values override earlier ones.
Validating Configuration
Validate your configuration without starting Ghostty:Viewing Current Configuration
Show all currently active configuration values:Reloading Configuration
Ghostty supports runtime configuration reloading for most settings.Via Keybinding
The default keybind is:- macOS
- Linux/BSD
cmd+comma or use the reload_config actionWhat Can Be Reloaded?
Most configuration options can be reloaded at runtime. Options that cannot be reloaded are noted in their documentation.
- Colors and themes
- Font settings (for terminals that haven’t manually adjusted font size)
- Keybindings
- Window padding
- Custom shaders
language(requires full restart)background-opacityon macOS (requires full restart)- Window decoration changes (applies to new windows only)
CLI Arguments vs Config File
CLI arguments override config file settings:Special CLI Syntax
Some configurations have special CLI shortcuts:Configuration Commands
Ghostty provides several+ commands for working with configuration:
| Command | Description |
|---|---|
ghostty +validate-config | Check configuration for errors |
ghostty +show-config | Display all active configuration |
ghostty +list-fonts | List available fonts |
ghostty +list-themes | List available themes |
ghostty +list-actions | List all keybind actions |
ghostty +list-keybinds | Show all configured keybinds |
How do I check what keybinds are currently active?
How do I check what keybinds are currently active?
Configuration Organization
For complex setups, organize configuration into multiple files:Platform-Specific Configuration
Some options only apply to specific platforms:Platform-specific options are silently ignored on unsupported platforms.
Conditional Configuration
While Ghostty doesn’t have built-in conditionals, you can use separate config files per platform:Next Steps
Appearance
Configure colors, themes, and visual styles
Fonts
Set up fonts and typography
Keybindings
Customize keyboard shortcuts
Window Settings
Control window behavior and decorations