docTR vs Google Cloud Vision OCR
Pick docTR if you run Python, want the code under Apache-2.0, and need word-level text with coordinates on your own hardware. Pick Google Cloud Vision OCR if you want a hosted API with no models to run, need handwriting, or process large volumes of plain text. Neither returns tables or Markdown, so both need extra work for structured documents.
docTRmindee/doctr | Google Cloud Vision OCRgoogle/cloud-vision | |
|---|---|---|
| Type | Open source | OCR API |
| Price | 1 credit / page | 2 credits / page |
| Per 1,000 pages | $1.00 | $2.00 |
| Typical speed | 0.9 s / page | 1.0 s / page |
| Best for | Word-level OCR with positions | Photos and simple scans |
| Inputs | PDF, images | PDF, images |
| Languages | Mainly Latin scripts | 100+ languages |
| Max pages per request | 500 | 2,000 |
| Tables | No | No |
| Handwriting | No | ✓ Yes |
| Math | No | No |
| Bounding boxes | ✓ Yes | ✓ Yes |
| Confidence | ✓ Yes | ✓ Yes |
| Forms | No | No |
| Multilingual | No | ✓ Yes |
| 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 docTR if
- You need to run OCR locally or on your own servers, since docTR is a Python library on PyTorch with Docker images and no per-page fee.
- You want Apache-2.0 licensed code, a choice of detection and recognition architectures, and a key information extraction predictor to build custom extraction for invoices and receipts.
- You want to train or swap your own models, and get a nested page, block, line and word structure with coordinates as JSON.
Choose Google Cloud Vision OCR if
- You want a hosted API with no GPU or CUDA setup, called over REST or client libraries on Google Cloud.
- You need handwriting, which is supported through DOCUMENT_TEXT_DETECTION and language hints.
- You have high volume, because the price falls from $1.50 to $0.60 per 1,000 units above 5M and async batch takes up to 2,000 image files per request.
Key differences
| docTR | Google Cloud Vision OCR | |
|---|---|---|
| Licence | Apache-2.0 | Proprietary |
| How you run it | Local Python library on PyTorch, with Docker images | Hosted API on Google Cloud, no on-premise option |
| Price | Free and self-hosted; you pay for compute | First 1,000 units per month free per feature, then $1.50 per 1,000 units up to 5M, $0.60 per 1,000 above. Each PDF page is one unit. |
| Hardware and setup | CPU or NVIDIA GPU; GPU Docker images need CUDA 12.2 or newer on the host | None to manage, but billing must be enabled even for the free 1,000 units |
| Output | JSON, plain text and bounding boxes in a page, block, line and word hierarchy | JSON, plain text and bounding polygons in a page, block, paragraph, word and symbol hierarchy |
| Tables and Markdown | No table, formula or Markdown output; words and lines only | No table or layout structure and no Markdown; Google points to Document AI for forms and tables |
| Known failure | Split-crop merging misjoins readings across repeated characters, and cropping images leads to poorer results | PDF and TIFF need async processing via Cloud Storage, and you rebuild reading order yourself |
Sources
What each one is
docTR
Open-source OCR library from Mindee with separate text detection and recognition models.
docTR detailsGoogle Cloud Vision OCR
Google Cloud's image OCR with text and document text detection, word boxes and confidence.
Google Cloud Vision OCR 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": "mindee/doctr","fallbacks": ["google/cloud-vision"],"file_url": "https://example.com/document.pdf"}Questions
More comparisons
docTR alternativesGoogle Cloud Vision OCR alternativesBest OCR models in 2026