Markdown

HTML

Preview

A two-way converter between Markdown and HTML. In "Markdown → HTML" mode it turns headings, paragraphs, bold/italic, links, images, nested bullet and numbered lists, blockquotes, fenced code blocks and GFM pipe tables into clean HTML. Every heading gets an anchor id automatically, and one click inserts a nested table of contents (TOC) at the top of the document — so building a TOC for a blog post, README or internal doc takes seconds. The HTML source appears instantly on the right, and a live preview below shows how it actually renders. In "HTML → Markdown" mode you can paste the body HTML from an existing web page or CMS and convert headings, lists, links, tables and quotes back into Markdown — handy when moving content from a CMS into a GitHub README, or from exported HTML into Markdown. The input updates live as you type and the output copies with one click. Because drafts and documents often contain unpublished or confidential content, this tool does all of its conversion entirely inside your browser — nothing is uploaded, stored, or sent to a server.

How to use

  1. Pick the direction in the toolbar (Markdown → HTML or HTML → Markdown).
  2. Paste your Markdown (or HTML) into the input box on the left — use "Sample" to try an example. For Markdown → HTML you can toggle "Insert table of contents" and "Heading anchors (id)".
  3. The converted result appears instantly on the right, with a live preview below. Click "Copy" to grab the output. Nothing you paste is sent anywhere.

FAQ

Is the Markdown or HTML I paste uploaded anywhere?

No. Conversion, table-of-contents generation and the preview all run in your browser with JavaScript. Your input is never uploaded, stored, or sent to a server, so confidential drafts and unpublished articles are safe to paste.

How is the table of contents generated?

It collects every heading (# through ######) in order, gives each one an anchor id, and inserts a nested bullet list at the top of the document based on heading level. Duplicate heading titles get unique ids (-1, -2, …) so the TOC links always jump to the right place. Turn on "Insert table of contents".

What do the heading ids (anchors) look like?

GitHub-style slugs: the heading text is lowercased, punctuation is removed and spaces become hyphens (e.g. "## Getting Started" → id="getting-started"). Non-Latin headings are kept as anchors too. Turn off "Heading anchors (id)" if you don't want ids.

Which Markdown features are supported?

Headings, paragraphs, bold/italic/strikethrough, inline code and fenced code blocks (```), links and images, bullet and numbered lists (including nesting), blockquotes, horizontal rules, autolinks and GFM pipe tables. The goal is a reliable round-trip of the syntax people actually use; a few niche extensions (footnotes, custom directives) are out of scope.

What does HTML → Markdown convert back?

Headings, paragraphs, bold/italic, inline code and code blocks, links, images, bullet and numbered lists (nested), blockquotes, tables, horizontal rules and line breaks. Decorative classes and script/style are dropped. Very complex custom layouts can't be reproduced perfectly, so a quick manual touch-up afterwards is recommended.

Can I paste the converted HTML straight into my site?

Yes. The output is plain HTML you can drop into a blog, CMS or static site. The preview only styles things for display inside this tool; what gets copied is the raw, style-free HTML.