Home › Blog › A black box on a PDF

A black box on a PDF: why the hidden text is still readable

A black box drawn on a PDF hides the text on screen without deleting it: the text is still underneath, and a simple copy and paste brings it back. To hide text reliably, you have to delete it from the file.

Published · Updated · 7 min read

Why a black box does not hide the text

A PDF file stacks several layers: a text layer (the characters, their font, their exact position on the page) and, possibly, graphic objects added on top (shapes, images, annotations). When you draw a black box with the “shape” or “drawing” tool of a PDF reader, you add a graphic object to that second layer. The text in the first layer does not move: it stays exactly where it was, with the same characters, in the same position.

The result: on screen, you no longer see the text. But for the computer, it is still there. Select all the content of the page (Ctrl+A or Cmd+A) and copy it into a text editor, and you get it back in full, black box or not. The search function of the PDF reader finds it just as easily. That is why people speak of a failed redaction: redacting originally means actually removing a passage, not covering it up visually.

The same problem arises with text highlighted in black, set in white on a white background, or covered by an image pasted on top: in every case, the original content remains in the file. Same trap with a scanned PDF: the image may hide a text layer recognized by OCR (see scans and the OCR layer).

The Manafort case: a redaction gone wrong

The case most often cited to illustrate this problem dates back to January 2019. A court filing in the Manafort case, in the United States, contained passages that were supposed to be hidden by black boxes. Journalists simply selected the text of the document and pasted it into an editor: the hidden passages appeared in plain text. The mistake did not come from a lack of sophisticated tools, but from the choice to cover the text visually instead of deleting it from the file.

The episode was widely shared because it showed, very concretely, that the problem affects everyone: government agencies, law firms, journalists, companies. If you are looking for a reliable end-to-end method, our guide on how to redact a PDF step by step details the procedure that avoids this kind of mistake.

How to check that a PDF is really redacted

Before sending or publishing a document, a few simple checks are enough to spot a failed redaction:

  1. Select all the text (Ctrl+A or Cmd+A in the PDF reader), copy, then paste into a plain text editor (Notepad, TextEdit, Notes). If a hidden passage shows up in the paste, the redaction failed.
  2. Search for a known word behind the box with the reader's search function (Ctrl+F or Cmd+F). If it is found, the text is still there.
  3. Compare the file size before and after redaction, as a clue only: actually deleting text and images often changes the size, while a box added on top barely does, but recompression or a change of software can also make it vary. It is a weak clue: rely on the two tests above first.
  4. Check the metadata and earlier versions kept inside the file, which may contain exactly the information you are trying to remove. Our article on how to remove a PDF's metadata explains what it reveals and how to clean it.

Common mistakes that leave text readable

Most failed redactions come from the same reflexes, all born of a confusion between “hiding visually” and “deleting”:

A file “converted to PDF” from a word processor is no guarantee either: if the source document still contained the text elsewhere, in a comment or in the change history, it can reappear in the export.

How to hide text reliably

To hide text in a PDF with no copy-and-paste risk, you must either actually delete the characters concerned, or turn the page into an image after covering them, so that no text layer exists at that spot anymore.

A real redaction tool does this job: the one in Adobe Acrobat Pro (“Redact”, on subscription), the one in Preview on a Mac (Tools → Redact) or the one in LibreOffice Draw (Tools → Redact, which turns the pages into images). Their drawing tools, on the other hand, only cover the text, and neither exporting nor printing to PDF deletes it. The step-by-step method is in redacting a PDF: the reliable method, step by step and, on a Mac, in redacting a PDF on a Mac. In every case, reopen the final file and run the tests above again.

Online tools (Smallpdf, iLovePDF, UPDF…) sometimes offer redaction or text-removal features. Before uploading a confidential document, check their privacy policy: the file is sent to their servers to be processed, which can be a problem for documents covered by professional secrecy or for sensitive personal data.

AnonymFiles is another option, designed precisely against this trap: redacted text is actually deleted from the output PDF, which keeps its layout, and the black block carrying the label hides nothing; metadata, annotations, forms and links are removed along the way. The app detects the information to hide (people, organizations, addresses, emails, phone numbers, IBANs), replaces it with stable labels such as [PERSONNE_1], also allows manual redaction, and shows the original and the copy side by side so you can approve each document before export. It processes an entire folder, with no account, no online license check, no telemetry and no cloud chat, and works offline once installed; it is coming soon for Apple silicon Macs and Windows. Scanned PDFs and images are read by local OCR, and the pixels of the detected areas are erased in the image. Whatever tool you choose, keep the habit of reviewing the final result: no automatic tool is 100% reliable, and for a document meant to circulate, the guide anonymize a PDF for free without uploading it covers the whole process.

Frequently asked questions

Is a black box in a PDF enough to hide text?

No. A black box drawn with the shape or highlighter tool of a PDF reader adds a graphic object on top of the page, but leaves the text underneath untouched. That text can still be selected, copied and searched until it is actually deleted from the file.

How can I tell whether my PDF is really redacted?

Select all the text in the document (Ctrl+A or Cmd+A), copy it, then paste it into a plain text editor. If the passages that should be hidden show up in the paste, the redaction failed. You can also use search (Ctrl+F or Cmd+F) to look for a word you know sits behind the box.

What should I do if I have already shared a badly redacted PDF?

Remove the file from wherever it can still be reached (email, shared link, public repository), warn the recipients about the problem, then send a corrected version in which the text has really been deleted, not just covered. Also check the metadata and any earlier versions kept inside the file.

Is automatic redaction software enough without a human review?

No. No automatic tool is 100% reliable. A human review of the final document is still needed to confirm that the right passages were hidden and that no sensitive text remains visible or recoverable.