OCRRouter

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/doctrGoogle Cloud Vision OCRgoogle/cloud-vision
TypeOpen sourceOCR API
Price1 credit / page2 credits / page
Per 1,000 pages$1.00$2.00
Typical speed0.9 s / page1.0 s / page
Best forWord-level OCR with positionsPhotos and simple scans
InputsPDF, imagesPDF, images
LanguagesMainly Latin scripts100+ languages
Max pages per request5002,000
TablesNoNo
HandwritingNo✓ Yes
MathNoNo
Bounding boxes✓ Yes✓ Yes
Confidence✓ Yes✓ Yes
FormsNoNo
MultilingualNo✓ Yes
On OCRRouterAvailableAvailable

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

docTRGoogle Cloud Vision OCR
LicenceApache-2.0Proprietary
How you run itLocal Python library on PyTorch, with Docker imagesHosted API on Google Cloud, no on-premise option
PriceFree and self-hosted; you pay for computeFirst 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 setupCPU or NVIDIA GPU; GPU Docker images need CUDA 12.2 or newer on the hostNone to manage, but billing must be enabled even for the free 1,000 units
OutputJSON, plain text and bounding boxes in a page, block, line and word hierarchyJSON, plain text and bounding polygons in a page, block, paragraph, word and symbol hierarchy
Tables and MarkdownNo table, formula or Markdown output; words and lines onlyNo table or layout structure and no Markdown; Google points to Document AI for forms and tables
Known failureSplit-crop merging misjoins readings across repeated characters, and cropping images leads to poorer resultsPDF 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 details

Google Cloud Vision OCR

Google Cloud's image OCR with text and document text detection, word boxes and confidence.

Google Cloud Vision OCR details

Try 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": "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