Format
Markdown Previewer & HTML Converter
Live-preview Markdown as HTML, or convert HTML back into Markdown, right in your browser.
Runs entirely in your browser — nothing you paste is uploaded or stored.
What is markdown previewer?
A README, a pull request description, a changelog entry, a wiki page — Markdown is the default way developers write formatted text, but a raw `.md` file is hard to proofread as plain text: you can't tell whether a table lined up, whether a nested list rendered the way you meant, or whether a stray `_` closed emphasis early. This tool renders Markdown to a live HTML preview as you type, using GitHub Flavored Markdown — tables, strikethrough, task lists and autolinks all work the way they do on GitHub, not just bare CommonMark. It also runs the other direction: paste HTML copied from a web page or exported from a rich-text editor, and get back clean Markdown you can drop into a README or a chat message. Every rendered result is sanitized before it's displayed, and the live preview itself renders inside a sandboxed frame with scripts disabled, so pasting HTML from an untrusted source never executes anything — the point of a previewer is looking at *someone else's* markup safely, not just your own.
When to use it
- Proofreading a README or CONTRIBUTING.md before committing it, to catch a table that didn't line up or a list that nested wrong.
- Drafting a GitHub-flavoured pull request description or issue comment and checking it renders correctly before pasting it in.
- Converting a snippet of HTML copied from a web page or emailed document into clean Markdown for a wiki page or README.
- Sanity-checking Markdown generated by a script, static-site generator, or LLM before it ships, especially GFM tables and task lists.
How to use this tool
- Paste Markdown into the input, or click "Load example" to see a working sample.
- Watch the rendered preview update as you type, or switch to "Source" to see the generated HTML.
- Turn on "Line breaks" if you want a single newline to become a line break, instead of requiring a blank line between paragraphs.
- To go the other way, switch to "HTML → Markdown", paste HTML, and pick a heading style, bullet marker and code block style for the output — the preview then shows what the converted Markdown renders as, so you can spot anything the conversion couldn't carry across.
- Copy the result, download it as a file, or copy a link that restores this exact input and options.
Example
A short release note in GitHub Flavored Markdown, rendered to HTML.
Input
# Release Notes
**v2.1** adds *dark mode* and fixes a login bug.
- Faster startup
- Smaller bundle size
> See the [full changelog](https://example.com/changelog) for details.Output
<h1>Release Notes</h1>
<p><strong>v2.1</strong> adds <em>dark mode</em> and fixes a login bug.</p>
<ul>
<li>Faster startup</li>
<li>Smaller bundle size</li>
</ul>
<blockquote>
<p>See the <a href="https://example.com/changelog">full changelog</a> for details.</p>
</blockquote>The heading, bold and italic emphasis, list, and blockquote-with-link all render exactly as they would on GitHub — this is what the live preview shows, and "Source" shows this exact HTML as text.
Why the preview renders in a sandboxed frame
Most “paste your own Markdown” tools only ever render content the user typed themselves, so
there’s little to worry about. This tool is explicitly also meant for the reverse case —
pasting HTML copied from somewhere else, or Markdown someone else wrote — which means the
input can’t be assumed safe. The rendered result is sanitized with
DOMPurify before it’s ever displayed, stripping
<script> tags, on* event-handler attributes, and javascript: URLs. The live preview then
renders that already-sanitized HTML inside a sandboxed <iframe> with scripting disabled
entirely, so even a sanitizer bug would still have nothing able to execute. Two independent
layers, for content whose origin the tool has no way to vouch for.
Frequently asked questions
Is it safe to paste HTML I don't trust into this tool?
Yes — that's specifically what it's built for. Every rendered result is sanitized to strip scripts, event-handler attributes, and other executable content before it's shown, and the live preview itself renders inside a sandboxed iframe with scripts disabled as a second layer of protection. Nothing you paste is ever transmitted anywhere either; the whole conversion happens in your browser tab.
What Markdown flavour does this use?
GitHub Flavored Markdown (GFM) — CommonMark plus tables, strikethrough (`~~text~~`), task lists (`- [ ]`), and automatic linking of bare URLs. This is what almost every visitor means by "Markdown" today, since it's what GitHub, GitLab and most chat tools actually render, rather than the narrower base CommonMark spec.
Why doesn't this tool warn me when my HTML or Markdown looks malformed?
Because, unlike JSON or SQL, neither format actually has an "invalid" state a parser can reject. The HTML5 specification defines exactly how a browser must recover from a mismatched or unclosed tag, so a browser (and this tool, which uses the browser's own HTML parser) never fails on it — it always produces *some* structure, just possibly not the one you meant. Markdown's grammar is designed the same way — every input has a well-defined rendering, however odd it looks, rather than a parse error. That's exactly why the live preview matters here — it's the real check. If the rendered result doesn't look like what you meant, that mismatch is the signal, not an error message.
Why does "HTML → Markdown" lose some of my formatting?
Markdown's grammar only covers a specific, limited set of formatting — headings, emphasis, lists, links, images, blockquotes, code, and (with GFM) tables and strikethrough. HTML can express far more than that — layout `<div>`s, inline styles, custom classes, forms, and many other elements have no Markdown equivalent, so they're either flattened to their text content or dropped. This is expected, not a bug — the same trade-off any HTML-to-Markdown converter makes.
What's the difference between "Preview" and "Source"?
The "Preview" view always shows a rendered result you can eyeball, and "Source" always shows text you can copy — which text depends on the direction. Converting Markdown to HTML, "Source" is the generated HTML markup itself. Converting HTML to Markdown, "Source" is the converted Markdown, and "Preview" renders that Markdown back to HTML purely so you have something to look at — Markdown has no "invalid" state a parser can flag, so seeing it rendered is the real way to catch anything the conversion couldn't carry across.
Is there a size limit?
Yes, 500,000 characters in either direction. Both the Markdown renderer and the HTML-to-Markdown converter run synchronously in your browser tab with no server to offload to and no way to show progress, so an unbounded document would freeze the page. That covers any realistically hand-written document — a file that large is almost always generated and better processed by the tool that generated it.
Find these tools useful? A coffee helps keep them free and ad-light.
Buy me a coffee