Mathpix Convert vs Docling
Pick Mathpix Convert when the job is math-heavy papers, textbooks or handwritten equations that must come out as LaTeX or DOCX, and you accept a hosted API with per-page billing. Pick Docling when you want a free, MIT-licensed library that runs on your own machine and turns born-digital PDFs and Office files into structured JSON for RAG. The main split is hosted STEM conversion versus self-hosted general ingestion.
Mathpix Convertmathpix/convert | Doclingibm/docling | |
|---|---|---|
| Type | OCR API | Open source |
| Price | 7 credits / page | 2 credits / page |
| Per 1,000 pages | $7.00 | $2.00 |
| Typical speed | 1.5 s / page | 2.2 s / page |
| Best for | Math and scientific papers | Structured export for RAG |
| Inputs | PDF, images | PDF, images, DOCX |
| Languages | 30+ languages | Latin scripts, CJK |
| Max pages per request | 500 | 500 |
| Tables | ✓ Yes | ✓ Yes |
| Handwriting | ✓ Yes | No |
| Math | ✓ Yes | ✓ Yes |
| Bounding boxes | ✓ Yes | ✓ Yes |
| Confidence | ✓ Yes | No |
| Forms | No | No |
| Multilingual | No | No |
| On OCRRouter | Available | Available |
Prices are what you pay on OCRRouter. Speed is the provider's typical figure, not a benchmark we ran.
Which to choose
Choose Mathpix Convert if
- It is built for STEM content: math, tables and chemistry become LaTeX and Markdown.
- It exports whole PDFs straight to DOCX or LaTeX.
- It handles handwritten equations, which are listed among its good uses.
Choose Docling if
- It is MIT licensed and free to self-host, so you only pay for compute.
- One API parses PDF, DOCX, PPTX, XLSX, HTML, EPUB, images, emails and XBRL.
- Lossless JSON export keeps layout, reading order and table structure for downstream tools.
Key differences
| Mathpix Convert | Docling | |
|---|---|---|
| How you run it | Hosted API | Python library that runs locally on macOS, Linux and Windows; CPU works, GPU speeds up model stages |
| Licence | Proprietary | MIT (individual models have their own licenses) |
| Price | PDF $0.005 per page up to 1M pages, then $0.0035; images $0.002 each; one-time $19.99 API key activation fee | Free, self-hosted (you pay for compute) |
| Output formats | LaTeX, Markdown, DOCX, HTML, JSON | Markdown, HTML, JSON, DocTags, plain text |
| Input types | Images and PDFs with math, tables and chemistry | PDFs, Office files, HTML, EPUB, images, emails and XBRL |
| Benchmarks | Not published on general OCR leaderboards | Not published |
| Known failure | Images with more than 12 text rows may be billed at the PDF page rate | OCR regression in 2.143.1 drops words and numbers with full-page Tesseract OCR (issue #5254); reading order can merge neighbouring columns (issue #5132) |
Sources
- Mathpix billing docs
- Mathpix OCR API
- Docling GitHub README
- Supported formats
- Issue #5254 OCR regression
- Issue #5132 reading order
What each one is
Mathpix Convert
Specialist for math, science papers and handwritten formulas. Outputs LaTeX.
Mathpix Convert detailsTry both on your own file
Run the file once with each model and compare the output.
PDF, PNG, JPG, WebP, HEIC. Up to 20 MB each, 10 files.No file?
Use one, fall back to the other
{"model": "mathpix/convert","fallbacks": ["ibm/docling"],"file_url": "https://example.com/document.pdf"}Questions
More comparisons
Mathpix Convert vs TesseractMathpix Convert vs MinerUReducto Parse vs DoclingLlamaParse vs DoclingPaddleOCR-VL vs DoclingMinerU vs DoclingDocling vs TesseractMathpix Convert vs Pixtral
Mathpix Convert alternativesDocling alternativesBest OCR models in 2026