Skip to content

PyMdown Extensions

Overview

PyMdown Extensions is a collection of extensions for Python Markdown. They were originally written to make writing documentation more enjoyable. They cover a wide range of solutions, and while not every extension is needed by all people, there is usually at least one useful extension for everybody.

Usage

All extensions are found under the module namespace of pymdownx. Assuming we wanted to specify the use of the MagicLink extension, we would include it in Python Markdown like so:

>>> import markdown
>>> text = "A link https://google.com"
>>> html = markdown.markdown(text, extensions=['pymdownx.magiclink'])
'<p>A link <a href="https://google.com">https://google.com</a></p>'

Check out documentation on each extension to learn more about how to configure and use each one.

Reminder

Please read the Usage Notes for information on extension compatibility and general notes to be aware of when using these extensions.

Extensions

  Extensions  
Arithmatex B64 BetterEm
Blocks: Admonition Blocks: Caption Blocks: Definition
Blocks: Details Blocks: HTML Blocks: Tab
BracketSpan Caret Critic
Emoji EscapeAll Extra
FancyLists Highlight InlineHilite
Keys Legacy: Details Legacy: Tabbed
MagicLink Mark PathConverter
ProgressBar Quotes SaneHeaders
SmartSymbols Snippets StripHTML
SuperFences Tasklist Tilde