HTML to Markdown Converter
Paste HTML, get clean Markdown. Perfect for escaping a WYSIWYG editor or migrating into a docs-as-code workflow.
Turn HTML source into editable Markdown
The HTML-to-Markdown converter turns common semantic HTML into readable, diffable Markdown you can commit to Git, edit in a text editor, or move between platforms. It handles headings, paragraphs, lists, simple tables, blockquotes, code, links, images, and inline emphasis.
Conversion runs in your browser, so mdkit does not upload the HTML to a conversion server. This can be useful for internal CMS exports, knowledge-base migrations, and other documents you do not want to submit to an online conversion API.
The output is GitHub Flavored Markdown: GFM tables, fenced code blocks, task lists, and autolinks. You can paste it directly into a docs repo, a static site generator, or any modern Markdown editor.
HTML-to-Markdown example
Semantic headings, emphasis, and links map cleanly to their Markdown equivalents.
<h2>Setup</h2>
<p>Read the <strong>guide</strong> before you <a href="/start">begin</a>.</p>## Setup
Read the **guide** before you [begin](/start).How to use the HTML to Markdown Converter
- 1
Paste your HTML
Paste the HTML — from View Source, a CMS export, a pasted-rich-text clipboard, or anywhere else — into the left panel.
- 2
Review the Markdown
The right panel shows the converted Markdown. Check that headings, lists, and tables came through correctly.
- 3
Copy and review
Copy the Markdown into your editor or repository, then review complex tables, embeds, links, and images.
Limits to know before you publish
- CSS, page layout, forms, scripts, and most element attributes have no Markdown equivalent and are not preserved.
- Tables with merged cells, nested blocks, or multiple paragraphs usually need manual cleanup.
- Review relative links and image paths after moving content between sites.
Common use cases
- Migrating blog posts from a WordPress, Medium, or Ghost export into a Git-based docs workflow
- Converting Notion or Confluence HTML exports into plain Markdown notes
- Recovering documentation from a rendered web page when the original source is lost
- Cleaning up copy-pasted rich text that brought along bloated inline formatting
Frequently Asked Questions
What happens to inline styles and scripts?+
Will complex HTML tables convert cleanly?+
Does it preserve image paths?+
What about custom HTML elements like <kbd>, <details>, or <sup>?+
Is any HTML sent to a server?+
Related tools
Learn more
How to Convert HTML to Markdown: 5 Methods + Cleanup Tips
Convert HTML to Markdown with a browser tool, Turndown, Pandoc, or Python, then review tables, images, embeds, styles, and other lossy output.
Markdown vs HTML: Differences, Use Cases & Examples
Compare Markdown and HTML syntax, portability, rendering, security, accessibility, and use cases, with examples and a practical format decision table.
Markdown Cheat Sheet: Syntax, Examples & GFM Reference
Copy Markdown syntax for headings, lists, links, images, code, tables, and task lists, with clear CommonMark and GitHub Flavored Markdown labels.