What Is pdf-inspector? (And How to Use It Online, No Code Required)
pdf-inspector is an open-source Rust library by Firecrawl that classifies PDFs and converts native-text documents into clean, structured Markdown — in milliseconds. Released in 2026, it quickly became one of the most talked-about tools in the document-parsing space, billed as the fastest PDF parser engine available. It can even run entirely inside your browser via WebAssembly.
pdf-inspector in 30 Seconds
- What: Rust engine that classifies PDFs and converts text-based ones to Markdown
- By: Firecrawl (MIT license, fully open source)
- Install:
npm install @firecrawl/pdf-inspectororpip install pdf-inspector - GitHub: firecrawl/pdf-inspector
- Speed: Milliseconds per document; ~200 pages in under half a second in-browser
- Use case: RAG pipelines, AI agents, and any workflow that needs PDF to Markdown at scale
What pdf-inspector Actually Does
Three things, all fast:
- Classification — in roughly 10–50ms it tells you whether a PDF is text-based, scanned, image-based, or mixed, with a confidence score and per-page routing hints. This matters because roughly half of real-world PDFs have a native text layer and never need expensive OCR.
- Extraction — position-aware text with font information and coordinates.
- Markdown conversion — headings (inferred from font sizing), lists, tables, code blocks, bold and italics.
The classification step is the quietly clever part: it lets a pipeline route each document to the cheapest path that works — direct parsing for text PDFs, OCR only for the pages that truly need it.
How to Use pdf-inspector (Code)
Node.js
npm install @firecrawl/pdf-inspector
import { processPdf } from '@firecrawl/pdf-inspector';
import { readFileSync } from 'fs';
const result = processPdf(readFileSync('document.pdf'));
console.log(result.pdfType); // "TextBased", "Scanned", ...
console.log(result.markdown);
Python
pip install pdf-inspector
import pdf_inspector
result = pdf_inspector.process_pdf_bytes(open("document.pdf", "rb").read())
print(result.markdown)
In the Browser (WASM)
import init, { processPdf } from '@firecrawl/pdf-inspector-wasm';
await init();
const pdf = new Uint8Array(await file.arrayBuffer());
const { markdown } = processPdf(pdf);
Is There a pdf-inspector Online? (Using It Without Code)
Yes — two ways.
Firecrawl hosts a minimal demo page, but if you want a full converter, file2markdown's PDF to Markdown tool runs pdf-inspector as its production engine. Upload a PDF, get structured Markdown back near-instantly, no signup required. That is not a marketing metaphor: our backend literally calls pdf-inspector for every text-based PDF.
Using file2markdown instead of the raw library also fills pdf-inspector's two gaps:
- Scanned PDFs. pdf-inspector deliberately does no OCR — it classifies a scan and stops. file2markdown routes those pages to AI-powered OCR automatically. (More in our scanned PDF guide.)
- Other formats. pdf-inspector is PDF-only. file2markdown also converts DOCX, PPTX, XLSX, images, and more.
What pdf-inspector Is Not
It is not an OCR tool, not a general document converter, and not a layout-analysis model. Multi-column academic papers can come out with scrambled reading order — for those, an AI-layout tool like Docling still wins on accuracy (see our full pdf-inspector vs Docling comparison). And for scanned archives you want a vision pipeline like Marker (pdf-inspector vs Marker).
How It Compares
| Tool | Speed | Structure | OCR | Formats |
|---|---|---|---|---|
| pdf-inspector | Milliseconds | Good | No (classify-only) | |
| MarkItDown | Seconds | Flat text on PDFs | Limited | Many |
| Docling | Minutes | Best-in-class | Yes | Several |
| Marker | Seconds–minutes | Excellent | Yes (deep learning) |
Full breakdowns: pdf-inspector vs MarkItDown and the ranked best PDF to Markdown converters in 2026.
Frequently Asked Questions
Is pdf-inspector free?
Yes — MIT licensed, free for commercial use, on npm, PyPI, and crates.io.
Can pdf-inspector convert scanned PDFs?
No. It detects that a PDF is scanned (very quickly and accurately) but performs no OCR. Use a hosted converter with OCR — file2markdown handles scans automatically — or pair it with an OCR pipeline.
Does pdf-inspector work in the browser?
Yes. The WASM build parses PDFs fully client-side — around 200 pages in under half a second — with no server involved.
What does file2markdown add on top of pdf-inspector?
Automatic OCR for scanned pages, support for every other document format, a no-code web interface, and a REST API for batch pipelines. Same engine, none of the integration work.
Get Started
Try it without installing anything: drop a PDF into the free PDF to Markdown converter. If you are building your own pipeline, start with the GitHub repo — and read our comparison posts to know when a different tool fits better.
The Markdown Memo
A fortnightly note for lawyers, researchers, accountants, and anyone else drowning in PDFs, scans, and decks. No spam.