BASALT · JOURNAL

How to find and remove hidden text from a PDF

2026-09-21 · remove hidden text pdf

“Hidden text” describes several unrelated PDF mechanisms. The right removal depends on whether the text is useful OCR, deliberately invisible page content, an accessibility replacement, a hidden layer, or a value outside the page stream.

Common hidden-text carriers

Searchable scans use invisible OCR text over an image. Content streams can also paint text in white, at zero opacity, outside the crop box, behind another object, or inside a clipping path. Optional-content groups can switch text off. ActualText accessibility properties can provide replacement text that differs from the visible glyphs.

Annotations, form fields, bookmarks, metadata, and attachments store strings outside page painting entirely.

Inspect before deleting

Invisible OCR is beneficial for search and accessibility and should not be stripped wholesale unless the workflow requires it. The security question is whether it contains information approved for removal or diverges from the visible page.

Use a PDF-aware inspector to list text objects and their bounds, rendering mode, opacity, clipping, layer membership, and replacement text. Compare extracted text with page rendering. Search target values across every text carrier.

Remove the correct object and verify

For a redacted scan, remove OCR glyphs intersecting the image mark while preserving text elsewhere. Remove hidden layers content-and-all when they are not approved for release. Clear unwanted field, annotation, metadata, and attachment strings through sanitization.

Reopen the result with an independent parser, extract every supported text source, and confirm the target is absent. A screenshot or print preview cannot prove that.

Frequently asked questions

Is all invisible text dangerous?

No. OCR text often makes scans searchable and accessible. The risk is hidden content that discloses information or differs from the approved visible record.

What is ActualText in a PDF?

It is replacement text used for extraction or accessibility. It can reveal a value even when the visible glyphs appear different.

Can text outside the cropped page still exist?

Yes. Cropping often changes the viewing boundary without deleting off-page content.

Doing it in Basalt

Basalt's inspector reports OCR, hidden layers, annotations, forms, metadata, and other artifact classes. Redaction removes intersecting hidden text and sanitization clears non-page carriers; the verifier then extracts the output independently. Download Basalt.

Redaction that proves itself

Basalt destroys the content you mark, then re-opens the file it wrote and proves the content is gone before it saves anything. Your documents never leave your Mac.

DOWNLOAD BASALT 2.3.0 BUY $29 FREE FOR 24 HOURS · MACOS 13+