HTML to Markdown Converter: Web Pages & Articles to MD
HTML to Markdown converter online: turn web pages, emails, or articles into clean Markdown for notes and publishing. Copy or save as .md.
Updated 2026-08-26
Related Tools
Markdown Editor Online: Write, Preview & Export HTML
HTML to Text Converter: Remove HTML Tags & Get Plain Text
CSV to Markdown Table: Convert CSV/TSV to Markdown Online
EPUB to Markdown: Convert EPUB eBooks to Markdown Online
JSON to Markdown: Convert JSON to Markdown Table Online
Markdown to HTML Converter: Convert Markdown to HTML Online
Features
- Convert HTML to clean Markdown syntax instantly
- Supports headings, paragraphs, links, images, lists, tables, code blocks, and more
- Real-time conversion as you type or paste
- Preserve or remove links with a single toggle
- Escape special Markdown characters option
- Copy converted Markdown to clipboard with one click
- Save results as .md files
- Handles nested HTML elements and malformed markup gracefully
- Works with full HTML documents and code snippets
How to Use
- 1Paste your HTML code into the input area on the left panel.
- 2The Markdown output updates in real-time on the right panel.
- 3Toggle options to preserve links or escape Markdown characters.
- 4Copy the result to your clipboard or save it as a .md file.
- 5Use the Clear button to reset and start over.
- 6Drag and drop an .html file onto the input area to load its content for conversion.
- 7Enable 'Preserve Links' when you want clickable URLs in the Markdown output; disable it for plain text.
- 8Enable 'Escape Markdown' when your HTML contains characters like *, _, or [ that could be misinterpreted as Markdown formatting.
- 9Use the Save button to save the result as a .md file ready for use in GitHub, GitLab, or documentation platforms.
Frequently Asked Questions
What HTML tags are supported for conversion?
Our converter supports: headings (h1-h6), paragraphs (p), links (a), images (img), bold/strong (b, strong), italic/emphasis (i, em), code (code, pre), lists (ul, ol, li), blockquotes (blockquote), horizontal rules (hr), line breaks (br), and tables (table, thead, tbody, tr, th, td). Unsupported tags are stripped but their inner text is preserved.
How do I convert HTML to Markdown with Python or an npm package?
Python: pip install markdownify, then markdownify.markdown(html), or html2text for a different flavor. JavaScript/npm: turndown (new TurndownService().turndown(html)). This tool runs the same kind of conversion in the browser, so you get the result without installing anything.
Is there a Chrome extension for HTML to Markdown conversion?
Yes, several browser extensions convert the current page or a selection to Markdown (copy-as-markdown style tools), but they need permission to read page content. This web tool converts pasted HTML with no extension and no permissions, and works in every browser including Firefox, Edge, and Safari.
How are HTML tables converted?
HTML tables are converted to Markdown pipe tables. The first row becomes the header, separated by a dashed separator row. Each subsequent row becomes a data row. This format is widely supported by most Markdown parsers.
Why did my links disappear after conversion?
Links are stripped whenever Preserve Links is off; only the visible link text survives. Turn the toggle on and <a href='url'>text</a> converts to [text](url) instead. This is useful when you want plain text without hyperlinks, and it is the only setting that controls link output.
What does 'Escape Markdown characters' do?
When enabled, special Markdown characters like *, _, [, ], (, ), #, +, -, ., !, and \ are escaped with backslashes. This prevents them from being interpreted as Markdown formatting in the output.
Can I convert a full web page or HTML document?
Yes, you can paste the full HTML of any web page or a complete document. The converter processes all supported elements and extracts content from <body>; <head>, <style>, <script>, and <meta> tags are stripped because they have no Markdown equivalent. Complex layouts with CSS-dependent formatting may not convert perfectly, so for best results copy the main content area of the page.
Does this tool handle inline CSS and JavaScript?
Inline CSS and JavaScript are not converted to Markdown. They are treated as unsupported tags and stripped, though their inner text content is preserved. For a cleaner result, consider removing script and style elements before conversion.
Why is conversion slow on very long documents?
There is no strict input limit, but documents over 100,000 characters can slow conversion noticeably. All processing runs client-side, so speed depends on your device. For large pages, convert section by section: each part converts instantly and the .md files can be merged afterward.
How are HTML lists converted to Markdown?
Unordered lists (<ul>) become Markdown bullet lists with -, *, or +. Ordered lists (<ol>) become numbered lists with 1., 2., 3. Nested lists are preserved with proper indentation. List items with multiple paragraphs are handled correctly. The converter maintains the list hierarchy so complex nested lists remain readable.
How are links and images handled?
With 'Preserve Links' enabled: <a href='url'>text</a> becomes [text](url) and <img src='url' alt='text'> becomes . With it disabled, only the visible text is kept. Image alt text becomes the Markdown image's alt text. Relative URLs in href and src attributes are preserved as-is.
Why does the output look cluttered with backslashes?
That is the Escape Markdown option working as designed: every special character (*, _, #, [, ], parentheses, and more) gets a backslash so the Markdown renderer treats it as literal text. If your source text is plain prose or code that should not be formatted, turn Escape Markdown off; the output will be cleaner. Keep it on only when your HTML contains characters that would otherwise be misinterpreted as Markdown syntax.
Why are classes, IDs, and other HTML attributes not preserved?
Markdown has no concept of attributes; it is a plain-text format. The converter keeps the visible content and structural semantics (headings, lists, links, tables) but deliberately drops class, id, style, and data attributes because no standard Markdown renderer can use them. If you need the attributes, keep the original HTML or use a Markdown dialect that allows raw HTML blocks.
Why does my html to markdown converter online output break complex tables?
Markdown pipe tables only support simple grids: no rowspan/colspan merges and no multi-line cells. Complex tables are flattened into the closest pipe-table approximation, so merged cells repeat or collapse. For such tables, keep the original HTML: GitHub and most renderers display raw HTML tables correctly. Alternatively, restructure the table into simple cells before converting.
Why does this html to markdown converter give different output than Python markdownify or JS turndown?
Libraries make different choices: which tags to keep, how nested lists are indented, which table flavor to emit, and whether special characters get escaped. This browser converter produces output close to turndown's defaults (CommonMark-ish). There is no single 'correct' Markdown; pick the output that renders correctly on your target platform, and use the Preserve Links and Escape Markdown options to steer the result.