Hide Passport MRZ Numbers on Uploads (Blackout Edits)
Before uploading a passport image, confirm the recipient does not need the machine-readable zone (MRZ). If it is not required, remove both full MRZ lines with a true PDF redaction or by changing the image pixels. Save a separate copy, then reopen and test it. A black shape that only covers text is not safe redaction.
A passport upload can expose more than the visible name and photo. The MRZ at the bottom of the identity page contains encoded information that a phone or computer can read. If a pet’s name, travel details, or other personal notes appear in the same photo, crop them out too; they do not belong in a passport upload.
I treat redaction as a file-editing task, not a drawing task. The aim is to give the recipient what they need while removing data they do not need. I keep the original in a private location, work on a copy, and verify the finished file before sending it.
Plan the redaction before editing
A safe redaction starts with a simple check: does the recipient need to see or scan the MRZ? The machine-readable zone, or MRZ, is the printed code area on a passport identity page. Requirements vary by service, so check the upload instructions or ask the recipient before removing it.
Some identity checks may require an unaltered passport image. Redacting the MRZ could cause the upload to be rejected or prevent a check from working. Do not assume that a service needs less information, or that it accepts edited documents. If the instructions are unclear, ask what can be covered and whether another document is acceptable.
Keep an untouched original only if you have a valid reason to retain it, and store it securely. Make a separate working copy so you do not accidentally change the only original. Give the upload a plain, accurate filename, such as passport-redacted.pdf, and avoid putting passport numbers or names in the filename.
The principle is data minimization: share only the information needed for the stated purpose. This does not mean removing details at random. Preserve any fields the recipient requires, and redact only what they agree is not needed.
Know what the MRZ contains and what to cover
A standard TD3 passport MRZ has two lines, with 44 character positions on each line. ICAO Doc 9303, Part 4 defines this layout. Each line includes characters and filler marks, so covering a few digits is not enough to remove the zone.
Cover both complete lines from the first character to the last. Include a small amount of surrounding area where practical, so no edge of a character remains visible. There is no universal legal or technical measurement for the size of a blackout. Use the recipient’s rules and make sure the entire printed zone is unreadable.
| Upload situation | What to do | What to check |
|---|---|---|
| Recipient confirms MRZ is not needed | Remove both complete lines | No character is partly visible |
| Recipient needs the MRZ to scan | Do not redact it without approval | Follow the stated upload process |
| Instructions do not say | Ask before editing | Keep the original private meanwhile |
| You are unsure which area is the MRZ | Check a passport guide or ask the recipient | Do not guess and cover required fields |
Do not use a blur, highlight, translucent fill, or pixelation as a substitute for removal. These effects may leave enough information to read or restore. An opaque cover can also fail if it is only an editable layer on top of the original text.
Redact the file in a safe sequence
The safest workflow has four stages: survey, redact, export, and verify. I use the same sequence whether I am preparing a PDF or an image. It helps prevent a common mistake: checking only what the file looks like on screen.
- Survey the upload. Confirm that the recipient does not require the MRZ. Open the correct passport page and check for other details the recipient does not need, such as unrelated pages or visible notes.
- Make a copy. Keep the original separate. Edit the copy, and make sure the working file is the one you intend to upload.
- Apply the redaction. Use a PDF editor’s actual redaction tool, or change the image pixels in an image editor. Cover both MRZ lines fully.
- Export a new file. Save a new copy in the format the recipient requests. Remove unnecessary metadata, comments, attachments, and prior revisions where your software offers those options.
- Verify the exported copy. Close it, reopen it, and run the checks below. Upload only after it passes.
A PDF is not safe just because a black rectangle looks solid. A movable rectangle or annotation may sit above the original text. In that case, someone may still be able to select, search, copy, or extract the MRZ beneath it. Use Apply Redactions or the equivalent command that removes the covered content, then save the result as a new file.
PDF is a standardized document format under ISO 32000, but the format itself does not make a visual overlay secure. The software and the way you save the file matter. If your tool has a preview or confirmation step, inspect the marked area before applying the redaction.
For a photo or scan, use an editor that changes the actual pixels. Paint an opaque fill over both lines, then export a flattened copy. Flattening merges visible layers into one image, so the blackout is no longer a separate movable object. It does not, by itself, prove that the original image, metadata, or embedded files have been removed.
Choose the right method for PDF or image uploads
PDF redaction and image editing solve the same problem in different ways. A PDF may contain selectable text beneath a scanned page or overlay. An image editor changes the visible pixels, but the exported file still needs a check for retained source data and metadata.
| File type | Preferred method | Main risk | Final check |
|---|---|---|---|
| Text-based PDF | Apply the editor’s redaction tool | Text remains under a rectangle | Search, select, and copy test |
| Scanned PDF | Apply redaction to the page image | Image may remain in another layer or revision | Inspect the export at high zoom |
| JPEG or PNG photo | Replace MRZ pixels with opaque fill | Original or editable layers may be retained | Reopen the flattened export |
| Word or slide file | Export a final, redacted PDF or image | Hidden objects or earlier versions may remain | Inspect the exported file, not just the source |
Do not send a working file with editable layers unless the recipient specifically asks for it. A screenshot of a blacked-out passport may look secure, but it can lose clarity or create a new file with its own metadata. Use the requested format and check that the remaining passport details are still clear enough for the intended use.
Avoid online redaction services unless you have checked how they handle uploaded passport data, including storage and deletion. If you cannot assess those terms, use a trusted offline tool instead. No tool can make a file safe if it keeps an unredacted copy in a cloud history or export folder you later share by mistake.
Verify the exported upload, not just the edit
Verification means checking that the MRZ cannot be seen or recovered from the file you will send. The key edge case is a PDF that looks blacked out but still holds the original text beneath the cover. Visual review alone cannot detect that.
Use these checks on the exported copy:
- Visual check: Reopen the file and zoom in. Confirm that both complete lines are covered and no characters show at the edges.
- Text check: In a PDF, try to select or copy text from the covered area. Search for a visible MRZ string if you know one. The covered text should not be available.
- OCR check: Run optical character recognition (OCR), which turns text in an image into searchable text. Check whether it can read any part of the covered lines.
- File check: Review document properties and attachments. Remove passport data in metadata, comments, embedded files, or prior revisions if your tool allows it.
- Upload check: Confirm the filename and preview show the redacted copy, not the original or working file.
A failed text or OCR check means the export needs more work. Reapply the redaction with a tool that removes the underlying content, export a fresh copy, and test again. If you cannot confirm that the MRZ is gone, do not upload that file.
Worked examples: common redaction decisions
These examples show how I would reason through typical cases. They are scenarios, not claims about a particular recipient or service. Always follow the actual upload rules for your case.
Scenario 1: A form asks for a passport image but says the MRZ is not needed. I would make a copy, apply true redaction to both lines, and preserve the required identity fields. Then I would reopen the exported file and test it for visible, selectable, and OCR-readable MRZ content.
Scenario 2: An upload portal scans the passport automatically. I would not remove the MRZ unless the portal or its support team confirms that a redacted copy is accepted. The code area may be part of the requested check. If the service needs an unedited page, use its stated secure process rather than guessing.
Scenario 3: A user placed a black box over the MRZ in a PDF. I would treat that file as unredacted until proven otherwise. If the text can still be selected or copied, the cover is only an overlay. I would use a real redaction tool, apply it, save a new copy, and repeat the checks.
Common mistakes to avoid
A blackout can fail even when it looks convincing. The most useful safeguard is to check how the final file behaves, not just how it appears in the editor.
- Covering only numbers while leaving letters or filler marks visible.
- Using blur, a translucent shape, or a movable annotation.
- Saving over the original without keeping a separate working copy.
- Checking the editor canvas but not reopening the exported file.
- Assuming flattening removes metadata or every retained copy of the source.
- Uploading to an online tool without reviewing its data handling.
- Sending a redacted file when the recipient requires a readable MRZ.
The safest next step is to pause if the recipient’s requirements are unclear. Ask what may be removed, and keep the unedited passport private until you have a clear answer.
Frequently asked questions
These quick answers cover common questions about removing MRZ data from passport uploads. The right choice still depends on the recipient’s requirements. If a service needs the code for scanning, do not remove it without approval.
What is the MRZ on a passport?
It is the machine-readable zone, usually printed as two lines near the bottom of the passport identity page. A standard TD3 passport has 44 character positions on each line.
Should I hide the MRZ before every upload?
No. First check whether the recipient needs it. Redaction may block an identity scan or lead to rejection if the service requires an unedited passport image.
Can I put a black rectangle over the MRZ in a PDF?
Not if it is only a shape or annotation. Use a PDF tool’s applied redaction function, which removes the covered content, then test the saved file.
Is a blacked-out image safe after flattening?
Flattening removes separate editable layers from the exported image, but it does not prove that the source image or metadata is gone. Reopen and inspect the export.
Should I cover just the passport number?
If the recipient agrees that the MRZ is not needed, cover both complete MRZ lines. Do not leave letters, filler marks, or partial characters exposed.
Can blur or pixelation hide the MRZ?
Do not rely on either method. They alter appearance but may leave information readable or recoverable. Use true redaction or replace the image pixels with an opaque fill.
How can I tell if PDF text remains underneath?
Try selecting or copying text from the covered area, search for text from the MRZ, and run OCR. If any covered content is recovered, make a new redacted export.
Do I need to remove metadata?
Remove unnecessary metadata, comments, attachments, and prior revisions when your software supports it. Then check the exported file’s properties and attachments before upload.
Is it safe to use a free online redaction site?
Only if you have reviewed and accepted how it handles and retains passport data. If you cannot confirm its practices, use a trusted offline tool.
What if the recipient does not explain whether the MRZ is needed?
Ask before editing or uploading. Keep the original private, and do not send an unverified file while you wait for guidance.
The practical rule is simple: confirm the recipient’s needs, remove both full lines with a method that changes the file content, and verify the exported copy. If any check suggests the MRZ remains, do not upload it.
(This article was written by one of our staff writers, Richard Montclair. Visit our Meet the Team page.)





