Custom themes in Notebook 7#

In Notebook 7, the way to create custom themes has changed. This means that custom themes developed for Notebook 6 or earlier will not work with Notebook 7 and upwards.

This is for example the case for community contributed themes such as jupyter-themes.

Using a custom theme#

Fortunately installing a custom theme for Notebook 7 is very easy. It is the same process as installing a regular extension.

For exampe let’s say you want to install the JupyterLab Night theme. You can do so by running the following command:

pip install jupyterlab-night

Then refresh the page and you should see the new theme available in the settings menu:

a screencast showing how to install a custom theme

There are already many themes available on PyPI.

You can also find other themes using the jupyterlab-theme topic on GitHub:

For example:

Creating a custom theme#

Creating a custom theme for Notebook 7 follows the same process as creating a custom theme for JupyterLab 4.

See the Frontend Extension Guide to get you started. When creating the extension, select the Theme option in the cookiecutter prompt.