Skip to content
hateitall

HTML to Markdown

Move a web page, email or CMS export into Markdown without retyping it, keeping the structure intact.

Processed locallyIn: HTML, HTM, TextOut: Markdown

Loading tool…

How to use html to markdown

  1. Paste HTML or open an .html file.

  2. Pick the bullet marker and code fence style, and whether to keep images.

  3. Read the Markdown on the right; it updates as you type.

  4. Copy it or download it as a .md file.

What this tool does

  • Converts headings, paragraphs, nested bulleted and numbered lists, task list checkboxes, links, images, bold, italic and strikethrough.
  • Turns pre and code blocks into fenced code with the language kept, and HTML tables into GitHub pipe tables with alignment.
  • Cleans the HTML with an allowlist first, so scripts, event handlers and javascript: links never reach the Markdown.
  • Escapes characters such as * and _ in ordinary text so they read back as text, not formatting.

How the result is verified

The Markdown is rendered back to HTML and its visible text is compared with the visible text of the cleaned input. The result of that round trip is shown under the output.

Frequently asked questions

Can I convert a whole web page?

Yes. Save the page as HTML or copy its source and paste it in. Navigation, scripts and styles are dropped, so you may want to trim menus and footers from the result.

What happens to inline styles and classes?

They are removed. Only the structure that Markdown can show survives: headings, lists, emphasis, links, images, code, quotes and tables.

Is my data uploaded to a server?

No. Everything you drop, paste or type is processed by code running in this browser tab. You can check it yourself: open your browser's developer tools, watch the Network panel, and use the tool. No request carries your data.

CommonMark and GitHub tables to clean, sanitized HTML

Markdown · MD · Text→ HTMLLight on device

Plain text from HTML with line breaks kept and entities decoded

HTML · Text→ TextLight on device

Consistent headings, bullets, emphasis and spacing, output unchanged

Markdown · MD→ MarkdownLight on device

Indent HTML neatly while keeping pre, textarea and script content intact

HTML · SVG→ HTMLLight on device