Forum Discussion

Michelle_Scott77's avatar
Michelle_Scott77
Brass Contributor
Aug 28, 2026

How to properly redact a PDF?

I need to share a PDF that contains names, email addresses, and other confidential details that must be removed first. Simply placing black boxes over the text does not seem secure, since the original content may still be searchable, selectable, or recoverable, so I need a way to permanently redact a PDF.

Because the document contains sensitive information, I would prefer not to upload it to an online tool. I’m looking for either a built-in option or professional third-party desktop software that can permanently redact both text and images while processing the file locally. It would also be useful to remove hidden information from a PDF before sharing, including comments, document metadata, and any other embedded details.

What is the safest way to handle this, and how can I verify that a PDF is properly redacted before I send it?

4 Replies

  • LauraBennett's avatar
    LauraBennett
    Brass Contributor

    You are right: drawing a black rectangle is not redaction. For a local, code-based solution, PyMuPDF supports actual PDF redaction without uploading the document.

    The basic process is:

    1. Work on a copy. Locate sensitive text with page.search_for() and mark the matching areas using page.add_redact_annot(). Mark image areas by coordinates too. Scanned text needs local OCR or manual review because ordinary text search will miss it.
    2. Call page.apply_redactions() on each affected page. Adding the annotations alone does not remove content. Configure it to remove text, blank overlapping image pixels and remove overlapping vector graphics as appropriate.
    3. Remove remaining comments, unwanted attachments and metadata. PyMuPDF provides methods such as delete_annot(), embfile_del(), set_metadata({}) and del_xml_metadata(). Those operations are not a universal sanitizer: forms, layers and other PDF structures need separate attention.
    4. Save to a new file, using a full save with garbage collection, such as doc.save("redacted.pdf", garbage=4, deflate=True). Do not use an incremental save, which can retain earlier document data.

    For a document with complex hidden content, a simpler security-focused option is to render the redacted pages to images and build a fresh PDF containing only those images. This avoids carrying over the original text objects, comments, forms, attachments and metadata. Rebuild from the rendered pages; merely flattening annotations or printing to PDF is not equivalent. The tradeoff is losing selectable text, accessibility information and interactive features.

    Before sharing, reopen the new file and:

    • Search for the removed names and addresses, and try selecting or copying around each redaction.
    • Extract its text with a separate tool such as Poppler’s pdftotext.
    • Inspect every page visually, including images and repeated occurrences.
    • Check document properties, comments and attachments.

    A failed text search alone is not proof of successful redaction—sensitive details may still be visible in images. For highly sensitive material, have someone else review the final output as well.

  • AndrewAtAcuity's avatar
    AndrewAtAcuity
    Copper Contributor

    Full disclaimer I run a SaaS that provides automated redaction. However, I saw your post and I'm sure we can help!

     

    Acuity AutoRedact does this. You can upload your PDF and it will identify the entities you will likely want to redact. Then you click to allow those that are suitable. It's designed to make this job very quick.

     

    You can not recover data as we turn each page into an image at the end, with the redactions in place, and then save it again as a PDF. This ensures redacted data is gone.

     

    If you head to http://www.acuityautoredact.com and register you can process 200 pages for free.

     

    Any questions, please give me a shout!

     

    Best wishes,

    Andrew

  • Eric_Brooks's avatar
    Eric_Brooks
    Brass Contributor

    The best way to redact a PDF securely is to use a dedicated redaction tool that permanently removes selected text, images, and associated data. If you need to black out text in a PDF, do not rely on a black rectangle, highlighter, or annotation because the underlying information may remain searchable, selectable, or recoverable.

    Always keep an untouched original. Applied redactions are intentionally permanent and usually cannot be undone.

    • Built-in method

    Redact a PDF with Preview on Mac

    Current versions of Preview provide a built-in way to redact a PDF on Mac without installing additional software.

    1. Duplicate the PDF and open the copy in Preview.
    2. Select Tools > Redact or choose Redact from the Markup toolbar.
    3. Drag over the text or area that must be removed.
    4. Reopen the file and confirm that the information cannot be selected, copied, or searched.

    You can undo a marked redaction with Command + Z only while the document remains open; closing Preview does not reliably discard the changes because the redacted content may still be saved. Preview is suitable for basic redaction, but a dedicated third-party PDF editor provides more control over repeated information and hidden document data.

    Windows 10/11 do not include a built-in tool for secure PDF redaction. For anyone searching for how to redact a PDF without a redaction tool, Microsoft Edge is not a secure solution because drawing or highlighting only covers the information visually.

    • Desktop applications

    Because redaction usually involves private or confidential information, avoid online tools that require the PDF to be uploaded to a server. A desktop PDF editor that processes the file locally is generally more appropriate.

    Permanently Redact a PDF for free with PDFgear

    PDFgear is a free PDF editor for Windows and Mac that does not require an account or sign-in. If you are looking for how to redact a PDF without Adobe Pro, PDFgear includes a dedicated Redact tool that permanently removes selected text, images, or page areas.

    1. Open a copy of the PDF in PDFgear.
    2. Select Protect>Redact from the toolbar.
    3. Mark the text, image, or page area containing sensitive information.
    4. Apply and confirm the redactions.
    5. Save the PDF under a new name and verify the removed content.

    PDFgear lets you redact a PDF offline because all desktop features run locally, so the file does not need to be uploaded to a server. Keep the original document because applied redactions cannot normally be undone.

    Redact a PDF with Adobe Acrobat Pro

    For users searching for how to redact a PDF in Adobe, Acrobat Pro is the paid desktop option for removing visible content and hidden information on Windows or Mac.

    1. Open a copy of the PDF in Adobe Acrobat Pro.
    2. Select All tools > Redact a PDF.
    3. Choose Redact text and images, then mark the sensitive content or search for repeated words and phrases.
    4. Select Apply and remove hidden information when prompted.
    5. Save the redacted PDF under a new name and verify it.

    The free Adobe Acrobat Reader does not include the full Redact a PDF tool. Acrobat Pro can also search for a word or phrase and mark every matching instance for redaction, which is useful when the same sensitive information appears on multiple pages.

    To confirm that the information has been permanently removed, save the redacted PDF, close it, and reopen the final copy. Search for the removed names, numbers, or email addresses, then try selecting and copying text around each redacted area into a plain-text editor. The removed content should not appear in search results, selections, or copied text.

  • Hello, 

    Using black rectangles is not considered a secure way to redact a PDF because the underlying content may still be present and recoverable.

    The safest approach is to use a dedicated PDF redaction feature that permanently removes the selected content rather than simply hiding it. (as Adobe Acrobat) 

    In addition to redacting the visible content, I would also recommend removing hidden information such as comments, document properties, metadata, attachments, form fields, and other embedded content before sharing the file.

    Before sending the document, verify that the redacted content is no longer searchable, selectable, or copyable, and review the document properties to confirm that no sensitive metadata remains.

    For highly sensitive documents, some organizations also choose to create a new PDF from the redacted output as an additional safeguard.

    If this helped, a Like is always appreciated. If it addressed your scenario, please consider marking it as the accepted solution to help other community members find it more easily