Mathpix Convert vs docTR
Pick Mathpix Convert when you need math, tables or chemistry from papers and textbooks turned into LaTeX, Markdown or DOCX, and you are fine with a hosted, paid API. Pick docTR when you want a free Apache-2.0 library that runs on your own machine and returns words, lines and coordinates for your own extraction code. The main split is output: Mathpix Convert returns structured STEM documents, docTR returns text with boxes only.
Mathpix Convertmathpix/convert | docTRmindee/doctr | |
|---|---|---|
| Type | OCR API | Open source |
| Price | 7 credits / page | 1 credit / page |
| Per 1,000 pages | $7.00 | $1.00 |
| Typical speed | 1.5 s / page | 0.9 s / page |
| Best for | Math and scientific papers | Word-level OCR with positions |
| Inputs | PDF, images | PDF, images |
| Languages | 30+ languages | Mainly Latin scripts |
| Max pages per request | 500 | 500 |
| Tables | ✓ Yes | No |
| Handwriting | ✓ Yes | No |
| Math | ✓ Yes | No |
| Bounding boxes | ✓ Yes | ✓ Yes |
| Confidence | ✓ Yes | ✓ Yes |
| 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
- You need math, tables or chemistry converted to LaTeX or Mathpix Markdown, including handwritten equations.
- You want whole PDFs exported straight to DOCX or LaTeX.
- You prefer a hosted API with no models or GPUs to run yourself.
Choose docTR if
- You need word-level text with coordinates, returned as nested page, block, line and word JSON.
- You want to self-host under Apache-2.0 on CPU or NVIDIA GPU, with Docker images ready, and pay only for compute.
- You want to pick detection and recognition architectures, use straight or rotated boxes, or train your own models in Python.
Key differences
| Mathpix Convert | docTR | |
|---|---|---|
| Licence | Proprietary | Apache-2.0 |
| How you run it | Hosted API | Python library on PyTorch, run locally, with Docker images (GPU images need CUDA 12.2 or newer on the host) |
| Price | PDF $0.005 per page (0-1M), $0.0035 above 1M; 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 | JSON, plain text, bounding boxes |
| Tables and formulas | Converts math, tables and chemistry | No table, formula or Markdown output; words and lines only |
| Best document types | Math-heavy papers and textbooks, handwritten equations | Invoices and receipts feeding custom extraction |
| Known failure | Images with more than 12 text rows may be billed at the PDF page rate | Cropping images leads to poorer results (issue #2007); split-crop merging can misjoin readings across repeated characters (issue #2229) |
| Public benchmark | Not published on general OCR leaderboards | Not published |
Sources
What each one is
Mathpix Convert
Specialist for math, science papers and handwritten formulas. Outputs LaTeX.
Mathpix Convert detailsdocTR
Open-source OCR library from Mindee with separate text detection and recognition models.
docTR detailsTry both on your own file
Run the file once with each model and compare the output.
Use one, fall back to the other
{"model": "mathpix/convert","fallbacks": ["mindee/doctr"],"file_url": "https://example.com/document.pdf"}Questions
More comparisons
Mathpix Convert alternativesdocTR alternativesBest OCR models in 2026