Skip to content

Free HTML to Markdown Converter

Paste HTML from a web page or editor and get tidy Markdown for a README, a wiki or your notes.

  • 100% free
  • Runs in your browser
  • Instant results
Quick answer

An HTML to Markdown converter reads HTML markup and rewrites it in Markdown: headings become # lines, bold becomes **text**, links become [text](url) and lists, tables and code blocks get their Markdown forms. Paste your HTML and copy clean Markdown. Scripts, styles and layout-only tags are dropped.

How to use the HTML to Markdown Converter

  1. Paste your HTMLPaste a fragment or a whole page. You can copy the source from your browser's developer tools or from a CMS editor.
  2. Review the MarkdownThe Markdown appears instantly. Check tables and nested lists, which are the parts most likely to need a manual touch.
  3. Copy or downloadCopy the Markdown or download it as a .md file.

How HTML is mapped to Markdown

The HTML to Markdown converter parses your markup into a tree and writes each element in the equivalent GitHub Flavored Markdown:

  • <h1> to <h6> become # to ###### headings.
  • <strong>/<b> become **bold**, <em>/<i> become *italic*, and <del>/<s> become ~~strikethrough~~.
  • <a> becomes [text](url "title") and <img> becomes ![alt](src).
  • <ul> and <ol> become bullet and numbered lists, with nested lists indented and checkboxes turned into task items.
  • <pre> becomes a fenced code block, keeping the language from a language-xxx class; inline <code> becomes backticks.
  • <blockquote>, <hr> and <br> become > quotes, --- and line breaks.
  • <table> becomes a pipe table, using the first row as the header.

HTML entities such as &amp; and &nbsp; are decoded, and characters that Markdown would treat as formatting (*, _, [, backticks and a leading #) are escaped with a backslash so your text keeps its meaning.

What gets dropped, and limits to know about

Markdown describes content, not layout, so anything without a Markdown equivalent is simplified:

  • Removed completely: <script>, <style>, the document <head>, SVG graphics, iframes, embedded audio and video, and form controls.
  • Unwrapped: containers such as <div>, <span>, <section> and unknown tags keep their text but lose the tag. Classes, IDs and inline styles are discarded.
  • Tables must be simple. Merged cells (colspan, rowspan) and block content inside cells cannot be expressed in Markdown tables; cell content is flattened to one line.

The converter is tolerant of sloppy HTML, including unclosed <p> and <li> tags. It works on the markup you paste, not on a live page, so content that a site adds with JavaScript after loading will only be included if you copy the rendered HTML from the developer tools.

Nothing is uploaded and no scripts in the pasted HTML are run: the markup is handled as text. To turn Markdown back into HTML, use the Markdown to HTML converter.

Frequently asked questions

How do I convert HTML to Markdown?

Paste the HTML into the HTML to Markdown converter. Headings, links, lists, tables and code blocks are rewritten in Markdown, ready to copy or download.

Which Markdown flavour does it produce?

GitHub Flavored Markdown: ATX headings with #, hyphen bullets, fenced code blocks, pipe tables, strikethrough and task lists. It works on GitHub, GitLab and most Markdown editors.

What happens to scripts, styles and classes?

Scripts, styles, iframes and form controls are removed. Classes, IDs and inline styles are dropped because Markdown has no way to express them.

Can it convert a whole web page?

Yes, paste the page source. Navigation menus and footers are converted too, so you may want to paste only the main content area.

Is my HTML uploaded or executed?

No. It is parsed as text inside your browser. Nothing is sent to a server and no code from the pasted HTML is run.

Last updated 24 November 2026 by the TheTechFolk team.