Skip to article frontmatterSkip to article content
Site not loading correctly?

This may be due to an incorrect BASE_URL configuration. See the MyST Documentation for reference.

JupyterBook

JupyterBookΒΆ


πŸ“¦ Installation & Setup

Install

pip install "jupyter-book<2"

Create a new book

jb create mybook

Build

jb build mybook
πŸ“ Project Structure
mybook/
  _config.yml
  _toc.yml
  intro.md
  chapter-1/
    index.md
πŸ“ Content Types

Markdown pages

intro.md
chapter-1/section.md

Notebooks

notebooks/example.ipynb

MyST directives

```{admonition} Title
:class: tip
Content
```
πŸ”§ _config.yml Reference
title: My Book
author: Your Name
logo: _static/logo.png
execute:
  execute_notebooks: auto
repository:
  url: https://github.com/user/repo
html:
  use_repository_button: true
πŸ—‚οΈ _toc.yml Reference
format: jb-book
root: intro
chapters:
  - file: chapter-1/index
    sections:
      - file: chapter-1/section
πŸ—οΈ Building & Previewing
jb build mybook
jb build mybook --all
python -m http.server -d mybook/_build/html 8000
πŸš€ Deployment (GitHub Pages)
jb build mybook
ghp-import -n -p -f mybook/_build/html