Convert Markdown to HTML

Type Markdown, see it rendered in a locked-down preview, and copy the HTML. Nothing leaves your browser.

This page opens on the HTML. Type or paste Markdown on the left and the converted code appears first, ready to copy or save as an .html file. Tables written with pipes, strikethrough and task lists are converted, and a block of code becomes pre and code. Use GitHub-style line breaks when your text keeps one sentence per line and you want each line to stay on its own line. Turn on Wrap the HTML in a full page to get a doctype, head and body, so the result opens as a page. The rendered preview sits below the code in a locked frame with no scripts, so you can still check what you made. The HTML itself is raw and not sanitised: a script tag you type stays in it, so clean the output before you use it on a site that shows other people's text. Your Markdown is converted in this tab and is not uploaded.

How it works

  1. Type or paste your Markdown
  2. Check the preview and the two options
  3. Copy or download the HTML

What is converted

The page reads your text with the GitHub-flavoured Markdown rules. That covers headings, bold, italic, links, images, block quotes, code blocks and lists, plus three extras: tables written with pipes, ~~strikethrough~~, and task lists such as - [x] done. Raw HTML you type inside the Markdown is passed through to the HTML box exactly as written. Two options change the result. GitHub-style line breaks turns a single line break inside a paragraph into a br tag; with it off, as in standard Markdown, that break is a space and only a blank line starts a new paragraph. Wrap the HTML in a full page adds a doctype, html, head and body around the HTML box, with a UTF-8 charset and a viewport tag, so the file opens as a page on its own.

How the preview is kept safe

The generated HTML is never inserted into this page. The preview is a separate frame with an empty sandbox: scripts cannot run in it, it cannot submit forms, and it has no access to this page or its storage. Before the HTML reaches the frame, a small filter removes script, style, iframe, object, embed, link, meta and base elements, every on-event attribute such as onclick or onerror, and links that start with javascript: or a data: address. Comments are dropped. Links in the preview are switched off so a click goes nowhere. A security policy inside the frame also blocks pictures that come from the web, so a pasted image address is not requested. Pictures given as data: PNG, JPEG, GIF or WebP are drawn. The filter is a second layer; the sandbox is the first.

The HTML box is raw

What you copy from the HTML box is not filtered. If your Markdown contains a script tag or an onerror attribute, it is in that output, because the preview filter only protects this page. Do not paste the output into a website that shows text from other people without cleaning it first with a sanitiser built for that site. Markdown itself has no safety rules: it allows raw HTML by design. The converter also does not add heading ids, does not highlight code, and does not check that your links work. A fenced code block becomes pre and code with a language class when you name one, and nothing more.

Limits and where it runs

The conversion runs in this tab with the marked library, which is a separate download that loads when the page opens, so the preview appears after a short moment on the first visit. Your Markdown is not sent to a server, not saved and not put in the page address. Only the two option choices are remembered in this browser. Up to 200,000 characters are handled; a longer text shows a message asking you to split it. The words count is the number of space-separated pieces in your Markdown, and the characters count is the length of the HTML before any document wrapper.

Frequently asked questions

Can I get a complete HTML file, not just the body?

Yes. Turn on Wrap the HTML in a full page and the output gains a doctype, a head with a UTF-8 charset and a viewport tag, and a body. Use Download .html to save it as a file.

Does the converter clean the HTML?

No. Raw HTML in your Markdown, such as a script tag, is kept in the output. Only the preview frame is filtered. Sanitise the code before you publish it on a site that shows other people's text.

Will a pipe table become a table?

Yes, when the second line is a divider row such as | --- | --- |. Without the divider row the lines stay as a paragraph.

Why does my image not show in the preview?

The preview frame blocks every request to the web, so an image with an https address is not fetched. The img tag is still in the HTML box. An image written as a data: PNG, JPEG, GIF or WebP address is drawn.

Is the HTML output safe to publish?

No. It is the raw converter output. A script tag or an onerror attribute you typed is kept. Sanitise the HTML with a tool made for your site before you show it to other people.

Which Markdown flavour does it use?

GitHub-flavoured Markdown: tables, strikethrough, task lists and autolinked addresses on top of the standard rules. Heading ids, footnotes and math are not added.

What does the line break option do?

With it on, one line break inside a paragraph becomes a br tag, as comments and issues on GitHub do. With it off, a single break is just a space and you need a blank line for a new paragraph.

Is there a size limit?

Yes, 200,000 characters per paste, roughly a 200 KB file. Above that the page asks you to split the text into parts.