文件格式任意转换助手Transfer Any File

离线 · 无上传 · 浏览器本地完成Offline · no uploads · runs in the browser

Word 转 Markdown(.docx → .md)——本地完成,不上传Convert Word to Markdown (.docx → .md) locally, no upload

把一份 Word 稿件拉进 Markdown 仓库、Wiki 或静态站点生成器,卡的通常不是「能不能转」,而是「转完还要手改多少」。这条链路是 Word → HTML → Markdown:mammoth 读的是 .docx 的语义结构(标题、列表、表格、链接、图片),turndown 再把它写成 Markdown。它搬的是内容与层级,不是版式——这既是你省下手改格式的原因,也是复杂表格会简化的原因。Getting a Word draft into a Markdown repo, a wiki or a static site generator is rarely blocked by whether it converts at all — it is blocked by how much you re-edit afterwards. This route is Word → HTML → Markdown: mammoth reads the semantic structure of the .docx (headings, lists, tables, links, images) and turndown writes it out as Markdown. It moves content and hierarchy, not layout — which is exactly why your formatting survives, and why an elaborate table arrives simplified.

左右对照的预览与编辑视图
左右对照预览,下载前直接改Preview side by side, edit before you download

这条链路怎么走How the route runs

Word (.docx)Word (.docx) HTMLHTML MarkdownMarkdown

共 2 步,由扩展的路径搜索自动选出,中间产物不落盘。2 steps, chosen by the extension's own path search; intermediate results never touch the disk.

会保留什么What carries over

  • 标题、列表(含嵌套)、加粗与斜体、链接、段落结构,转成对应的 Markdown 语法Headings, lists (nested included), emphasis, links and paragraph structure map onto Markdown syntax
  • 文档内嵌图片会被读出并以 data URI 写进 Markdown,不依赖任何网络——但跟得过去的只有 `png / jpeg / gif / webp / bmp / avif / ico` 这几种位图,TIFF、EMF、WMF 那类在写出 HTML 前就丢了 `src`Embedded images are read out and written into the Markdown as data URIs, with no network involved — but only these raster types travel: `png / jpeg / gif / webp / bmp / avif / ico`; a TIFF, EMF or WMF loses its `src` before the HTML is written
  • 表格转成 Markdown 表格;单元格内容保留,合并信息不保留Tables become Markdown tables: the cell content survives, the merge structure does not
  • HTML 中间产物先经 DOMPurify 净化,文档里的可执行脚本不会带进结果The intermediate HTML passes through DOMPurify, so executable markup in the document is not carried over

如实说明的限制What it does not do

  • 页眉页脚、批注、修订记录、目录域、分栏、文本框不进 Markdown——它们本来也不是 Markdown 能表达的东西Headers and footers, comments, tracked changes, table-of-contents fields, columns and text boxes do not come across — Markdown has no way to express them
  • data URI 图片会让 .md 文件明显变大;要提交进 Git 的话,建议转完再用工具把图片外链化data URI images make the .md noticeably heavier; externalise them again before committing to Git
  • 老式 .doc(97-2003 二进制)不在支持的 14 种格式里,先在 Word 里另存为 .docx 再转Legacy .doc (97-2003 binary) is outside the 14 supported formats, so save it as .docx first

实操提示Working with it

  • 一次最多 200 个文件;多份 .docx 批量转,结果按文件名逐个产出,也可以一次拿 ZIPUp to 200 files in one run; batch a set of .docx and take the results individually or as one ZIP
  • 同一份文档可以先转成 HTML 预览效果,再决定要不要落成 MarkdownThe same document can go to HTML first, so you can see the structure before committing to Markdown

常见问题Questions people actually ask

为什么我的表格变简单了?Why did my table lose its shape?

Word 的合并单元格在 HTML 这一步已经无法无损表达,turndown 能写的就是普通行列。需要保住原版的排版,请改用 Word → PDF(那是渲染快照,不是结构化表格)或 Word → HTML。Merged cells cannot survive the HTML hop losslessly, so what turndown writes is a plain grid. If the layout itself is the point, use Word to PDF (a rendered snapshot, not a table) or Word to HTML instead.

转换会保留图片吗?Are the images preserved?

会,内嵌图片以 data URI 形式写在 Markdown 里,因此离线也拿得到。代价是 .md 体积明显变大。Yes — embedded images are written into the Markdown as data URIs, so they survive without any network. The price is a noticeably heavier .md.

加密或损坏的 .docx 会怎样?What happens to an encrypted or broken .docx?

读取失败就在界面上给出该文件的错误提示,批次里其余文件继续转——单个失败不会中断整批。A file that cannot be read reports its own error in the UI while the rest of the batch continues; one failure never aborts the run.

不需要账号,也不需要联网:装好扩展后点图标,在新标签页里打开工作台,文件从磁盘直接选。No account and no network: install the extension, click its icon, and the workbench opens in a new tab reading straight off your disk.