Passport OCR API
4.8/5
(30+ reviews)
Passport OCR API that reads the MRZ and every visual field
Turn a passport photo or scan into structured JSON in seconds. Names, passport number, nationality, dates and both MRZ lines, each with a confidence score. No template per country, no rules to maintain.
No credit card required
SOC 2 Type II & GDPR

Trusted by finance and product teams at




Why passport data slows onboarding down
Every country prints its passports differently, and customers upload glare-filled phone photos. Generic OCR trips on the MRZ, so an agent ends up retyping names and dates, then checking them twice.
Passport uploaded
Photo or scan sent through the sign-up flow.
Manual review
Names, number and dates retyped from the data page.
Friction
Glare and blur trigger a new upload request.
Cross-check
Data compared with the form and other documents.
Friction
Transliterated names rarely match on the first try.
Compliance check
KYC file approved or sent back for missing details.
Friction
Each back-and-forth gives the customer a reason to leave.
Account opened
Finally active, days after the customer signed up.
Every passport field, from the data page to the MRZ
Hover a group to see where it sits in the JSON response. Dates come back in ISO format, and each value is located on the data page.
See fields list
Holder
surnames, given_names
Birth
date_of_birth, place_of_birth, sex
Passport
passport_number
Validity
date_of_issue, date_of_expiry
Country
issuing_country, nationality
MRZ
mrz_line_1, mrz_line_2
{
"surnames": { "value": "MARTIN" }, "given_names": { "value": "CLAIRE ANNE" },
"date_of_birth": { "value": "1990-03-15" }, "place_of_birth": { "value": "LYON" }, "sex": { "value": "Female" },
"passport_number": { "value": "24FV81726" },
"date_of_issue": { "value": "2024-09-29" }, "date_of_expiry": { "value": "2034-09-28" },
"issuing_country": { "value": "FRA" }, "nationality": { "value": "FRA" },
"mrz_line_1": { "value": "P<FRAMARTIN<<CLAIRE<ANNE<<<<<<<<<<<<<<<<<<<<" }, "mrz_line_2": { "value": "24FV817265FRA9003154F3409286<<<<<<<<<<<<<<02" },
}
Ready to post, not just to read.
Dates come back in ISO 8601, sex as Male, Female or Other, and both MRZ lines as raw text. Every field carries a confidence score and its position on the page.
Built for real passport photos, not lab scans
Glare on the laminate, a thumb over the corner, a data page shot at an angle on a kitchen table. The model reads the passport photos your users actually take.

Any country, one schema
A passport from a country you have never onboarded comes back in the same JSON shape. No template to add per issuing country.

MRZ and data page, side by side
Both MRZ lines come back as raw text next to the printed fields, so you can compare them in your own checks.

Glare and blur, still read
Phone photos with glare on the laminate or a slight tilt are still read, and low-confidence values are flagged for review.

Passport, ID card or licence, sorted
Mixed uploads are classified first, so each passport, ID card or driver licence is sent to the right extraction model.
PDF / JPEG / PNG / WEBP / TIFF / HEIC, Phone photos & scans, Any issuing country, Latin and non-Latin scripts, Multi-page PDFs
Passport OCR accuracy, visible on every value
Each field comes with a confidence score, so clear values pass straight through and doubtful ones go to a reviewer. Test it on your own passports during the free trial.
96.1%
Field-level accuracy on key fields
Names, number, dates, nationality
99.8%
Accuracy on MRZ lines
Both lines, character by character
0.8s
Median time per passport
Single image, synchronous call
A confidence score on every field
Send only real exceptions to a human

Document AI features, better than OCR
Prepare, classify and extract. Mindee delivers high-accuracy extraction for every document format, so you can automate workflows with speed and high reliability.
Data extractor
Classifier
Splitter
Edge detector
Pull the exact fields you need from any document
Pick a ready-made model or describe your own data schema. Every value comes back typed, normalised, located on the page and scored.
- Prebuilt models or your own custom schema
- Tables and line items, across pages
Know what each document is before you read it
The classifier labels every upload with your own classes, so an ID card goes to onboarding and an invoice goes to accounts payable.
- Your own document classes
- Route each type to the right model
One scanned batch in, separate documents out
Send a long PDF from the office scanner. Mindee finds where each document starts and ends, and returns them one by one.
- Page ranges for every detected document
- Up to 200 pages and 100 MB per file
Several documents on one photo? Each gets its own crop
Users photograph three receipts on a desk, or both sides of an ID. Mindee detects each border, returns its coordinates and reads them separately.
- Coordinates for every detected document
- Built for mobile capture flows
Prototype in minutes, go live with the API
Step 1 : Prototype
Run a proof of concept in Make, Zapier or n8n
No code, no IT ticket. Point a mailbox at Mindee and watch the data arrive in a spreadsheet.
Passport uploaded
From your sign-up form or mobile app
Mindee extracts the passport
Names, number, dates, MRZ
Customer profile pre-filled
HubSpot, Salesforce, your KYC tool…
Low-confidence fields sent for review
Slack or email alert to your team
Step 2 : Production
Integrate the API into your platform
Official SDKs, typed responses and webhooks for async processing. Most teams ship the integration in a day.
mindee docs
$ pip install mindee
Your app
Mindee API
Your ERP/CRM
.webp)
Integrate Mindee into your workflow in minutes with SDKs & no-code tools
Go live in minutes using our verified Zapier & Make.com app with zero coding, or integrate seamlessly via our well-documented REST API built for developers. SDKs available for Python, .NET, Node.JS, Java, Ruby, PHP.
Integrations

Enterprise-grade security
Our API has a SOC 2 Type II certified infrastructure and is GDPR Compliant to ensure your file information remains protected at all times.
EU or US hosting available
GDPR, CCPA Compliant
Learn more
What teams build with passport OCR
The same API powers very different products. Here is where it usually starts.

Banking & lending
Insurance
Onboarding client/KYC
Verify identity and proof of address in real time, without slowing down sign-up.

Banking & lending
Real estate
Loan requests
Pre-fill loan applications from payslips, tax returns and bank statements.

Real estate
Tenant screening
Check a renter’s identity, income and tax documents in one application file.

HR
Candidate application
Parse resumes and ID documents into structured candidate profiles.
Rated 4.8/5 by developers and onboarding teams
4.8
4.9
Mindee is a web based tool that help us in scanning and reading different type of documents like identity cards, invoices, proposal plans etc and extract all the information with its AI and then it provides all the information and data associated with these documents a structured way.
Mindee is a web based tool that help us in scanning and reading different type of documents like identity cards, invoices, proposal plans etc and extract all the information with its AI and then it provides all the information and data associated with these documents a structured way.
Mindee works reliably and delivers good performance. The OCR data is accurate, and the API is stable. It works like a charm.
Excellent. In addition to their great product, the sales team has always been proactive on how they could help us leverage the maximum results from their product. It was like having an additional product manager on our side
Documents related that Mindee reads
FAQ about Mindee's Passport OCR API
Can't find what you're looking for? Our team answers within one business day.
What is the MRZ on a passport, and does Mindee read it?
The MRZ (Machine Readable Zone) is the block of two lines of characters at the bottom of a passport’s photo page. Defined by the ICAO international standard, it encodes the holder’s key details in a format machines can read: document type, issuing country, name, passport number, nationality, date of birth, sex and expiry date, plus check digits that detect reading errors. Mindee reads both the MRZ and the printed fields on the page (the visual zone) and returns them as structured JSON. You can then compare the two sources to catch inconsistencies or typing errors.
Does Mindee work with passports from every country?
Yes. Passports from all countries follow the same ICAO format for the photo page and the MRZ, so Mindee can extract data from passports worldwide, whatever the language or alphabet of the printed fields. The MRZ always uses Latin characters, which means names are returned in a consistent, searchable format even when the visual zone is written in Cyrillic, Arabic or Asian scripts.
Does Mindee verify that a passport is authentic?
Mindee focuses on data extraction. It turns a passport image into accurate, structured data in seconds, but it doesn’t perform forgery detection, chip (NFC) reading or liveness checks. In a KYC or onboarding flow, Mindee typically handles the step where data is captured and pre-filled, and works alongside a dedicated identity verification provider. Confidence scores and consistency between the MRZ and the printed fields also help you flag suspicious or poor-quality captures for manual review.
Is it safe to process passports with an OCR API instead of a general AI chatbot?
A passport contains highly sensitive personal data, so where it is processed matters. Sending passport photos to a general-purpose AI chatbot can mean your data is stored or used under terms you don’t control. Mindee is built for identity document processing: it is SOC 2 Type II certified and GDPR compliant, data is encrypted in transit and at rest, and you control how long documents are retained. You also get consistent, structured output with confidence scores, instead of free-text answers that might guess a passport number or a date.
About Mindee
Is my data secured and protected during the conversion process?
Yes, your data is highly secured and protected during the entire conversion process. As an enterprise-grade OCR solution, Mindee takes data privacy very seriously. Here are the key security measures in place:
- Certified compliance: Mindee's infrastructure is SOC 2 Type II certified and fully GDPR compliant, ensuring strict industry standards for data protection.
- Encryption: All documents and extracted data are fully encrypted both in transit (during the API call) and at rest.
- Data localization: You have control over where your data is processed, with the option to host and process your data on either EU or US servers.
- Strict privacy: Mindee respects data confidentiality. Your processed documents are not shared with third parties, and your private data is not used to train global AI models.
In short, your sensitive documents are processed in a secure, isolated environment and remain completely under your control.
Is Mindee's OCR API free to use?
We provide a 14 days free trial so you can fully test any of our OCR models — no credit card required. After this, we offer different pricing tiers depending of the volume of pages processed and the features you might need. See the pricing page for more information.
What file formats are supported for JSON conversion?
The supported document formats are:
- PDF (
application/pdf) – While technically a document format rather than an image, it is natively supported for all extraction models. - JPEG / JPG (
image/jpeg) - PNG (
image/png) – Must be non-animated. - WebP (
image/webp) - TIFF / TIF (
image/tiff) – Both single-page and multi-page TIFFs are supported and processed similarly to PDFs. - HEIC (
image/heic) – Apple's High-Efficiency Image Container format.
📌 Important technical limitations to keep in mind:
To ensure the OCR pipeline runs smoothly and successfully returns your JSON, make sure your files adhere to the following constraints:
- Maximum file size: 100 MB per file.
- Maximum page count: Up to 200 pages per document.
- File state: The files cannot be encrypted, and PDFs must not be password-protected.
Ready to stop retyping passport details?
Plug the passport OCR API into your onboarding flow in minutes, with a team of document processing engineers behind it.
14-day free trial
No credit card required