More
More
Markdown ↔ HTML
Preview Markdown, convert to and from HTML, and export to Word or PDF.
Free tools that run in your browser. Nothing you type, open or create is uploaded to NerdBible or anyone else.
Exports the Markdown from the Markdown to HTML tab, with the GitHub extras and heading ids set there.
Web page
A complete .html file with simple, readable styling that opens in any browser.
Opens your browser's print window with only the document on the page. Choose Save as PDF as the printer.
Word
A .docx file with real headings, lists, links, tables and code that Word, Google Docs and LibreOffice can open and edit.
Markdown is read with marked (MIT licence) and the preview is built element by element from what it finds, never by pasting HTML into the page. HTML inside your Markdown is kept only for a safe list of formatting tags; scripts, styles, event handlers and javascript: links are removed. The HTML to Markdown and table converters are small scripts on this page that read the HTML as text, so nothing you paste is ever run or loaded; they handle headings, lists, links, images, emphasis, code, quotes and tables. The Word file is written by this page and zipped with fflate (MIT licence).
How to use it
- Pick a tab: Markdown to HTML, HTML to Markdown, or Table to Markdown for an HTML table or cells copied from a spreadsheet.
- Type, paste or open a file. The preview and the converted code update as you type.
- Copy the HTML or the Markdown, or download it as a file.
- To share the document, open Export and download it as a web page or a Word file, or print it or save it as a PDF.
Questions
Which Markdown does this follow?
CommonMark with the GitHub additions: tables, task lists with [ ] and [x], strikethrough with two tildes, and links written as plain addresses. Untick GitHub extras for plain CommonMark.
Why did some of my HTML disappear?
Raw HTML in Markdown is filtered for safety. Formatting tags such as b, i, sup, kbd, details and tables are kept; script, style, iframe, forms and any on... attributes are removed, which is what most sites that accept Markdown do too.
Does HTML to Markdown keep everything?
It converts the parts Markdown can express. Colours, fonts, classes and layout have no Markdown equivalent and are dropped, and the text inside them is kept.
How do I turn an HTML table into Markdown?
Open Table to Markdown and paste the HTML of the table, or a whole page that contains tables. Each table becomes a Markdown table with a header row, and column alignment is kept when the HTML sets it. You can also paste cells copied from a spreadsheet: tab-separated rows become a table too.
How do I save Markdown as a Word document or a PDF?
Write or paste it in Markdown to HTML, then open Export. Download .docx makes a Word file with headings, bold and italic text, bulleted and numbered lists, links, code and tables. Print or save as PDF opens the print window with only your document on the page; pick Save as PDF as the printer. Images are not embedded in the Word file; their alt text is written in their place.
Is my text sent anywhere?
No. Every conversion and export runs in your browser.
About this tool
About the Markdown converter
Markdown is the plain-text formatting used in README files, documentation, notes apps and many forums. This tool shows a live preview as you type and converts in both directions, then exports the result to a web page, a Word file or a PDF.
Markdown to HTML
Text is read with the marked library following CommonMark, with the GitHub additions on by default: tables, task lists written with [ ] and [x], strikethrough with two tildes, and plain addresses turned into links. Untick GitHub extras for strict CommonMark. Copy the HTML or download it as a file.
HTML written inside your Markdown is filtered for safety. Formatting tags such as b, i, sup, kbd, details and tables are kept; scripts, styles, iframes, forms and event handler attributes are removed, which is what most sites that accept Markdown do.
HTML to Markdown
Paste HTML, such as a page section or an email, and get Markdown back. Headings, lists, links, images, emphasis, code and tables convert cleanly. Colours, fonts, classes and layout have no Markdown equivalent, so they are dropped while the text inside them is kept.
Tables
Table to Markdown takes the HTML of one or more tables, or cells copied from a spreadsheet, and returns Markdown tables with a header row, keeping column alignment where the HTML sets it.
Export
- Web page: a complete .html file with simple, readable styling.
- PDF: opens the print window with only your document on the page; choose Save as PDF.
- Word: a .docx file with real headings, bold and italic text, bulleted and numbered lists, links, code and tables, which Word, Google Docs and LibreOffice can open and edit. Images are replaced by their alt text.
Quick syntax reminder
- # Heading, ## Subheading
- **bold** and *italic*
- - item for bullet lists, 1. item for numbered ones
- [text](address) for links
Every conversion and export runs in your browser. Pasted HTML is read as text by the page itself and is never run or loaded.
Related tools
- Text & Markdown to PDFTurn text or Markdown into a clean PDF.
- Code Formatter & MinifierFormat or minify HTML, CSS, JavaScript, SQL, XML, YAML and GraphQL, and check XML.
- Escape, Encode & DecodeEscape and unescape text for JSON, JavaScript, HTML entities, XML, SQL, CSV, regex and URLs.
- Word Counter & ReadabilityWords, characters, sentences and reading time, plus reading ease, grade level, long sentences and passive voice.
- Diff CheckerSee what changed between two texts or two JSON files.