AnyDoc by Firecrawl - Convert 14 Office Formats to Markdown (GitHub / Agent Skill / Rust)
AnyDoc is an open-source Rust library by Firecrawl that converts office documents into clean GitHub Flavored Markdown: Word, PowerPoint, Excel, OpenDocument, RTF, EPUB, CSV, PDF — 14 formats through one pipeline, with one consistent, LLM-friendly output no matter which format goes in. The official online version lives at anydoc.wiki (a sister site).
- Fast: single-digit-millisecond conversions — a typical Word doc takes ~4–5ms;
- Local-first: pure Rust, no ML models, no external service calls — files never leave your device;
- Open source: MIT License, source at github.com/firecrawl/anydoc;
- Five bindings + an Agent Skill: Rust / Node.js / Python / browser WASM / CLI, plus a one-command install into AI coding agents.
AnyDoc and this site's pdf-inspector are sister projects released together (see Firecrawl's launch post): pdf-inspector focuses on PDF classification and parsing (project page), AnyDoc covers the other 13 office formats — both exist to feed clean text to LLMs.
AnyDoc on GitHub
The source lives at github.com/firecrawl/anydoc — mostly Rust (98%+), MIT licensed:
git clone https://github.com/firecrawl/anydoc.git
cd anydoc
cargo build --release- Issues: github.com/firecrawl/anydoc/issues — report parsing bugs or request new formats;
- Pull Requests: contributions welcome; new format parsers are the most typical contribution;
- README: full usage and examples for every language binding.
AnyDoc as an Agent Skill (Claude Code / Codex / Cursor)
AnyDoc ships as an Agent Skill for any AI coding agent that speaks the skills protocol. One command:
npx skills add firecrawl/anydocAfter that, agents like Claude Code, Codex, Cursor, and OpenCode automatically invoke anydoc when they hit a .docx, .pptx, or .pdf, convert it to Markdown, and keep working — spec analysis, batch contract review, report summaries, no copy-pasting. Skill marketplace page: skills.sh/firecrawl/anydoc.
One-liner
npx skills add firecrawl/anydoc — after that, your AI agent can read any document.
AnyDoc in Rust
The core is pure Rust with no ML runtime, and the crates.io package is simply anydoc:
cargo add anydocuse anydoc::to_markdown;
let result = to_markdown("report.docx")?;
println!("{}", result.markdown);To track unreleased changes, depend on the Git repository directly:
[dependencies]
anydoc = { git = "https://github.com/firecrawl/anydoc" }Install Anywhere
| Platform | Package | Install / Use |
|---|---|---|
| Rust | anydoc | cargo add anydoc |
| Node.js | @firecrawl/anydoc | npm install @firecrawl/anydoc |
| Python | firecrawl-anydoc | pip install firecrawl-anydoc |
| Browser WASM | @firecrawl/anydoc-wasm | npm install @firecrawl/anydoc-wasm |
| CLI (zero-install) | @firecrawl/anydoc | npx @firecrawl/anydoc report.docx |
| Agent Skill | firecrawl/anydoc | npx skills add firecrawl/anydoc |
Common CLI patterns:
npx @firecrawl/anydoc report.docx # output to terminal
npx @firecrawl/anydoc slides.pptx -o slides.md # output to file
npx @firecrawl/anydoc - --format csv < data.csv # read from stdinThe 14 Supported Formats
- Word:
.doc.docx.docm - PowerPoint:
.ppt.pptx.pptm.pps.ppsx.ppsm.pot - Excel:
.xls.xlsx.xlsm.xlsb - OpenDocument:
.odt.ods.odp - Others:
.rtf,.epub,.csv,.pdf
PDF parsing inside AnyDoc is powered by the built-in pdf-inspector — the library this site is about (introduction): text-based PDFs convert locally in milliseconds, while scanned files come back with a needsOcr flag instead of garbled text.
AnyDoc vs pdf-inspector: which one?
| Need | Pick | Why |
|---|---|---|
| PDF only, with classification & fine-grained control | pdf-inspector (this site) | Millisecond classification, region extraction, selective OCR, confidence routing |
| A mixed pile of Word / PPT / Excel files | AnyDoc | 14 formats to Markdown through one pipeline; PDFs handled by the built-in pdf-inspector |
| Give an AI coding agent document-reading powers | AnyDoc Agent Skill | npx skills add firecrawl/anydoc |
They also stack well: route and fine-tune PDFs with pdf-inspector, let AnyDoc absorb everything else.
Official site & online converter
No install? Convert online at anydoc.wiki: drop a file, get Markdown — runs in your browser via WebAssembly, free and unlimited, nothing uploaded. The experience mirrors this site's online PDF parser.
FAQ
Is AnyDoc free? Open source?
Fully free and MIT licensed, commercial use included. Source at github.com/firecrawl/anydoc; the online version at anydoc.wiki needs no account and charges nothing.
Does AnyDoc handle scanned PDFs?
Not by default — no OCR. Scanned files return a needsOcr flag instead of garbage. For OCR, hand the file to Firecrawl's hosted Parse service (ocr: 'hosted'), or classify first with pdf-inspector and route accordingly.
AnyDoc vs markitdown?
Both convert documents to Markdown, but AnyDoc is pure Rust, millisecond-fast, dependency-free across five bindings with consistent output; markitdown is orders of magnitude slower and flattens heading levels. Full benchmarks are on anydoc.wiki.
What is the CLI command called?
The npm package @firecrawl/anydoc ships a CLI: just npx @firecrawl/anydoc <file>. The Rust build installs an anydoc binary via cargo install anydoc.