Skip to content

Passports and the machine-readable zone (MRZ): anonymize them before ChatGPT or sharing

The Passports and the machine-readable zone (MRZ) (International) are passport numbers and the two lines of characters at the bottom of a passport or ID card photo page. They turn up in documents people want to share or give to an AI assistant, and they should never go out as they are.

Two lines of 44 characters (passports), with name, nationality, date of birth, sex, expiry and check digits.

The full identity: name, nationality, date of birth, sex and document number.

Scanned passports and ID cards in onboarding (KYC), travel bookings, rental and hotel registrations, immigration files.

Piixie has a dedicated rule for it, in every model including Lite: it matches the format and checks the control digits, so random numbers of the same length aren’t flagged and real ones aren’t missed. The local LLM also reads the context around it.

With Synthesize, a fake with the same shape and separators, consistent everywhere the same number appears. With Redact, a black box or [REDACTED]; with Replace, a placeholder such as [ID_1].

All of it happens on your computer: the document is never uploaded to find the numbers. See why a local LLM.