Jupyter paths and configuration#
Configuration files are usually stored in the ~/.jupyter directory.
However, another directory can be specified with the environment variable
JUPYTER_CONFIG_DIR. If Jupyter cannot find a configuration in
JUPYTER_CONFIG_DIR, Jupyter runs through the search path with
/SYS.PREFIX/etc/jupyter/ and then for Unix
/usr/local/etc/jupyter/ and /etc/jupyter/, for Windows
%PROGRAMDATA%\jupyter\.
You can have the currently used configuration directories listed with:
$ jupyter --paths
config:
    /Users/veit/.jupyter
    /Users/veit/.local/share/virtualenvs/jupyter-tutorial--q5BvmfG/bin/../etc/jupyter
    /usr/local/etc/jupyter
    /etc/jupyter
...
Create the configuration files#
You can create a standard configuration with:
$ jupyter notebook --generate-config
Writing default config to: /Users/veit/.jupyter/jupyter_notebook_config.py
More generally, configuration files can be created for all Jupyter applications
with jupyter APPLICATION --generate-config.
Change the configuration#
… by editing the configuration file#
e.g. in jupyter_notebook_config.py:
c.NotebookApp.port = 8754
If the values are saved as list, dict or set, they can also be
supplemented with  append, extend, prepend, add and
update, e.g.:
c.TemplateExporter.template_path.append('./templates')
… with the command line#
for example:
$ jupyter notebook --NotebookApp.port=8754
There are aliases for frequently used options such as for --port or
--no-browser.
The command line options override options set in a configuration file.
See also