📝 Markdown ↔ HTML

Convert Markdown to HTML or HTML to Markdown with live preview

✓ Free Forever · ✓ No Signup · ✓ No Upload · ✓ Works Offline

🔒 Your text never leaves your device. All processing happens locally in your browser using marked.js + Turndown.js. No upload, no server, no tracking.

Features

  • Bidirectional Conversion — Convert Markdown to HTML or HTML to Markdown — switch direction with one click.
  • Live Preview — See a rendered preview of your HTML output as you type or paste.
  • Copy & Download — Copy the output to clipboard or download as a file.
  • Sample Content — Load a sample to see how the conversion works before using your own content.

How It Works

  1. Choose direction — Select Markdown to HTML or HTML to Markdown conversion.
  2. Paste your content — Enter Markdown or HTML in the input panel.
  3. Copy or download — Get the converted output — copy to clipboard or download as a file.

Use Cases

  • Convert README files to HTML for web publishing
  • Transform Markdown blog posts to HTML
  • Convert HTML snippets to Markdown for documentation

Frequently Asked Questions

Does it support GitHub-flavored Markdown?

Yes: tables, task lists, strikethrough, fenced code blocks and bare links, plus headings with the same ids GitHub gives them, so a table of contents ([Install](#install)) works in the preview and in the HTML. A single line break is a soft break, like a README on GitHub; tick “Turn every line break into <br>” for the comment style. Footnotes ([^1]) and GitHub’s [!NOTE] alerts aren’t converted, they come through as plain text.

What happens to front matter and to HTML tables?

A metadata block at the very top (--- title: … --- in Jekyll, Hugo or Astro posts, or +++ in TOML) is left out of the HTML instead of turning into a line and a heading, and the page says so; its title becomes the downloaded file’s <title>. Going from HTML to Markdown, every table row stays on one line: a | inside a cell is escaped as \| and a line break inside a cell becomes <br>, which GitHub renders. <kbd>, <sub> and <sup> are kept as HTML, and a plain <pre> block becomes a code block so its spacing survives.

Is the HTML output clean?

Yes. The output is well-formatted, semantic HTML without unnecessary wrappers or inline styles.

Is it safe to preview a Markdown file I didn't write?

Yes. Before the preview shows anything, scripts, event handlers and javascript: links are stripped out, so a hostile .md file can't run code on this page. The HTML you copy or download is left exactly as converted — it's your document, and I don't rewrite it behind your back.

Notes from Milo 🐨

2026-10-23

I pasted one of my own blog posts in and the very first thing on the page was a horizontal line and a big heading reading "title: … date: …" — the front matter. That's now left out (and the page tells you), and its title becomes the downloaded file's <title>. A README wrapped at 80 columns no longer breaks mid-sentence either: a single line break is a soft break, like on GitHub, with a tick box if you want the comment style. Headings get GitHub's ids, so a table of contents actually jumps. Going the other way, a | inside a table cell used to split the row into an extra column and a line break in a cell broke the table — every row now stays on one line. And there's an Open file button, so you don't have to copy a README out of an editor first.

2026-09-30

I went through this one line by line and didn't love what I found. The preview would happily run code hidden inside a Markdown file — it now cleans everything before showing it, while the HTML you download stays exactly what you wrote. HTML → Markdown was a pile of guesses that mangled images and flattened tables and nested lists; it now reads the page properly, so tables, nested lists, code blocks and images all come through. Switching direction swaps your output into the input instead of wiping it, a dropped .html file opens the right way round, and on a phone the two boxes finally stack instead of squeezing side by side.

Related Tools

💬 Bug, idea, or just to say hi? Tell Milo 🐨 · [email protected]