A fast yet powerful Python Markdown parser with renderers and plugins.
[](https://github.com/lepture/mistune/actions)
[](https://pypi.org/project/mistune)
[](https://anaconda.org/conda-forge/mistune)
[](https://pepy.tech/projects/mistune)
[](https://codecov.io/gh/lepture/mistune)
[](https://sonarcloud.io/summary/new_code?id=lepture_mistune)
[](https://sonarcloud.io/summary/new_code?id=lepture_mistune)
> [!NOTE]
>
> I’ve released [Wenmode](https://github.com/lepture/wenmode), a new Markdown parser inspired by the lessons learned from Mistune.
>
> Wenmode focuses on fast CommonMark-style parsing, explicit rule composition, mdast-compatible AST output, safe HTML defaults, streaming output, and pluggable renderers.
>
> In the current benchmark suite, Wenmode’s core Markdown-to-HTML path is about 1.5-1.8x as fast as Mistune across the tested documentation corpora. See the [benchmark results](https://wenmode.lepture.com/benchmarks/) for the exact setup and numbers.
Check [benchmark results for Wenmode](https://github.com/lepture/wenmode#benchmark).
## Install
To install mistune:
```
$ pip install mistune
```
## Overview
Convert Markdown to HTML with ease:
```python
import mistune
mistune.html(your_markdown_text)
```
## Security Reporting
If you found security bugs, please do not send a public issue or patch.
You can send me email at