Convert ipynb to HTML
Turn a Jupyter notebook into a single HTML file in your browser. Free, and the file never leaves your computer.
Your notebook starts here
Open a local file to preview its contents. No account needed.
or drop the notebook anywhere on this page
See the result first.
Your notebook, kept intact
An .ipynb file is JSON: a list of cells holding Markdown or code, plus the output each cell produced when it last ran. This converter renders all of it into one HTML document — same cells, same order, same outputs — with the stylesheet written into the file.
Markdown
Headings, lists, tables, images.
Code
Highlighted, in Python, R, Julia and more.
Math
LaTeX equations, rendered properly.
Plots
Charts, DataFrames, printed output.
How to convert a notebook to HTML
- 1
Pick your file
Choose a notebook, or drop it on the page. It works with notebooks saved from Jupyter, JupyterLab, Colab, Kaggle and VS Code.
- 2
Check it
The notebook is shown exactly as the HTML will look. Hide the code if you only want the write-up, then choose a full page or just the body.
- 3
Download HTML
One file, styles included, that opens in any browser. Or copy the markup and paste it into your own site.
Five ways to get HTML out of a notebook
HTML is the one export that never needed LaTeX, so every route works. The differences are what you have to install first, and what the file looks like at the end.
| Method | Needs installing | Hide code | One file | Images |
|---|---|---|---|---|
| This converter | Nothing | One switch | Yes, styles inline | Inside the file |
| nbconvert --to html | Python + nbconvert | --no-input flag | Yes | Inside the file since 6.5, beside it before |
| JupyterLab export | Jupyter | No | Yes | Inside the file |
| VS Code export | Jupyter extension + nbconvert | No | Yes | Inside the file |
| GitHub file view | Nothing | No | Not a file at all | Shown, not saved |
The command-line route, for when you have Python anyway:
jupyter nbconvert --to html notebook.ipynb
Add --no-input to drop the code cells. On nbconvert older than 6.5, add --embed-images or the plots are written into a folder beside the file.
What an HTML notebook is for
Send it to someone without Jupyter
An .html opens on any phone or laptop with a double-click. The reader sees the notebook the way you saw it, and never has to install Python.
Put it on a website
Choose Body only, paste the markup into a blog post, a wiki or a course page, and the notebook becomes part of it. It picks up your site's fonts.
Keep a copy that opens in ten years
HTML is the one format every device will keep reading. Outputs are frozen into the file exactly as they were when the notebook last ran.
Need it on paper instead? Convert the same notebook to PDF · Just view the .ipynb online
How it works, and why you can trust it
The whole converter is JavaScript running in this page. Markdown is rendered with markdown-it, code is highlighted with highlight.js, equations are typeset with KaTeX, and the result is sanitised with DOMPurify before it is shown or saved. There is no upload endpoint, so the file cannot leave your machine.
The HTML you download is the same markup you see in the preview, wrapped in a page with the stylesheet written inline. The source is on GitHub under the MIT licence.
Questions
- Is my notebook uploaded?
- No. The file is read and converted by JavaScript on your own computer. There is no server to send it to.
- Will the HTML file open without an internet connection?
- Yes. The stylesheet and every image are inside the file. The one exception is LaTeX maths: the equation fonts are loaded from a CDN, so a notebook with equations needs a connection the first time it is opened. Everything else works offline.
- Are the images inside the file?
- Yes. Plots and other images a notebook saved are stored in the .ipynb as base64 text, and they are written into the HTML the same way. Images that lived beside the notebook on disk cannot be reached and are marked with a note.
- Can I paste it into a blog or a wiki?
- Yes. Choose Body only and copy the HTML. You get the notebook markup without the page around it, so it sits inside your own template. It is plain HTML — headings, paragraphs, pre blocks and tables — with class names you can style.
- Can I leave the code out?
- Yes. Turn off the Code switch and the file shows only text and results, the same as nbconvert's --no-input.
- How is this different from nbconvert --to html?
- nbconvert needs Python installed, and its HTML reproduces the look of JupyterLab, prompts and all. This page needs nothing installed and produces a clean document made to be read, in one file. Both keep the outputs exactly as saved.
- Does it work with Google Colab notebooks?
- Yes. Download the notebook from Colab with File → Download → .ipynb and open it here. Outputs that were run in Colab are included.
- HTML or PDF — which should I choose?
- PDF for anything that will be printed, submitted or attached to an email. HTML when the reader will look at it on a screen: it scales to the window, the text can be selected and searched, and it is a fraction of the size. Both come from the same rendering on this site.
- What about Plotly charts and widgets?
- Anything that needs JavaScript to draw itself is not in the saved notebook, only a placeholder is. If a static image was saved alongside, that image is used. Otherwise a note is shown where the widget was.
- Is it free?
- Yes. No account, no watermark, no file limit. The code is open source under the MIT licence.