How to Redact a PDF for Free: Permanently Remove Sensitive Text
Quick summary: To redact a PDF for free, open it in LibreOffice Draw, draw a filled black rectangle over the sensitive content, then export as a new PDF (File → Export as PDF). For true permanent redaction using the command line, use Ghostscript or a dedicated free tool like OCRmyPDF. Never use Preview or Acrobat Reader’s annotation tools — black box annotations look redacted but the original text remains in the file and can be selected and copied.
Redaction means permanently removing information from a document so it cannot be recovered. It is not the same as covering text with a black box — the wrong method leaves the original data in the file, visible to anyone who selects the text, opens the PDF in a text editor, or removes the annotation layer. This guide covers only methods that produce genuinely permanent redaction.
Before sharing sensitive documents, you can also review the final redacted version with our AI PDF reader to confirm no sensitive terms remain in the extractable text.
What redaction is NOT
These common mistakes look like redaction but are not:
| What people do | Why it fails |
|---|---|
| Add a black shape in Preview’s Markup | The shape is an annotation layer on top — the original text is still in the file and can be selected |
| Add a black highlight or ink stroke in Acrobat Reader | Same issue — annotation, not redaction |
| Edit the PDF’s text color to white | The text is still there, just invisible on screen |
| Print to PDF after adding black boxes | May bake in the boxes but may also re-render the original text underneath |
True redaction removes the text data (or image pixels) at the content layer, not just visually covers them.
Method 1: LibreOffice Draw (Mac and Windows, free)
LibreOffice Draw opens PDFs and lets you draw shapes that become part of the page content — not floating annotations.
- Download and install LibreOffice from libreoffice.org.
- Open LibreOffice Draw (not Writer).
- Go to File → Open and open your PDF.
- LibreOffice imports each page as an editable canvas.
- Use the Rectangle tool (in the Drawing toolbar at the bottom).
- Draw a filled black rectangle over each piece of text you want to redact.
- Right-click the rectangle → “Area” → set Fill Color to Black.
- Make sure there is no border (Line: None) so no white gap appears at the edges.
- When all sensitive content is covered, go to File → Export as PDF.
- In the PDF export dialog, uncheck “Export PDF form” and click Export.
Verify before sharing: Open the exported PDF in a viewer and try to select or copy the text under the black rectangles. If no text is selectable there, the redaction is effective. If text is still selectable, the rectangles ended up as annotations — repeat the process and export again.
Limitation: LibreOffice re-renders PDFs when opening them, which can change font rendering, spacing, and image quality. For legal or official documents, use Ghostscript (below) or a dedicated redaction tool.
Method 2: Ghostscript (command line, Mac, Windows, Linux)
Ghostscript processes PDFs at the content stream level, making it suitable for scripted or batch redaction. However, Ghostscript alone does not detect text — you need to know the exact page coordinates of what you want to remove.
Install Ghostscript:
- Mac:
brew install ghostscript - Windows: Download from ghostscript.com
To redact by flattening all annotations (removes annotation layers but not content text):
gs -sDEVICE=pdfwrite -dNOPAUSE -dBATCH \
-dFastWebView=false \
-sOutputFile=redacted.pdf input.pdf
For content-level redaction, combine with a PDF manipulation library (such as PyMuPDF / fitz in Python) to delete text objects before passing to Ghostscript — this is the basis of most open-source redaction pipelines.
Method 3: Online redaction tools (free)
Several browser-based tools offer visual PDF redaction with genuine content removal. Search for “redact PDF free” and look for tools that explicitly state they remove text data (not just overlay boxes):
- Upload your PDF.
- Use the redaction tool to mark sensitive areas.
- Apply and download the redacted PDF.
Privacy note: You are uploading sensitive data to a remote server. For documents containing medical, financial, or legal information, use an offline method.
Method 4: Preview on Mac (visual cover only — limited)
Preview’s markup tools do not produce true redaction. Use this only when you need a quick cover for informal sharing and the underlying data does not matter:
- Open the PDF in Preview.
- Click View → Show Markup Toolbar.
- Select the Rectangle tool. In the style controls, set:
- Fill color: Black
- Line: None
- Draw rectangles over the sensitive text.
- File → Export as PDF (not Save).
The text under the rectangles remains extractable. If the recipient opens the PDF in a viewer with annotation hiding disabled, or strips annotations programmatically, the text is visible.
How to verify your redaction worked
After redacting and saving:
- Open the redacted PDF in any viewer.
- Press Ctrl+A (or Cmd+A) to select all text.
- Copy and paste into a plain text editor.
- Search the pasted text for any of the terms you redacted.
If the terms appear in the pasted text, your redaction did not work at the content level. Repeat using LibreOffice or Ghostscript.
Alternatively, run the PDF through our PDF reading tool and search the extracted text for the sensitive terms.
Flatten the PDF after redacting
After redacting, flatten the PDF before sharing. Flattening merges all layers into a single content stream, removing any lingering annotation metadata:
- See how to flatten a PDF for free for step-by-step instructions on Mac, Windows, and online.
Related guides
- How to flatten a PDF for free — lock layers after redacting
- How to password protect a PDF for free — add access control in addition to redaction
- How to edit a PDF for free — make other content changes before or after redacting
- How to search a PDF for free — find sensitive terms before redacting
Frequently Asked Questions (FAQ)
Is PDF redaction with LibreOffice permanent?
When you export as PDF from LibreOffice after drawing filled rectangles on the page canvas (not as annotations), the black shapes are baked into the content stream and the original text underneath is removed from the exported file. Verify using the select-all test described above.
What is the difference between redaction and password protection?
Redaction removes the information permanently — no one can recover it regardless of what software they use. Password protection prevents unauthorized access but the information is still in the file; remove the password and the content is visible. For truly sensitive data, redact first, then optionally add a password. See how to password protect a PDF.
Can I redact a scanned PDF?
A scanned PDF is an image — there is no text layer to remove. Covering the area with a black rectangle in LibreOffice is sufficient, because there is no extractable text to recover (the entire page is already pixel data). Export as PDF after adding the black shapes.
How do I redact metadata and document properties?
PDF metadata (author, title, creation date, software used) is separate from page content. To remove it:
- In LibreOffice: File → Properties → clear all fields before exporting.
- With Ghostscript: add
-dFASTWEBVIEW=false -c "[ /Author () /Creator () /Producer () /Keywords () /ModDate () /CreationDate () /Title () /Subject () /DOCINFO pdfmark"before the input filename.
Why does my redacted PDF still have the text in search results?
Search engines and cached versions may have indexed the text before you redacted it. The redacted file itself is clean — the search result is from an older, unredacted version. Request re-indexing via Google Search Console if the content appears in search results.
Why can’t I redact a PDF in Adobe?
Redaction is only available in Adobe Acrobat Pro, not the free Reader. In Acrobat Pro, go to Tools → Redact → Mark for Redaction. If that option is missing, you are using Acrobat Reader — use the LibreOffice method above instead, which is free and produces permanently redacted output.
Can I redact a PDF so the text cannot be uncovered?
Yes, if done correctly. Simply drawing a black box over text in Preview or a drawing tool does NOT redact it — the original text remains in the file and can be selected or copied. True redaction requires either Adobe Acrobat Pro’s dedicated redaction tool or the LibreOffice export method: drawing filled rectangles on the page canvas (not as annotations) and then exporting as a new PDF. Always verify the output by pressing Ctrl + A to select all — no text should appear under the black areas.