ToolsHub4u

Convert Markdown into clean HTML

Paste Markdown and get HTML with tables, footnotes, task lists and nested lists, a live preview, and relative links kept as written.

  • Live preview
  • Scripts escaped
  • Runs locally
Ready Developer & Utility
1Enter
2Adjust
3Copy result

Markdown to HTML Converter

1

Markdown input

No data yet Live
2

HTML output

Converted 17 lines of Markdown to HTML.

Rendered preview

HTML

  • Raw HTML is escapedA tag written in the Markdown source is shown as text rather than passed through. That keeps scripts out of the preview.
  • CommonMark subsetHeadings, lists, links, images, emphasis, code, quotes, rules and paragraphs are supported. Tables, footnotes and task lists are not.
Headings
2
Links
1
Code blocks
1
HTML characters
481

The preview runs in a sandboxed frame with no scripts. Links are limited to http, https, mailto, tel, anchors and relative paths; anything else becomes #.

This page converts Markdown into HTML and shows a live preview beside the output. It handles headings, paragraphs, emphasis, links, images, blockquotes, nested lists, task lists, pipe tables with alignment, footnotes and fenced code blocks. Paste or type the Markdown, choose whether a single newline becomes a line break, and copy the generated HTML.

The converter follows a CommonMark subset plus the three extensions people ask for most: tables, task lists and footnotes. That covers ordinary README and documentation syntax. Knowing which side of that line a feature sits on is the main thing to check before publishing.

What is supported

ATX headings from # to ###### become the matching h1 to h6. Paragraphs are separated by a blank line. **bold** and __bold__ become strong, single asterisks or underscores become em, and double tildes become del. Backticks produce code, and a triple-backtick or triple-tilde fence produces a pre with a code element inside.

Links use [text](url) and images use ![alt](src). Blockquotes get a > prefix, unordered lists use -, * or +, and ordered lists use numbers. A line of three or more hyphens or asterisks becomes a horizontal rule. Fenced code keeps its content escaped, so angle brackets inside a code sample render as text.

Indentation decides nesting. An item indented under another item becomes a child list, so 1. One followed by an indented 1. One A produces an ol inside the first li. An ordered list that starts at a number other than one keeps that number in a start attribute, as in <ol start="3">.

Inline code is protected from further parsing. In the test, `code **not bold**` became a code span containing the literal asterisks rather than a bold word. That is the correct behaviour and the one most likely to be noticed when documentation shows syntax examples.

Tables, task lists and footnotes

A pipe table needs a header row and a separator row of at least three hyphens per column. It becomes a real table with thead, tbody, th and td. A colon at the start of a separator cell gives left alignment, a colon at both ends gives centre, and a colon at the end gives right, written as a style="text-align:…" on each cell in that column. In the test, a three-column table with one of each produced 300 characters of HTML and kept all three alignments.

A task list item is written - [x] Done or - [ ] Todo. The text becomes a disabled checkbox followed by the label, and the item gains class="task-list-item". If every item in the list is a task, the ul also gets class="task-list" and the bullets are hidden; in a mixed list the bullets stay on the plain items and only the task items lose their marker. The test pair produced two disabled checkboxes, one of them checked.

A footnote is a reference such as [^note] plus a definition line [^note]: The text. References become numbered superscript links, a second reference to the same note reuses the number with a longer id, and the definitions collect in a section class="footnotes" list at the end with a back link. In the test, two notes with three references produced two notes and five links in total, counting the references and the back links.

Line breaks and the preview

With Treat single line breaks as <br> off, a single newline inside a paragraph is treated as a space, which is the CommonMark rule. Two lines of an address therefore run together unless you leave a blank line or add two trailing spaces. With the option on, every newline becomes a <br>, which matches how many people expect a chat message or a poem to behave. In the test, a two-line paragraph was 24 characters with the option off and 28 with it on.

The preview runs in a sandboxed frame with scripts disabled. That is a safety measure: even if the converter let a script through, it would not run in the preview. The note under the result says so, and it is worth reading before you assume the preview proves the HTML is safe for your own site.

The output area contains the HTML source, not the rendered page. Copy it into a template or a CMS field. The preview is for checking structure and emphasis, not for checking your site's CSS, because the frame does not load your stylesheet.

A worked example

The page's sample is 25 lines: a heading, a paragraph with bold text, a subheading, a list with a nested pair, two task items, a two-column table, a blockquote, a JavaScript fence, a link and a footnote. Converted with the line-break option off, it produced 1,136 characters of HTML with 2 headings and 1 code block.

Conversion results for four Markdown inputs
InputResult
25-line sample with table, nested list and footnote1,136 characters, 2 headings, 1 code block
Table with left, centre and right alignment300 characters, three text-align styles
Nested ordered list, four lines77 characters, an ol inside the first li
- [x] Done and - [ ] Todo190 characters, two disabled checkboxes

The sample output is clean, semantic HTML. The heading became <h1>, the emphasis became <strong>, the list became a ul whose second item contains a child ul, and the code fence gained class="language-js" from the fence info string. The link kept its root-relative /about.html address. The footnote reference became a superscript link to the note at the end.

The code fence is the part to check closely. The JavaScript arrow in items.reduce((sum, item) => …) was written as =&gt; inside the code element, which is correct: the browser displays => and the HTML stays valid. Copying the output into a page will show the code rather than execute it.

A table needs its separator rowA header row followed by a line of pipes without hyphens is not a table. The separator row of at least three hyphens per column is what marks it, and without one the pipes stay as paragraph text.

Links and raw HTML

Raw HTML in the Markdown is escaped, not passed through. A <script> tag and an <img onerror> both appear as visible text in the output, which is the safe default for a converter that anyone can paste into. If you need raw HTML, this is not the tool for that document.

A link keeps its address unless it names a scheme that is not safe in an href. http, https, mailto and tel pass, and so does every relative path, including about.html, ../index.html and /about.html. javascript:, data: and vbscript: become #. The scheme test ignores case and stray spaces, so JavaScript: is caught too.

A destination may be wrapped in angle brackets or contain balanced parentheses, and it is read as one address. [note](https://example.com/a(b)) produced a single link with no stray closing bracket, and [click](javascript:alert(1)) produced a link to # with nothing left over in the text. That is the failure mode that used to leave a loose ) behind.

What is not supported

Reference-style links such as [text][id], setext headings underlined with === or ---, and indented code blocks are not implemented. A setext underline is read as a horizontal rule, so use ATX # headings and fenced code when consistency matters. Definition lists, emoji shortcodes such as :smile: and strikethrough with a single tilde are left as text.

There is no syntax highlighting. A fence with an info string gains a language-… class, and your own highlighter can use it, but the page does not colour the code itself. A table cell containing a list or a block element is flattened into one cell of inline text, and very deep list nesting keeps its indent but is easier to check in the source than in the preview.

For the reverse direction, use the HTML to Markdown converter. If the generated HTML needs tidying, the HTML beautifier will indent it, and the HTML minifier will strip the whitespace before you paste it into a page.

Questions

Common questions

Short answers about this tool and its limits.

Does it support tables?

Yes. A header row, a separator row of at least three hyphens per column and the data rows become a real HTML table. A colon at the start, end or both ends of a separator cell sets left, right or centre alignment on that column.

Are nested lists kept?

Yes. An item indented under its parent becomes a child list inside that parent's li, for both bulleted and numbered lists. An ordered list that starts at 3 keeps the starting number.

Do task lists get checkboxes?

Yes. - [x] Done and - [ ] Todo become disabled checkboxes with the label beside them. In a mixed list the plain items keep their bullets and only the task items lose the marker.

Are footnotes supported?

Yes. A [^note] reference becomes a numbered superscript link and the definition is collected in a list at the end. Two references to the same note share a number, and each note has a back link to its first reference.

Is raw HTML allowed?

No. A tag written in the Markdown is escaped and shown as text. That keeps scripts and event handlers out of the output, and it means you cannot use this page to pass through an HTML snippet.

What happens to a javascript: link?

It becomes #. http, https, mailto, tel and relative paths are kept, and a destination with parentheses is read whole, so no stray bracket is left in the text.

What does the line-break option change?

Off follows CommonMark: a single newline inside a paragraph is a space. On turns every newline into a <br>. Use it for addresses, poems or chat-style text where line breaks are meaningful.

Is my Markdown uploaded?

No. Conversion runs in the browser with no account or server copy. Copy or download the HTML before closing the tab, because nothing is stored.