Markdown to HTML
Paste Markdown or open a .md file and get the HTML code straight away, with a preview of how it looks. Copy the code into a website or email template, or download it as an .html file.
About Markdown to HTML
This converter turns Markdown into the HTML code that web browsers understand. It follows CommonMark, the detailed standard most Markdown tools now share, plus the extras GitHub added: pipe tables, task lists, strikethrough and bare web addresses turned into links. The code appears in one box and a rendered preview sits next to it, so you can check the result before copying it anywhere.
Two options matter most. “Remove scripts and unsafe HTML” cleans the output with DOMPurify, a widely used sanitiser, so Markdown from someone else cannot slip a script or an onclick handler into your page. “Full HTML page” wraps the result in a complete document with a character set, a mobile viewport, a title taken from your first top-level heading and light styling, ready to open in a browser or attach to an email.
When to use it
- Your CMS or newsletter tool accepts HTML but you prefer writing in Markdown.
- You need to publish a README or changelog as a standalone web page.
Worked example
Paste this Markdown:
## Shopping list / (blank line) / - [x] Rice / - [ ] **Toor dal** / (blank line) / Recipe: [dal tadka](https://example.com/dal)
The output starts with a level-two heading, followed by an unordered list. Each list item begins with a disabled checkbox, checked for Rice and empty for Toor dal, and “Toor dal” is wrapped in a strong element. The final paragraph contains a link to example.com/dal with the text “dal tadka”. The preview shows the same thing formatted.
Good to know
- Without the sanitising option, raw HTML in the Markdown passes through unchanged. The on-page preview is always cleaned either way.
- A single line break is normally ignored, as in standard Markdown. Tick the line-break option to turn each one into a break tag.
- GitHub extras such as @mentions, emoji codes and Mermaid diagrams are not converted.
- Conversion happens in your browser; nothing is uploaded.
How to use Markdown to HTML
- Paste your Markdown or open a .md file.
- Choose the options: remove unsafe HTML, line breaks, and fragment or full page.
- Check the preview, then copy the HTML or download the .html file.
Privacy: how it works
Everything happens in your browser. Your text is not sent to any server.
Frequently asked questions
What does “Remove scripts and unsafe HTML” do?
Markdown can contain raw HTML. With this option on, scripts, event handlers such as onclick, and javascript: links are removed using the DOMPurify library, so the result is safe to paste into a page. Switch it off only for Markdown you trust.
What is the difference between a fragment and a full page?
A fragment is just the converted content, ready to paste into an existing page or CMS. A full page adds the <!doctype>, <head>, a title taken from your first heading, and simple readable styling, so the file opens nicely on its own.
Does it follow GitHub’s Markdown?
It follows CommonMark with GitHub’s extensions: tables, task lists, strikethrough and automatic links. GitHub-only features such as @mentions, emoji shortcodes and diagrams are not converted.