Utils365

Convert HTML to Markdown

Turn HTML code, or text copied from a page or document, into tidy Markdown.

  • 100% free
  • No sign-up
  • Runs in your browser

Paste HTML code, open an .html file, or drop one here

Copy part of a web page, a Word file or a Google Doc and paste it here. Its formatting is turned into HTML in the box above, then into Markdown.

Next: Markdown editor · Markdown to PDF · HTML formatter

Report a problem with this tool

How to use HTML to Markdown

  1. Paste HTML or formatted text

    Paste HTML code, open an .html file, or paste text copied from a web page, Word or Google Docs into the formatted paste box.

  2. Choose your Markdown style

    Keep or leave out images, pick inline or reference links, and set the heading, bullet, bold and code block styles.

  3. Copy or download

    Copy the Markdown, or download it as a .md file.

Why use Utils365

  • GitHub-style Markdown

    Tables keep their column alignment, checkboxes become task list items, struck-through text uses ~~, and code blocks are fenced with their language.

  • Cleans up as it converts

    Scripts, styles, frames, comments, hidden elements and tracking pixels are dropped, along with the extra markup Word and Google Docs add.

  • Links that still work

    Give the page’s address and relative links like /about are written as full addresses, so they work wherever the Markdown ends up.

  • Private and safe

    The HTML is read as an inactive document on your device: its scripts never run, its images never load, and nothing is uploaded.

Frequently asked questions

Can I convert a web page by its address?

Not directly, because nothing is fetched from the internet. Open the page, select and copy the part you want and paste it into the formatted paste box, or save the page as an .html file and open it here.

How are tables converted?

Into pipe tables. Left, center and right alignment is kept, a | inside a cell is escaped, and line breaks inside a cell become <br>. A cell that spans several rows or columns leaves empty cells so the columns stay lined up. Markdown tables need a header, so the first row is used as one. Tables used only for layout, with a single column or other tables inside, are written as ordinary paragraphs.

Does it work with text copied from Word or Google Docs?

Yes. Paste it into the formatted paste box. Bold, italic, strikethrough, headings, links, tables and lists are kept, including Word’s lists, which arrive as plain paragraphs and are rebuilt. Colors, fonts and sizes have no Markdown equivalent and are dropped.

What happens to images?

Images are kept as ![alt](address) unless you leave them out. Images stored inside the HTML itself as data: addresses, which is how pasted documents often carry them, are always left out, and you’re told how many.

How is the language of a code block found?

From a class such as language-js or lang-py on the code or pre element, or highlight-source-js on the block around it. If the code itself contains ```, a longer fence is used so the block stays intact.

Why are some characters written with a backslash?

Characters like *, _ and [ are escaped where Markdown would otherwise read them as formatting, so 2 * 3 stays text instead of starting italics. Text that looks like a tag, such as <div> in a tutorial, is escaped too, so it shows as text instead of turning into HTML. They all show normally once the Markdown is rendered.

Is anything left as HTML in the Markdown?

Two things, because Markdown has no way to write them: superscript and subscript stay as <sup> and <sub> tags, so x² and H₂O keep their meaning, and line breaks inside table cells are written as <br>. Links are kept only when they point to a web address, an email address or a phone number; other kinds, such as javascript: links, lose the link and keep their text. Buttons and form fields are left out.