IntelliJ IDEA 2019.1 Help

Jupyter Notebook Support

With Jupyter Notebook integration available in IntelliJ IDEA through the Python plugin, you can easily edit, execute, and debug notebook source code and examine execution outputs including stream data, images, and other media.

Notebook support in IntelliJ IDEA includes:

  • Editing and preview:

    • Ability to present a notebook as source code with textual cell definitions and manipulate cells as regular code.

    • Live preview of the cell execution output and Markdown content.

  • Coding assistance:

  • Ability to run cells and preview execution results.

  • Dedicated Jupyter Notebook Debugger.

  • Shortcuts for basic operations with Jupyter notebooks.

  • Ability to recognize .ipynb files and mark them with the ipynb file icon icon.

Get familiar with the user interface

In IntelliJ IDEA, you can work with Jupyter notebook files using three viewing modes:

In this mode, you can add notebook cells and edit them.

Editor only mode

In this mode, you can both edit cells and preview their output. This is the default viewing mode for Jupyter notebooks in IntelliJ IDEA.

Editor and preview mode

In this mode, you can preview markdown and raw cells as well as code cell execution results.

Preview only mode

Editing and preview modes reflect the currently selected IntelliJ IDEA user interface appearance.

The Jupyter notebook toolbar provides quick access to all basic operations with notebooks:

Jupyter toolbar

Toolbar element

Description

Scroll from source

Enables auto scrolling from the source cell in the Editor to the corresponding output in the Preview pane.

Scroll to source

Enables auto scrolling from the cell output in the Preview pane to the corresponding source cell in the Editor.

Show sources in preview

Click this icon to show source code fragments in the Preview pane.

List of Jupyter servers

The Jupyter Server widget that shows the currently used Jupyter server. Click the widget and select Configure Jupyter Server to setup another local or remote Jupyter server.

List of Jupyter kernels

List of the available Jupyter kernels.

Interrupt the kernel

Click this icon if you want to interrupt any cell execution.

Jupyter Quick List

Opens the Jupyter Quick List for easy access to the basic notebook operations:

Jupyter Quick List for Windows
Jupyter Quick List for Windows
Editor only viewing mode

Click this icon to switch into the editor only viewing mode.

Editor and preview viewing mode

Click this icon to show both Editor and the Preview pane.

Preview only mode

Click this icon to switch into the preview only mode.

The Server Log tab of the Jupyter tool window appears when you have any of the Jupyter server launched. The Server log tab of this window shows the current state of the Jupyter server and the link to the notebook in a browser.

Jupyter server tool window: the Server log tab

It also provides controls to stop the running server (Stop the server) and launch the stopped server (Run the server).

The Variables tab provides the detailed report about variable values of the executed cell.

Jupyter server tool window: the Variables tab

Quick start with the Jupyter notebook in IntelliJ IDEA

To start working with Jupyter notebooks in IntelliJ IDEA:

  1. Create a new project, specify a virtual environment, and install the jupyter package.

  2. Open or create an .ipynb file.

  3. Add and edit source cells.

  4. Execute any of the code cells to launch the Jupyter server.

  5. Analyze execution results in the Preview pane.

Refer to the following topics for more information about Jupyter Notebook support in IntelliJ IDEA:

Last modified: 20 June 2019

See Also