jupytext
Jupyter notebooks as Markdown documents, Julia, Python or R scripts
What it is and what it does
Jupytext bridges the gap between Jupyter notebooks and plain-text development workflows by allowing notebooks to be stored and edited as regular Python scripts, Markdown files, or other text formats. It reads `.ipynb` files and converts them to formats like `.py` (percent-format) or `.md` (Markdown-based), and vice versa, preserving cell structure and metadata. The tool integrates with JupyterLab as an extension, making text-format notebooks appear and behave like regular notebooks in the interface.
The package enables two main workflows: text-only notebooks (inputs only, no outputs) for clean version control and IDE editing, and paired notebooks (simultaneous `.ipynb` and `.py` or `.md` files) that preserve outputs while allowing text-based collaboration. It includes command-line tools for batch conversion, synchronization, and piping notebooks through linters. Dependencies are lightweight—markdown-it-py, mdit-py-plugins, nbformat, packaging, pyyaml, and tomli—and the package supports Python 3.9 through 3.14.
Use it for:
- Store Jupyter notebooks in Git with meaningful diffs by pairing `.ipynb` with `.py` or `.md` and committing only the text version.
- Edit notebook code in your IDE (VS Code, PyCharm, etc.) as a regular Python script, then reload it in Jupyter to see outputs.
- Collaborate on notebooks via Git pull requests, where each collaborator can review and merge text-format changes without output noise.
- Convert existing `.ipynb` notebooks to `.py` or `.md` format for archival, documentation, or integration into a code repository.
- Automate notebook-to-script conversion in CI/CD pipelines using the command-line interface.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Jupytext converts Jupyter notebooks to and from plain-text formats (Python scripts, Markdown, or other text files) while preserving notebook structure, enabling version control and IDE editing of notebook content.
Yes. Jupytext is actively maintained, has no known vulnerabilities, and solves a real problem for teams wanting to version-control notebooks and edit them in IDEs. Install it if you work with Jupyter and Git together, or need to treat notebooks as code. The low dependency count and permissive MIT license make it a safe addition to any Python environment.
Install
jupytext on PyPI
pip
pip install jupytextuv
uv add jupytextpoetry
poetry add jupytextInstalling jupytext
Before you install
Low friction install with six straightforward dependencies (markdown-it-py, mdit-py-plugins, nbformat, packaging, pyyaml, tomli). Active maintenance with a recent release (24 days ago) and 7228 repository stars.
License in practice
MIT License permits unrestricted use, modification, and distribution with minimal restrictions—suitable for both open-source and commercial projects.
Quickstart
pip install jupytext
import jupytext
notebook = jupytext.read('notebook.ipynb')
jupytext.write(notebook, 'notebook.py')
Requires JupyterLab or Jupyter to be installed in the same Python environment; command-line usage also available without Jupyter.
Verify before relying
- Whether paired notebook sync handles merge conflicts automatically or requires manual intervention beyond the described pop-up prompts.
- Performance characteristics when working with very large notebooks or many paired files.
- Compatibility with notebook extensions other than the Jupyter Collaboration extension mentioned.
Package facts
| License | MIT License Copyright (c) 2018-2026 Marc Wouts Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to… (full text in the JSON record) (permissive) |
| Python support | supports the current Python release (>=3.9) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 6 — markdown-it-py, mdit-py-plugins, nbformat, packaging, pyyaml, tomli |
| Maintenance | actively maintained — 24 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 4,100,699/month — #2,380 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: jupytext-1.19.5-py3-none-any.whl
Tags
More Markup packages
PyYAML parses and emits YAML 1.1 data format,…
permissive · top 100 on PyPI
markdown-it-pyA Python markdown parser that converts markdown…
permissive · top 100 on PyPI
beautifulsoup4Beautiful Soup parses HTML and XML documents…
permissive · top 100 on PyPI
et-xmlfileet_xmlfile writes large XML files with minimal…
permissive · top 1,000 on PyPI
tomlkitParses and edits TOML files while preserving…
permissive · top 1,000 on PyPI
docstring-parserParses Python docstrings in ReST, Google,…
permissive · top 1,000 on PyPI
mkdocs-jupyterConverts Jupyter notebooks and Python scripts…
permissive · top 15,000 on PyPI
nb-cleannb-clean removes execution counts, metadata,…
permissive · top 15,000 on PyPI
nbconvertnbconvert converts Jupyter notebooks (.ipynb…
permissive · top 1,000 on PyPI
nbqaRuns standard Python linters and formatters…
permissive · top 15,000 on PyPI
nbstripoutStrips output cells and metadata from Jupyter…
permissive · top 5,000 on PyPI
myst-nbSphinx extension that parses and converts…
unclear · top 5,000 on PyPI
jupyter-collaborationAdds real-time collaborative editing to…
permissive · top 15,000 on PyPI
jupyter-docproviderAdds real-time collaborative editing to…
permissive · top 15,000 on PyPI
session-infoOutputs version information for all modules…
permissive · top 15,000 on PyPI
session-info2Captures and displays the versions of all…
copyleft · top 5,000 on PyPI