Themes
Pi supports fully customizable color themes. Themes control every color in the terminal UI.
Loading Locations
Themes are loaded from multiple locations, in order of precedence (later wins):
Set the active theme in settings:
Theme Structure
A theme is a JSON file with a name and 51 required color tokens organized under vars and colors:
The vars object defines reusable color variables. The colors object maps color tokens to values.
Color Token Categories
Core UI (11 tokens)
Backgrounds & Content (11 tokens)
Markdown (10 tokens)
Tool Diffs (3 tokens)
Syntax Highlighting (9 tokens)
Thinking Levels (6 tokens)
Bash Mode (1 token)
Color Formats
Color values support four formats:
Variable references allow you to define a color once in vars and reuse it across multiple tokens:
Hot Reload
Theme files are watched for changes during a session. When you edit and save a theme file, the changes are applied immediately without restarting Pi. This makes it easy to iterate on colors in real time.
Creating a Custom Theme
- Create a theme file in your global themes directory:
- Start with the built-in dark theme as a base and save it as a new file:
- Activate the theme in your settings:
- Adjust colors and save. Changes apply immediately via hot reload.
Use vars to define your palette, then reference variables with $name in colors. This makes it easy to adjust a single accent color and have it propagate throughout the theme.