Jupyter Notebook Usage
In the previous chapter, we completed the installation of Jupyter Notebook.
After installation, let's start it immediately and see what this smart notebook looks like.
### 1. Starting Jupyter Notebook
First, in the command line, switch to the directory where you want to store your future notebook project files. For example, you want to work in the `my_jupyter` folder on your desktop:
# Windows Example cd C:\Users\YourUsername\Desktop\my_jupyter # macOS/Linux Example cd ~/Desktop/my_jupyter
Then, enter the startup command:
jupyter notebook
After pressing Enter, two things will happen:
The command line window will start running a server (do not close this window).
!(https://example.com/wp-content/uploads/2026/01/f79223e4-9cb5-43da-b132-6376e5c2d67f.png)
Your default web browser (like Chrome, Firefox) will automatically open a new page, usually at the address `http://localhost:8888`, which is the **Jupyter Notebook Dashboard**.
!(https://example.com/wp-content/uploads/2026/01/jupyter-install-tutorial-1.png)
At this point, you can click File -> New -> Notebook to create a notebook:
!(https://example.com/wp-content/uploads/2026/01/f8594e58-089c-44ac-9a9d-40c3145a80e1.png%22)
You can also use the following method.
### 2. Creating Your First Notebook
In the opened browser page (Dashboard):
* Click the **New** button in the upper right corner of the page.
* Select **Python 3 (ipykernel)** from the dropdown menu.
!(https://example.com/wp-content/uploads/2026/01/jupyter-install-tutorial-2.png)
* At this point, a new browser tab will open, which is a brand new, blank **Notebook document**.
!(https://example.com/wp-content/uploads/2026/01/jupyter-install-tutorial-3.png)
### 3. Writing and Running Your First Code
What you see now is a cell, which is the core of the Notebook.
* In the first cell, enter:
print("Hello, Jupyter! I am from Tutorial!")
* Press `Shift + Enter` to run this cell.
!(https://example.com/wp-content/uploads/2026/01/jupyter-install-tutorial-4.png)
You will immediately see the output `Hello, Jupyter! I am from Tutorial!` below the cell, and the interface will automatically create a second blank cell for you.
!(https://example.com/wp-content/uploads/2026/01/jupyter-install-tutorial-5.png)
After completion, a new cell will be generated. Paste the following code into it:
## Example
# This is a code cell
print("Hello, Jupyter!")
print("1 + 2 =",1 + 2)
# Try running this cell (Shift+Enter) and see the result!
**Expected Run Result**:
Hello, Jupyter!1 + 2 = 3
!(https://example.com/wp-content/uploads/2026/01/jupyter-install-tutorial-6.png)
### 4. Understanding Cell Types
Cells have two main modes (switchable via the toolbar dropdown menu):
* **Code**: Used for writing and executing code (default).
* **Markdown**: Used for writing formatted text descriptions. For example, you can enter `# This is a title`, then run it (Shift+Enter), and it will be displayed as a large heading.
!(https://example.com/wp-content/uploads/2026/01/jupyter-install-tutorial-7.png)
Try changing the type of a new cell to **Markdown**, then enter `## This is my data analysis project`, run it and see the effect.
!(https://example.com/wp-content/uploads/2026/01/jupyter-install-tutorial-8.png)
### 5. Saving and Closing
* **Saving**: The Notebook will automatically save periodically. You can also click the **Save icon** (floppy disk shape) on the toolbar to save manually. Your notebook will be saved as a file with the extension `.ipynb`.
* **Closing**: Simply close the browser tab to close the notebook. To **stop the entire Jupyter service**, go back to the initial command line window, press `Ctrl + C` twice, and then confirm the shutdown according to the prompt.
!(https://example.com/wp-content/uploads/2026/01/jupyter-install-tutorial-9.png)
YouTip