OCRRouter

MRZ OCR

Read the two or three lines of chevrons at the bottom of passports, ID cards and visas, parse them into fields and check every check digit.

PDF, PNG, JPG, WebP, HEIC. Up to 10 files at onceNo file?

What makes machine-readable zones hard to read

  • 0 and O, 1 and I, 8 and B that a single wrong digit breaks
  • OCR-B font printed small under laminate
  • Three formats: TD1 ID cards, TD2 and TD3 passports

Fields coming with document_type

200mrz fields
{"format": "TD3","line_1": "P<UTOERIKSSON<<ANNA<MARIA<<<<<<<<<<<<<<<<<<<","line_2": "L898902C36UTO7408122F1204159ZE184226B<<<<<10","document_number": "L898902C3","nationality": "UTO","date_of_birth": "1974-08-12","expiry_date": "2012-04-15","check_digits_valid": "true"}

Best models for machine-readable zones

Call it from your code

curl https://api.ocrrouter.ai/v1/ocr \
  -H "Authorization: Bearer $OCRROUTER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "azure/document-intelligence",
    "file_url": "https://example.com/invoice.pdf",
    "format": "json"
  }'

Questions

Free tools

Other documents