Skip to main content

Notion Markdown Exporter with Python Cli

Project description

Notion2Md logo - an arrow pointing from "N" to "MD"

About Notion2Md

PyPI version Code Quality

  • Notion Markdown Exporter using official notion api by notion-sdk-py


  • Check out Notion2Medium that publishes a Medium post from Notion using Notion2Md.

API Key(Token)

$ export NOTION_TOKEN="{your integration token key}"


$ pip install notion2md

Usage: Shell Command

Terminal output of the notion2md -h command

  • Notion2md requires either id or url of the Notion page/block.

  • download option will download files/images in the path directory.

  • unzipped option makes Notion2Md export unzipped output of Notion block.

notion2md --download -n post -p ~/MyBlog/content/posts -u
  • This command will generate "" in your '~/MyBlog/content/posts' directory.

Usage: Python

from notion2md.exporter.block import MarkdownExporter, StringExporter

# MarkdownExporter will make markdown file on your output path

# StringExporter will return output as String type
md = StringExporter(page_id='...',output_path='...').export()


  • Download file object(image and files)
  • Table blocks
  • Synced Block
  • Page Exporter
  • Child page
  • Column List and Column Blocks


Please read Contribution Guide


If you think Notion2Md is helpful to you, you can support me here:

Buy Me A Coffee



Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

notion2md-2.8.0.tar.gz (12.1 kB view hashes)

Uploaded Source

Built Distribution

notion2md-2.8.0-py3-none-any.whl (14.1 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page