Skip to content
Tutorials Center
My learning

Topics

Lesson 1 of 39 ยท Getting Started

What Is Jupyter?

Learn what Jupyter is, how notebooks mix code, text and results, what the Jupyter project includes, and when a notebook is the right tool for your work.

A Jupyter notebook is a document that holds live code, the results of running that code, and the explanation around it, all in one place. You write a few lines, run them, see a number or a chart appear right below, then write a paragraph of text about what you found. Because code, output and prose live together, a notebook reads like a lab journal that you can also re-run.

Jupyter started in 2014 as a spin-off from IPython, an interactive Python shell. The name is a nod to the three languages it first supported: Julia, Python and R. Today it works with dozens of languages, but Python remains by far the most common.

About this track. The Jupyter software itself is a program you install on your computer or use in a hosted service. It cannot run inside this website. So this course describes menus, commands and file formats precisely, and every runnable example here is a small Python stand-in that demonstrates the same idea (for example, how a notebook file is structured, or how cell execution order changes results). We never show real Jupyter output that we cannot guarantee; stand-ins are always labelled.

The idea: literate, interactive computing

Normal programs are written, saved and run top to bottom. A notebook works differently:

  1. You break the work into small cells.
  2. You run one cell at a time and look at the result immediately.
  3. The program's variables stay in memory between cells, so later cells can use earlier results.
  4. You mix Markdown text cells in between to explain what you are doing.

This loop of write, run, look, adjust is called exploratory programming. It is perfect when you do not yet know what the answer looks like: cleaning an unfamiliar dataset, trying a model, learning a library, or teaching a class.

What lives in a notebook

Code cells Run Python or another language
Text cells Explain with Markdown
Outputs Tables, charts, images

One file holds the whole story.

1 / 3

The pieces of the Jupyter project

"Jupyter" is not one program but a family of parts that work together:

Part What it is
Jupyter Notebook The classic browser app for opening and editing .ipynb files.
JupyterLab A newer, more flexible interface with tabs, a file browser, a terminal and extensions.
Kernel A separate process that actually runs your code (for example ipykernel for Python).
Jupyter Server The program that connects your browser to files and kernels.
nbformat The specification of the .ipynb file format.
nbconvert A tool that turns notebooks into HTML, PDF, scripts and slides.
JupyterHub A multi-user server that gives each person their own notebook environment.
Binder, Colab, and others Hosted services that run notebooks in the cloud for you.

The most important idea is the split between the front end (what you see in the browser) and the kernel (the engine that runs code). You will study it in detail in Kernels explained.

flowchart LR
    B["Browser: Notebook or JupyterLab"] <-->|"HTTP and WebSocket"| S["Jupyter Server"]
    S <-->|"messages"| K["Kernel (Python, R, Julia...)"]
    S <--> F[("Files: .ipynb, data")]

The browser never runs your code itself: it sends it to the kernel through the server and shows what comes back.

A notebook is just a file

A notebook is saved as a plain text file with the extension .ipynb, written in JSON. You can email it, put it under version control, or open it in a text editor. The code lives in it, and so do the outputs from the last run, including small images stored as text. We will look inside one in The .ipynb file format.

Here is a stand-in that builds the smallest possible notebook by hand and prints its structure. This is real notebook-format JSON, produced by plain Python:

Python Stand-in: the smallest notebook, built by hand

Press Run (or Ctrl + Enter) to see the result here.

Program input ยท what you'd type while the program runs

Type the answers before you press Run, one per line. Each time the program reads a line (with input()), it gets the next line from this box.

When a notebook is the right tool

Notebooks shine when:

  • you explore data and want to see each step's result;
  • you want to explain an analysis to someone who will read and re-run it;
  • you teach or learn, and want runnable examples next to the theory;
  • you prototype an idea before turning it into a proper program.

They are a weaker fit when you build a large application, need strict tests and a clean module structure, or must run a job on a schedule without a human. Good teams use notebooks for exploration and move stable code into regular Python files. Do not worry about that yet: first learn to use the tool.

Your first mental model: shared state

The single most important thing to understand early is that all code cells share one running program. A variable defined in cell 1 is visible in cell 5, and it stays until the kernel stops. The following stand-in imitates this by running "cells" as strings inside one shared namespace:

Python Stand-in: cells share one namespace

Press Run (or Ctrl + Enter) to see the result here.

Program input ยท what you'd type while the program runs

Type the answers before you press Run, one per line. Each time the program reads a line (with input()), it gets the next line from this box.

Each cell on its own is tiny, yet the third one uses names created by the first two. That is exactly how a real kernel behaves, and it explains both the power and the main danger of notebooks (see Execution order and hidden state).

Check your understanding

Quick check ยท 4 questions

of 4 answered You scored / 4 ยท perfect!

  1. 1. What does a Jupyter notebook combine in a single document?

    Notebooks hold code cells, the results of running them, and Markdown text, so analysis and explanation sit together.
  2. 2. Which part of Jupyter actually executes your code?

    The kernel is a separate process that runs code and sends results back. The browser is only the user interface.
  3. 3. What kind of file is an .ipynb notebook?

    A notebook is JSON text that stores cells, outputs and metadata, which is why it can be versioned and inspected.
  4. 4. Where is a notebook usually a weaker choice?

    Large applications need modules, tests and predictable execution, which notebooks do not enforce well.

Summary

  • A Jupyter notebook mixes code, output and Markdown text in one document.
  • The name comes from Julia, Python and R, though many languages are supported.
  • The browser is the front end; a separate kernel runs your code.
  • Notebooks are JSON files with the extension .ipynb.
  • All code cells share one running program, so earlier cells affect later ones.
  • Notebooks are great for exploration and communication, less so for big applications.

Next: Installing and launching Jupyter