> For the complete documentation index, see [llms.txt](https://docs.consoleflare.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.consoleflare.com/live-data-streaming/master/jupyter-notebook-setup.md).

# Jupyter Notebook Setup

In this guide you will see how to setup jupyter notebook as a default editor for PySpark

After completing the Spark installation in order to set jupyter notebook as the default editor we need to the following steps:

### Step 1 (install jupyter notebook)

Open CMD and use the following command to install jupyter notebook

```bash
pip install jupyter
```

### Step 2 (set environment variables)

create the following environment variables:

**PYSPARK\_PYTHON** = {path of your python.exe}

![](https://2978144431-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MhK79F6MpCuBt1OHFCP%2Fuploads%2FiA6573tUMon9Lx7kDj5l%2Fimage.png?alt=media\&token=fb30f591-0d37-48c2-8c22-356898c1ed42)

**PYSPARK\_DRIVER*****\_*****PYTHON** = jupyter

![](https://2978144431-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MhK79F6MpCuBt1OHFCP%2Fuploads%2FUYbZMZH1EpM6KaPrOhwn%2Fimage.png?alt=media\&token=9093b1b4-5d7e-43b2-bc90-e086576a11f7)

**PYSPARK\_DRIVER\_PYTHON\_OPTS** = 'notebook'

![](https://2978144431-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MhK79F6MpCuBt1OHFCP%2Fuploads%2F4d5mhhZotoDsZUPaCNI2%2Fimage.png?alt=media\&token=1718c3c3-4dc0-40eb-8cb6-5a0e5926e846)

That's it!

*You can verify if your setup was successful by typing the following command on cmd*

```bash
pyspark
```

*This should open jupyter notebook in your default browser.*
