1. Home
  2. Writing & text tools
  3. reStructuredText to Markdown Converter

reStructuredText to Markdown Converter

Move a Python project’s README.rst or Sphinx documentation to Markdown for GitHub, MkDocs, Docusaurus or a static site, without installing Pandoc.

Free, no sign-up. Runs in your browser: nothing is uploaded.

How to use reStructuredText to Markdown Converter

  1. Paste or open the .rst file.
  2. Choose Markdown or HTML.
  3. Copy or download the result and read the notes.

Features

  • Section levels from the order adornments appear
  • Inline links, named and anonymous targets, substitutions
  • Literal blocks and code-block directives as fenced code
  • Admonitions as GitHub alerts; images, figures and footnotes
  • Grid, simple, list-table and csv-table tables

Supported formats

Input

  • RST
  • Typed or pasted text

You get

  • MD
  • HTML

Private by design

Everything you enter is processed by your browser on this device. Nothing is sent to openWorkstand or anyone else, so the reStructuredText to Markdown Converter is safe for private and work data. After you have used it once while online, it also works without an internet connection. How local processing works

Good to know

  • Sphinx autodoc, include and literalinclude need the project files and are dropped with a note.

Guide

Moving reStructuredText documentation to Markdown

reStructuredText is the markup behind Python’s documentation, Sphinx and Read the Docs, and many Python projects still ship a README.rst. Markdown is what GitHub, MkDocs, Docusaurus and most static site generators expect. Converting by hand is slow because the two languages express the same ideas differently. This converter handles the common constructs and tells you what it could not translate.

Headings and levels

reStructuredText has no fixed character for each heading level. A title can be underlined with =, -, ~ or many other characters, with or without an overline, and the level is decided by the order in which styles first appear in the file. The converter follows the same rule: the first style it meets becomes #, the second ##, and so on.

Inline links such as `Python <https://python.org>`_ become Python. Named targets defined anywhere in the file, like .. _API: https://example.com/api, are resolved so that API_ becomes a link. Anonymous links with double underscores, footnotes ([1]_ becomes a Markdown footnote) and substitutions such as |name| defined with replace or image are converted too.

Code and literal blocks

A paragraph ending in :: introduces a literal block, which becomes a fenced code block (“Example::” becomes “Example:”). Code-block and sourcecode directives keep their language, so python highlighting survives, and doctest blocks starting with >>> become Python code.

Directives

Notes, tips, warnings, important and caution blocks become GitHub alerts, such as > [!NOTE]. Images and figures become Markdown images, with figure captions in italics. Raw HTML is passed through. A contents directive becomes a toc marker that the Markdown TOC Generator can fill, and a toctree becomes a list of links to the .md files. Version-added and deprecated notes become italic sentences.

Tables

All four table types are converted to pipe tables: grid tables drawn with +—+, simple tables with ===== rules, list-tables and csv-tables. Cells spanning several columns cannot be expressed in Markdown and are kept in the first column they cover.

Sphinx roles

Inline code roles such as :func: and :class: become code spans, :math: becomes $…$, and :ref: and :doc: become ordinary links whose targets you may need to point at the right file. Unknown roles keep their text, and a note says so.

What is dropped

Directives that need the rest of the project — autodoc, include and literalinclude — cannot be followed in a single file; they are dropped or replaced with a comment, and listed in the notes under the output.

A worked example

The sample Quickstart page becomes # Quickstart with a fenced pip command, links to the user guide and API, a > [!NOTE] alert, a Python code block, a flag table and Author: Ana Souza from the field list.

Converting a whole documentation folder

Convert files one at a time and keep the same file names with .md extensions, so the links made from toctree and :doc: entries point to the right places. Then build the new site and follow its broken-link report; cross-references between files are the part most likely to need hand fixes.

Preview the Markdown as HTML with Markdown to HTML, edit it in the Markdown Editor, or convert pasted grid tables separately with the ASCII Table Converter.

Checked against the current version of the reStructuredText to Markdown Converter on .

Troubleshooting

The download did not start

Look for your browser’s download bar or icon. Some browsers ask once before a site may download files; allow it and click the button again.

Frequently asked questions

Why did my second-level headings become level one?

Levels follow the order styles first appear. If the document title uses an overline and underline, but another file starts directly with an underline-only heading, that style becomes level one there. Add the same title style at the top or adjust the # signs after converting.

Will GitHub show the admonitions as coloured boxes?

Yes. Notes, tips, warnings, important and caution blocks become GitHub alert syntax, which GitHub renders as coloured callouts. Other Markdown renderers show them as ordinary block quotes starting with the alert label.

What happens to definition lists?

They are written as a bold term followed by a line starting with a colon, the form Pandoc, PHP Markdown Extra and many site generators understand. GitHub does not support definition lists, so there they appear as plain lines.

How are heading levels decided?

reStructuredText has no fixed symbol for each level. The first underline style the converter meets becomes #, the second ##, and so on, exactly as docutils does it.

What happens to Sphinx-only features?

Cross-references such as :ref: and :doc: become ordinary links you may need to point at the right file. autodoc and include directives need the project source, so they are dropped with a note.

Keep working with the result

After you download, choose “Save to Workstand” to keep the result in a folder on your computer, attach it to a project and create a follow-up task. It is saved by your browser, not uploaded.