# Extract Passport Data > Passport OCR API for any country: extract the passport number, names, nationality, dates, and MRZ in seconds, with ICAO 9303 validation. 20 free extractions. The Extract Passport Data API lets you extract data from passports of any country programmatically. It uses artificial intelligence to process the images, extract every field on the data page, and validate the MRZ with the ICAO 9303 check digits. - **Official site:** https://extractpassportdata.com - **API base URL:** https://extractpassportdata.com/api/v1 - **Authentication:** An `X-API-Key` header carrying a key that starts with `pass_`, issued from the dashboard - **Input:** A JPEG, PNG or WebP image (10 MB max) as multipart/form-data, base64 JSON, a remote URL, or a raw binary body - **Output:** Structured JSON - **Fields extracted:** 14 — passportNumber, surname, givenNames, nationality, dateOfBirth, sex, placeOfBirth, dateOfIssue, dateOfExpiry, issuingCountry, issuingAuthority, personalNumber, mrzLine1, mrzLine2 - **Free trial:** 20 extractions on sign-up, no card required - **Billing model:** Prepaid tokens, 1 token per extraction, no subscription and no expiry; an extraction that fails on a system error is refunded automatically - **Price (Mexican VAT included):** from $0.05 USD per extraction - **Language and market:** en · US - **Contact:** support@extractpassportdata.com ## API - [API documentation](https://extractpassportdata.com/docs): Passport OCR API documentation: endpoints, authentication, upload methods, and JavaScript, Python, and PHP examples for reading the passport MRZ. - [Full plain-text reference](https://extractpassportdata.com/llms-full.txt): Endpoints, examples, fields, prices and FAQ in a single markdown file - [Create an account and get an API key](https://extractpassportdata.com/register): 20 free extractions, no card required ## Product - [Extract Passport Data](https://extractpassportdata.com): Passport OCR API for any country: extract the passport number, names, nationality, dates, and MRZ in seconds, with ICAO 9303 validation. 20 free extractions. - [Pricing](https://extractpassportdata.com/pricing) - [Free demo](https://extractpassportdata.com/free-demo): Try it without an account ## Free tools - [MRZ Validator](https://extractpassportdata.com/mrz-validator): Paste the two MRZ lines and verify their ICAO 9303 check digits. - [Passport Validity Checker](https://extractpassportdata.com/passport-validity-checker): Check whether a passport satisfies the six-month rule for a given trip. - [Check digit calculator](https://extractpassportdata.com/check-digit-calculator): Compute the 7-3-1 check digit for one MRZ field and see the arithmetic. - [ICAO country codes](https://extractpassportdata.com/icao-country-codes): Look up which country — or which other thing — a three-letter MRZ code names. - [Sample MRZ generator](https://extractpassportdata.com/mrz-generator): Build valid example MRZ lines to test your integration against. ## Solutions by industry - [Hotels](https://extractpassportdata.com/hotels): Capture a foreign guest passport from one photo instead of typing it: a shorter front-desk queue and names spelled right the first time in your PMS. - [KYC and compliance](https://extractpassportdata.com/kyc-foreign-clients): Feed passport data into your foreign client identification file: fields verified against the document itself, and dated evidence the read was checked. - [Travel agencies](https://extractpassportdata.com/travel-agencies): Take each passenger passport from one photo into the booking and the ticket. Names identical to the document, and fewer paid name corrections after issue. - [Car rental](https://extractpassportdata.com/car-rental): Read a foreign driver passport from one photo and fill the rental agreement without typing: faster handovers and details identical to the document. ## Guides - [Blog](https://extractpassportdata.com/blog): Learn about passport data extraction, MRZ reading, ICAO 9303 validation, travel-document OCR, and KYC automation. - [The US Passport: Fields, Versions and How to Read It](https://extractpassportdata.com/blog/us-passport-fields-and-versions): The US passport data page: its fields, how the name is encoded in the MRZ, why the passport card uses a different MRZ format, and what e-passports change. - [Automating Hotel Guest Check-in by Scanning the Passport](https://extractpassportdata.com/blog/hotel-guest-check-in-passport-scanning): How to cut international guest registration to seconds by reading the passport: what to capture, how to integrate with your PMS, and how to design the flow. - [How to Choose a Passport OCR API: 9 Evaluation Criteria](https://extractpassportdata.com/blog/choosing-a-passport-ocr-api): How to choose a passport reading API: MRZ validation, failure behaviour, data retention, pricing model, and how to test each before you commit. - [MRZ Formats: TD1, TD2 and TD3 (Differences and Detection)](https://extractpassportdata.com/blog/mrz-formats-td1-td2-td3): The ICAO 9303 MRZ formats TD1, TD2 and TD3: how many lines each has, which documents use them, where the fields differ, and how to detect the format. - [How to Check Passport Validity (and the Six-Month Rule)](https://extractpassportdata.com/blog/how-to-check-passport-validity): How to check automatically whether a passport is valid, why many countries require six months of remaining validity, and how to use the MRZ expiry date. - [Common Passport Scanning Errors (and How to Avoid Them)](https://extractpassportdata.com/blog/common-passport-scanning-errors): The real reasons automated passport reading fails — glare on the laminate, a cropped MRZ, insufficient resolution — and how to fix each one at capture time. - [Passport KYC: Automating Identity Verification in the US](https://extractpassportdata.com/blog/passport-kyc-identity-verification): How to build a customer identification file from a passport: what data to capture, how to keep auditable evidence of the read, and what to automate. - [How to Integrate a Passport OCR API (Complete Guide with Code)](https://extractpassportdata.com/blog/integrate-passport-ocr-api): Step-by-step integration of a passport data extraction API: the four image upload methods, every error code, and examples in JavaScript, Python and PHP. - [ICAO 9303 Check Digits: How They're Calculated (with Code)](https://extractpassportdata.com/blog/icao-9303-check-digits-explained): The 7-3-1 MRZ check digit algorithm step by step, with the arithmetic on a real passport, the blind spot nobody mentions, and JavaScript and Python code. - [How to Read a Passport MRZ Line by Line (Position Map)](https://extractpassportdata.com/blog/how-to-read-the-mrz-line-by-line): A map of all 88 MRZ positions on a passport: what every character holds, how names and dates are encoded, and how to decode one by hand. - [How to Extract Passport Data Automatically (OCR + MRZ)](https://extractpassportdata.com/blog/how-to-extract-passport-data-automatically): A complete guide to extracting data from passports of any country with OCR: what the MRZ is, how ICAO 9303 check digits work, and how to integrate it via API. ## Legal - [Security and data handling](https://extractpassportdata.com/security) - [Privacy policy](https://extractpassportdata.com/privacy) - [Terms of service](https://extractpassportdata.com/terms) - [Contact](https://extractpassportdata.com/contact)