HTML to Markdown Converter
Paste HTML or upload an .html file and get clean Markdown back. Keep just the main content, fix relative links with a base URL and choose your heading style.
- 100% free
- No sign-up
- Runs in your browser
HTML
588 characters
Or drop an .html file
or
Read in your browser. Your file never leaves your device.
Options
Heading style
Optional, e.g. https://example.com/blog/
Markdown
0 words · 0 characters · 0 lines
Why convert HTML to Markdown
HTML is built for browsers. It's full of tags, classes and wrappers that make content hard to read and edit by hand. Markdown keeps the parts that matter for writing (headings, emphasis, links, lists, tables and code) in a format that's readable as plain text.
Common uses
- Moving blog posts from WordPress or another CMS to a static site generator like Next.js, Hugo or Astro.
- Turning HTML emails or newsletters into notes for Notion or Obsidian.
- Cleaning web content before giving it to an AI assistant, which uses fewer tokens than raw HTML.
- Writing README files and documentation from existing web pages.
What gets lost
Markdown has no layout, colours, fonts or column structure, so styling is dropped. Complex tables with merged cells are flattened to simple rows, and embedded media like videos and forms are removed.
How it works
How to use it
- Step 1
Paste or upload HTML
Paste HTML source code into the box, or drop an .html file saved from a browser or exported from a CMS.
- Step 2
Set your options
Keep only the main content, choose whether to keep links and images, and add a base URL for relative links.
- Step 3
Copy the Markdown
The Markdown updates as you type. Check the preview, then copy it or download a .md file.
FAQs
Frequently asked questions
Answers to common questions about the HTML to Markdown Converter.
No. The HTML is parsed and converted in your browser. Nothing you paste or upload is uploaded or stored, and scripts in the HTML are never run.
It looks for the page's <main> or <article> element and drops navigation, headers, footers, sidebars and hidden elements. Use it for full web pages saved from a browser. Turn it off when you paste a snippet that should be converted as a whole.
Saved pages often use relative links like /pricing or ../images/logo.png. They break once the Markdown lives somewhere else. With a base URL such as https://example.com/blog/, every relative link and image becomes a full URL. If the HTML has a <base> tag or a canonical link, it is used automatically.
ATX headings start with # signs (# Title, ## Section) and work for all six levels. Setext headings underline the text with === for level 1 and --- for level 2, and fall back to # for levels 3 to 6. Both are standard Markdown. ATX is more common.
Headings, paragraphs, line breaks, bold, italic, strikethrough, links, images, ordered and unordered lists, blockquotes, code blocks, inline code, horizontal rules and tables. Scripts, styles, forms, iframes and SVG are removed.
This tool works with HTML you paste or upload. To convert a page straight from its address, use the Webpage to Markdown tool in the free tools list.
More free tools
Try another tool
- ConverterPDF to Markdown ConverterConvert a PDF to Markdown with headings, lists and paragraphs kept.Use for free
- ConverterCSV to Markdown TableTurn a CSV or spreadsheet paste into a Markdown table.Use for free
- ConverterJSON to Markdown ConverterTurn JSON into readable Markdown lists or tables.Use for free
- ConverterWord to Markdown ConverterConvert a .docx file to Markdown with headings, lists, links and tables.Use for free
- ConverterRTF to Markdown ConverterConvert an RTF document to Markdown.Use for free
- ConverterPaste to MarkdownPaste formatted text from Docs, Word or a web page and get Markdown.Use for free
Put your Instagram DMs on autopilot
Hypello replies to comments and DMs with the link or info people ask for, and its AI agents collect names, emails and phone numbers for you. Free for up to 1,000 DMs a month.