
Catppuccin for Python
Install with pip or your preferred dependency management tool.
pip install catppuccin
For an API reference and usage examples, see our online documentation.
Install catppuccin[ipython] in the same environment as IPython, for example as a uv tool:
uv tool install ipython --with "catppuccin[ipython]"
or with pip:
pip install "catppuccin[ipython]"
If you don't have an IPython configuration file yet, create one with:
ipython profile create
Then add the following to your ipython_config.py:
c.TerminalInteractiveShell.true_color = True
c.TerminalInteractiveShell.colors = "catppuccin-mocha"You can also switch themes interactively with %colors catppuccin-latte.
Available IPython themes:
catppuccin-lattecatppuccin-frappecatppuccin-macchiatocatppuccin-mocha
Each theme also has a variant without italics, such as catppuccin-mocha:noitalic.
Important
This requires IPython 9.18 or newer.
IPython versions 9.0-9.17 are in a weird place where it requires an extension for the theme to work. I've chosen to skip that in the hope you can upgrade to 9.18 and use the new theme system. If you absolutely require support for these pre-9.18 versions, then open an issue explaining your situation and I will reconsider adding the extension as an option.
For IPython 8, install catppuccin[pygments] and use
c.TerminalInteractiveShell.highlighting_style = "catppuccin-mocha" instead.
If you are looking to contribute, please read through our CONTRIBUTING.md first!
This project is maintained with uv. If you don't have uv yet, you can install it using the installation instructions.
Install the project's dependencies including extras:
uv sync --all-extras
catppuccin/palette.py is generated by a build script based on the contents of palette.json.
To update after downloading a new palette JSON file:
uv run build.py
Formatting this file is done manually as with any other file, see Code Standards below.
All of the tools listed in this section are automatically installed by uv as
part of the dev dependency group.
Tests are run with pytest.
To run tests and display coverage:
pytest --cov catppuccin
Type checking is performed by mypy.
To run type checks:
mypy .
Code linting and formatting is done by ruff.
To lint the code:
ruff check
To format the code:
ruff format
Β
Copyright Β© 2022-present Catppuccin Org