How to disable password request for a Jupyter notebook session?

The following is very unsafe, but you can remove the password completely with:

jupyter notebook --ip='*' --NotebookApp.token='' --NotebookApp.password=''

Without --NotebookApp.password='', when connecting from a remote computer to a local Jupyter launched simply with:

jupyter notebook --ip='*'

it still asks for a password for security reasons, since users with access can run arbitrary Python code on the server machine!

Note that on my machine, running just:

jupyter notebook

already opens a logged-in window on my browser, and stdout contains:

    To access the notebook, open this file in a browser:
        file:///home/ciro/.local/share/jupyter/runtime/nbserver-3286-open.html
    Or copy and paste one of these URLs:
        http://localhost:8888/?token=7c9265bf9df5f57cf5da88f410a71b097e2548ae375826b7
     or http://127.0.0.1:8888/?token=7c9265bf9df5f57cf5da88f410a71b097e2548ae375826b7

so if your browser is not opening automatically, you can try one of those links, which seem to have a login token on them, and then investigate why your browser is not opening automatically.

Tested on Jupyter 4.4.x, Ubuntu 18.04.

Leave a Comment