Passport OCR API
Extract passport number, full name, nationality, birth and expiry dates, and TD3 MRZ validation from ICAO-compliant passports worldwide. Automate fintech KYC, airline check-in, and immigration workflows.


Try it out
Experience the power of our OCR. Upload a document and see the results instantly.
Drop document or click to upload
Supports PDF, PNG, JPG (max 10MB)
By uploading a document, you agree to our terms. We do not store your data.
Type of passport (e.g., P for Personal, D for Diplomatic, S for Service)
Whether the document type has been verified against the MRZ
The 3-letter ISO 3166-1 alpha-3 code of the issuing state
Whether the country code has been verified against the MRZ
Unique alphanumeric identifier for the passport booklet
Whether the passport number has been verified against the MRZ
Primary identifier or family name
Whether the surname has been verified against the MRZ
Secondary identifier, including first and middle names
Whether the given names have been verified against the MRZ
The citizenship of the passport holder (ISO 3166-1 alpha-3)
Whether the nationality has been verified against the MRZ
Holder's date of birth (YYYY-MM-DD)
Whether the date of birth has been verified against the MRZ
Standardized as M (Male), F (Female), or X (Unspecified/Non-binary)
Whether the sex has been verified against the MRZ
The date the document becomes valid (YYYY-MM-DD)
Whether the date of issue has been verified (usually not in MRZ)
The date the document is no longer valid (YYYY-MM-DD)
Whether the date of expiry has been verified against the MRZ
The government body, office, or ministry that issued the document
Whether a Machine Readable Zone (MRZ) was detected
City, state, or country of birth
The specific city or consulate where it was issued
The holder's domestic identity code (e.g., DNI, PESEL)
Whether the national ID number has been verified against the MRZ (if present in optional data)
Physical height of the individual
The holder's eye color
The holder's job title or employment status
Common questions
Quick answers to common questions about our Passport OCR API.
What types of passports are supported?
This extractor supports all international passports following ICAO standards, including Personal (P), Diplomatic (D), and Service (S) passports.
Does it support MRZ (Machine Readable Zone)?
Yes, it fully supports TD3 MRZ format used in passports for data verification and high-accuracy extraction.
Which fields are extracted?
It extracts all mandatory fields (name, dates, passport number, nationality) as well as common optional fields like place of birth, height, and eye color when present.
Integrate our API in seconds
Start extracting data from your documents in seconds with our ready-to-use OCR API.
curl -X POST "https://api.tiny-idp.com/api/extractors/run/passport" \ -H "x-api-key: YOUR_API_KEY" \ -F "files=@/path/to/your/document.jpg"
const formData = new FormData();
const fileInput = document.querySelector('input[type="file"]');
formData.append('files', fileInput.files[0]);
const response = await fetch("https://api.tiny-idp.com/api/extractors/run/passport", {
method: 'POST',
headers: {
'x-api-key': 'YOUR_API_KEY'
},
body: formData
});
const result = await response.json();
console.log(result);import requests
url = "https://api.tiny-idp.com/api/extractors/run/passport"
headers = {"x-api-key": "YOUR_API_KEY"}
files = {"files": open("document.jpg", "rb")}
response = requests.post(url, headers=headers, files=files)
print(response.json())<?php
$ch = curl_init();
curl_setopt_array($ch, [
CURLOPT_URL => "https://api.tiny-idp.com/api/extractors/run/passport",
CURLOPT_POST => true,
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'x-api-key: YOUR_API_KEY',
'Accept: application/json'
],
CURLOPT_POSTFIELDS => [
'files' => new CURLFile('/path/to/your/document.jpg')
]
]);
$response = curl_exec($ch);
curl_close($ch);
echo $response;Integrate with your coding agent
Copy instructions for Claude Code, Cursor, ChatGPT, and other agents to integrate Tiny IDP.
Ready to build?
Get your free API key and start extracting data from documents in minutes. No credit card required for the free tier.
Common use cases
Discover how businesses are using our OCR API to automate their workflows.
Fintech KYC & account opening
Capture passport number, names, nationality and expiry in one API call to pre-fill KYC forms and cut drop-off in neobank and remittance onboarding.
Travel & border check-in
Parse TD3 MRZ and visual zone fields for airline self-check-in, hotel guest registration, and travel-tech identity capture flows.
Corporate travel compliance
Verify employee passport data against booking profiles for duty-of-care, visa expiry alerts, and expense policy automation.
Immigration & visa portals
Feed structured passport JSON into e-visa, residence-permit, and consular appointment systems without manual re-keying.
Simple, Transparent Pricing
No hidden fees. No monthly minimums. Pay only for what you extract.
Usage-Based
Simple pay-as-you-go pricing. No monthly commitment.
- Unlimited extractors
- Pre-built & custom extractors
- OCR and AI technology
- GDPR compliant
- EU-hosted infrastructure
- Standard support
Enterprise
Tailored pricing for high-volume scenarios. Get SLA guarantees, on-premise deployment, and dedicated support — reach out and we'll put together a plan that fits your scale.
- Custom pricing models
- SLA guarantees
- On-premise deployment options
- Custom integration support
- 24/7 dedicated support
- Priority feature requests
All prices exclude VAT. Volume discounts apply automatically.
Enterprise-grade Compliance & Security
We take data privacy seriously. Tiny IDP is built from the ground up to meet the strictest European data protection standards.
Zero Data Retention
We don't store your documents, images, or predictions. Data is processed in-memory and immediately discarded.
GDPR Compliant
Full compliance with European data protection regulations (GDPR) for your peace of mind.
EU-Based Infrastructure
All data is processed and hosted exclusively in secure European data centers.
Do you need a custom OCR?
Need custom document extraction? Define your own JSON schema to extract structured data from any document format in seconds.