Skip to content
GivenTool

Convert Markdown to HTML

Convert Markdown to clean, sanitised HTML with a live preview, GitHub tables and task lists.

Loading tool…

Markdown is how READMEs, documentation, notes apps and many CMS editors store formatted text. When that text has to go somewhere that only understands HTML, such as an email template, a website without a Markdown plugin, a help-desk article or a newsletter tool, you need the HTML version. This converter shows a live preview next to your Markdown and gives you the HTML to copy, or a complete .html document to download.

GitHub Flavored Markdown is on by default: tables with column alignment, task lists with checkboxes, ~~strikethrough~~, fenced code blocks and bare links turning into links. You can also make single line breaks count as <br>, which suits text written in chat apps, and add target="_blank" to external links. The conversion uses marked (MIT), a widely used Markdown parser, loaded only when you start typing.

Markdown allows raw HTML, which is exactly how malicious content sneaks into converted text. Everything is therefore passed through DOMPurify (used here under its Apache-2.0 licence) before it is shown or copied: <script>, <iframe>, forms, inline styles and event-handler attributes such as onerror are removed, and javascript: links are stripped. The page tells you how many unsafe parts were dropped. Images on other websites are not loaded in the preview, so writing a draft never pings a third-party server; the HTML you copy keeps their addresses.

How to use it

  1. Type or paste Markdown on the left, or click "Load an example".
  2. Watch the preview update; switch to the HTML view to see the markup.
  3. Toggle GitHub Flavored Markdown, line breaks and new-tab links as needed.
  4. Copy the HTML, or download a complete .html page.

Frequently asked questions

Is the HTML safe to paste into my site?

It is sanitised with DOMPurify: scripts, iframes, forms, inline styles, event handlers and javascript: URLs are removed. Your site's own styles decide how it looks.

Why are my images not showing in the preview?

Images hosted on other sites are deliberately not loaded in the preview, for privacy. They appear as a placeholder with their address, and the copied HTML includes them normally.

Which Markdown features are supported?

CommonMark plus GitHub extensions: headings, emphasis, lists, links, images, block quotes, code spans and fenced code blocks, tables, task lists, strikethrough and autolinks. Footnotes and maths are not included.

Is code syntax highlighted?

Code blocks keep their language as a class (for example language-js), so a highlighter on your site such as Prism or highlight.js can colour them. The preview itself shows plain monospaced code.

Does the text leave my computer?

No. Parsing, sanitising and the preview all run in your browser.