This implementation adds full Jupyter notebook support to the Zer0-Mistakes Jekyll theme with GitHub Pages compatibility. Notebooks are converted to Jekyll-compatible Markdown files during the build process, maintaining all formatting, code blocks, outputs, and mathematical equations.
✅ GitHub Pages Compatible - Uses pre-build conversion (no custom plugins)
✅ Automated Conversion - GitHub Actions workflow converts notebooks on push
✅ Manual Control - Makefile targets for local conversion
✅ Rich Content Support - Code, equations, plots, tables, and images
✅ Responsive Design - Bootstrap 5 styling with mobile-first layout
✅ SEO Optimized - Proper front matter and Schema.org markup
✅ MathJax Integration - LaTeX equation rendering (already configured)
docker/Dockerfile)scripts/convert-notebooks.sh).ipynb files to Jekyll Markdownassets/images/notebooks/_layouts/notebook.html)default.html layout_sass/notebooks.scss)_config.yml)make convert-notebooks - Convert all notebooksmake convert-notebooks-dry-run - Preview conversionmake convert-notebooks-force - Force reconvert allmake list-notebooks - List notebooks to convertmake clean-notebooks - Remove converted files.github/workflows/convert-notebooks.yml)Place your .ipynb file in pages/_notebooks/:
cp my-notebook.ipynb pages/_notebooks/
# Preview what will be converted
make convert-notebooks-dry-run
# Convert the notebook
make convert-notebooks
# Or use the script directly
./scripts/convert-notebooks.sh
The converted Markdown file appears at:
pages/_notebooks/my-notebook.mdExtracted images go to:
assets/images/notebooks/my-notebook_files/docker-compose down
docker-compose up --build
docker-compose exec jekyll ./scripts/convert-notebooks.sh
When you push .ipynb files to GitHub:
git add pages/_notebooks/my-notebook.ipynb
git commit -m "Add new notebook"
git push
To reconvert all notebooks (useful after styling changes):
# Locally
make convert-notebooks-force
# Via GitHub Actions (manual trigger)
# Go to Actions > Convert Jupyter Notebooks > Run workflow
# Enable "force_reconvert" option
Notebooks are converted with Jekyll front matter extracted from:
#Example generated front matter:
---
title: "My Notebook Title"
description: "Jupyter notebook"
layout: notebook
collection: notebooks
date: 2025-11-29T10:00:00.000Z
categories: [Notebooks]
tags: [jupyter, python]
comments: true
jupyter_metadata: true
lastmod: 2025-11-29T10:00:00.000Z
---
Edit _sass/notebooks.scss to customize:
Edit scripts/convert-notebooks.sh to modify:
Edit _layouts/notebook.html to change:
A sample notebook is included at pages/_notebooks/test-notebook.ipynb demonstrating:
To test the full pipeline:
make convert-notebooks
# View the converted file at pages/_notebooks/test-notebook.md
Check dependencies:
python3 --version
python3 -c "import nbconvert" && echo "✓ nbconvert installed"
Install if missing:
pip3 install jupyter nbconvert
Check image paths in converted Markdown:
grep -r "!\[" pages/_notebooks/*.md
Verify images exist:
ls -R assets/images/notebooks/
Fix paths if needed: The conversion script should use Jekyll-compatible paths:

Rebuild container with Python:
docker-compose down
docker-compose build --no-cache
docker-compose up
Check Python installation in container:
docker-compose exec jekyll python3 --version
docker-compose exec jekyll pip3 list | grep nbconvert
Check workflow triggers:
.ipynb files in pages/_notebooks/scripts/convert-notebooks.shManual trigger: Go to GitHub Actions > Convert Jupyter Notebooks > Run workflow
MathJax is already configured in _includes/core/head.html
If equations don’t render:
Potential improvements for future versions:
docker/Dockerfile (modified - added Python/nbconvert)scripts/convert-notebooks.sh_layouts/notebook.html_sass/notebooks.scss.github/workflows/convert-notebooks.ymlpages/_notebooks/test-notebook.ipynb (sample content added)docs/JUPYTER_NOTEBOOKS.md (this file)_sass/custom.scss (imported notebooks.scss)_config.yml (added notebooks collection defaults)Makefile (added notebook conversion targets)All components are in place for full Jupyter notebook support:
Next step: Push to GitHub to trigger the automated conversion workflow!
git add .
git commit -m "feat: add Jupyter notebook rendering support
- Add Python/nbconvert to Docker environment
- Create notebook conversion script with image extraction
- Add dedicated notebook layout extending default.html
- Implement notebook-specific SCSS styling
- Configure notebooks collection in Jekyll
- Add Makefile targets for manual conversion
- Set up GitHub Actions for automatic conversion
- Include test notebook with sample content
Supports GitHub Pages deployment via pre-build conversion"
git push origin main
Your implementation is working correctly if:
make convert-notebooks runs without errors.md files appear in pages/_notebooks/assets/images/notebooks/Congratulations! Your Jekyll site now supports Jupyter notebooks! 🎊