Shard Tools

DOCX to Markdown

Convert a Word document to Markdown in your browser.

Maintained by Roshan.

Use DOCX to Markdown

Reads a Word document in this tab and writes it out as Markdown, keeping headings, lists, quotes, tables and emphasis.

Structure survives, layout does notHeadings, lists, tables and emphasis are recorded semantically by Word, so they come through. Page geometry, columns, text boxes and positioned images are layout instructions rather than content, and reproducing them would need a layout engine.

Explore developer and data tools

Find related browser-local tools for nearby tasks without starting another search.

Browse all developer and data tools

About DOCX to Markdown

Word documents arrive constantly in places where Markdown is the working format: a colleague sends a specification that belongs in the repository, a client supplies copy that has to become a web page, a policy written in Word needs to live in a wiki. Copying and pasting loses the structure and leaves invisible formatting behind; retyping wastes an afternoon. This converter reads the document properly instead. A .docx is a ZIP archive of XML, and Word records structure semantically rather than visually, which means headings really are marked as headings and lists really are marked as lists. That structure is recoverable exactly. What is not recoverable is layout, and being clear about the difference is what separates a converter you can trust from one that produces something you have to check line by line.

Work through the input

  1. The document is unpacked in this tab. Both the ZIP container and the XML inside it are handled here, so no document library needs downloading before you can convert.
  2. Headings are identified from Word's own style definitions, so a paragraph styled Heading 2 becomes a level-two Markdown heading rather than being guessed at from its font size.
  3. Lists are recognised whether Word attached the numbering to the paragraph or to a style such as List Bullet, and nesting depth is preserved. Numbered and bulleted lists are told apart from the document's numbering definitions.
  4. Bold and italic are read from each run, and adjacent runs with identical formatting are merged first. Word splits sentences into runs for its own reasons, and marking each separately would produce broken markers in the middle of words.
  5. Tables become Markdown tables with a header row and separator, and block quotes become quoted lines. Only characters that would change meaning are escaped, so ordinary punctuation stays readable.

When docx to markdown is useful

A specification headed for a repository

Convert, then read through the headings. Anything the author formatted by hand rather than with a heading style will come through as an ordinary paragraph, which is worth fixing at the source.

Client copy for a website

The structure and emphasis survive, which is usually all that is wanted. Check for images, since those need collecting separately.

Check the output

Questions about DOCX to Markdown

Do headings really come through?

Yes, provided they were styled as headings in Word. Text made large and bold by hand looks like a heading to a reader but is an ordinary paragraph to the file, so it converts as one.

What happens to images?

They are omitted. Markdown links to an image file by path, and since there is nowhere to save one, inserting a broken reference would be worse than leaving it out.

Are tables supported?

Yes, as Markdown tables. Merged cells flatten, because a Markdown table has to be rectangular.

Why is my punctuation not escaped?

Deliberately. Escaping every reserved character turns a full stop into an ugly backslash sequence. Only the characters that would actually render as formatting are escaped.

Related tools

DOCX to Text

Pull the plain text out of a Word document in your browser. No formatting, no hidden characters, nothing uploaded.

Markdown to PDF

Convert Markdown into a paginated PDF with headings, lists and code blocks laid out as real text. Runs in your browser.

PDF to Markdown

Turn a PDF into structured Markdown in your browser. Headings are inferred from font size, paragraphs and lists are rebuilt, and no file is ever uploaded.

DOCX to PDF

Convert a Word .docx to PDF locally in your browser, keeping page size, margins, headings, lists, tables and images. No upload, no account, no conversion server.