H
HidePDF
Redact PDFs in your browser. Nothing leaves your device.
100% local · fully local

Can OCR Recover Text From a Redacted PDF Image?

People worry that running OCR on a redacted PDF will magically read what was under the black box. If the redaction was flattened into the page image, OCR only sees the box — there are no underlying text pixels left to recognize. The failure mode that actually matters is a fake redaction: a rectangle sitting on top as a separate object, where the original text is still in the file.

PDF
Drop a PDF here, or click to choose
Your file never leaves your device.
Burning in redactions…
Preparing pages…

OCR is pattern recognition on what is visible. It is not a forensic undelete for PDF content. When a black box is burned into the page pixels, the glyphs underneath are gone from that image. An OCR engine asked to “read the page” will report a dark region or nothing useful — not the salary line that used to sit there.

Copy-paste tests for live text are covered in can you copy-paste text out of a redacted PDF. Hidden OCR layers under scans are does redacting an OCR’d PDF remove the hidden text layer. This page is specifically: does OCR defeat a flattened image redaction?

Flattened redaction overwrites the samples OCR would read

Proper burn-in merges the cover into the page content — typically by rasterizing the page (or the marked region) so the black (or white) fill replaces the former ink. The file no longer contains those character operators or those glyph pixels in the marked area. OCR run later operates on the new image: a rectangle of uniform color. There is no hidden sharpness underneath for the recognizer to discover.

That is why “will OCR undo my redaction?” is the wrong fear when flattening was done correctly. OCR cannot invent character shapes from a solid fill.

Unflattened overlays: no OCR required

The common disaster is drawing a black annotation, highlight, or stamp on top of live text or a scan without merging it into the page. The original content remains as a lower layer or as intact text objects. Anyone can hide or delete the annotation in a PDF editor and read the content directly. OCR is irrelevant — the text never left.

Teams that “redacted” with Preview shapes, Word black highlighting exported poorly, or comment rectangles learn this the hard way in discovery. Flattening is the control that matters more than which brand of redaction UI you used.

How HidePDF’s client-side flattening fits

HidePDF marks regions in the browser and exports with boxes burned into flattened page images. Processing stays in local memory on this page — HidePDF never receives the PDF. After download, search and select-test the marked areas. If text still highlights under a box, the export failed your test; fix coverage and try again.

For PDFs that already carry a hidden OCR text layer under a scan, burn-in must destroy that layer too — see does redacting an OCR’d PDF remove the hidden text layer. OCR-after-redaction on a good flatten still only sees the box; OCR-before issues are about leftover text objects, not magic recovery of burned pixels.

Scanned image-only PDFs

An image-only scan with a redaction painted into the bitmap is the same story: later OCR sees the painted region. If someone only put a vector rectangle above the image without rewriting the image, removing the rectangle restores the scan — again without needing OCR as an attack.

How to verify before you send

STEP 01

Select under the box

Try to highlight text where the redaction sits. Selectable text means the cover is not a true flatten for that region.

STEP 02

Search distinctive strings

Search for a unique word that should be gone. Hits mean content or an OCR layer still exists.

STEP 03

Open in a second viewer

Confirm the box cannot be moved or deleted to reveal underlying content.

STEP 04

Optional OCR sanity check

If you run OCR on the export for accessibility elsewhere, expect no recovery of marked secrets — only whatever remains visible outside the boxes.

Scenarios

Opposing counsel “OCR’d your production.” If boxes were flattened, they get box-shaped nothing in those regions. If boxes were overlays, they may not need OCR at all.

A colleague ran ABBYY on your “redacted” scan. ABBYY reads pixels; burned boxes stay boxes.

You black-highlighted in Word and printed to PDF. Often still extractable — treat as untrusted until select/search tests pass.

Practical takeaway

Fear OCR less; fear unflattened overlays more. Use a tool that burns redactions into the page, verify with select and search, and keep an unredacted original only in a place you control. Related: can you copy-paste text out of a redacted PDF.

Related guides

See also:

Frequently asked questions

Can someone OCR a redacted PDF to read what’s underneath?

No, if the redaction was properly flattened — OCR can only read visible pixels, and a flattened box has genuinely overwritten them.

What if the redaction wasn’t flattened?

Then the original text may be recoverable without OCR at all, just by removing the overlay layer — a more common and more serious mistake.

How do I know if my redaction was actually flattened?

Try selecting or copying text under the box — if nothing selectable exists there, it was flattened correctly.

Does this apply to scanned (image-only) PDFs too?

Yes — if the redaction box is part of the image itself, OCR run against that image only sees the box, same as any other flattened redaction.