Document Redaction Library

Hide or remove private information from various file types.

Edit text or images to eliminate sensitive content.

Manage file metadata using our advanced features.

GroupDocs.Redaction at a Glance

A solution to manage content in PDFs, Office documents, images, and other business files.

  • Remove or Edit Text

    Find and redact sensitive text in your documents with ease.

  • Redact Images

    Easily hide image areas in your files without extra effort.

  • Manage Metadata

    Remove or replace metadata such as the author in Word documents or EXIF data in images.

  • Advanced Features

    Search for data to redact using regular expressions or AI integration.

GroupDocs.Redaction Code Samples

Typical use cases of GroupDocs.Redaction redaction operations.

How to Redact Text in PDF Documents

GroupDocs.Redaction is the best solution for redacting text in your documents in just a few steps.
// Pass the file path to be redacted to a Redactor instance
using (Redactor redactor  = new Redactor("source.pdf"))
{
    // Provide redaction options
    var redaction = new ExactPhraseRedaction("Sensitive data", new ReplacementOptions("[hidden]"));

    // Redact and save the result
    redactor.Apply(redaction);

    var outputFile = redactor.Save();
}   
// Pass the file path to be redacted to a Redactor instance
final Redactor redactor  = new Redactor("source.pdf");

try 
{
    // Provide redaction options
    ExactPhraseRedaction redaction = new ExactPhraseRedaction("Sensitive data", new ReplacementOptions("[hidden]"));

    // Redact and save the result
    redactor.apply(redaction);
    redactor.save();
}
finally { redactor.close(); } 
import groupdocs.redaction as gr
import groupdocs.redaction.options as gro
import groupdocs.redaction.redactions as grr

def run():

    # Pass the file path to be redacted to a Redactor instance
    with gr.Redactor("source.pdf") as redactor:

        # Provide redaction options
        repl_opt = grr.ReplacementOptions("[hidden]")
        ex_red = grr.ExactPhraseRedaction("Sensitive data", repl_opt)

        # Redact and save the result
        result = redactor.apply(ex_red)

        so = gro.SaveOptions()
        so.add_suffix = True
        so.rasterize_to_pdf = False
        result_path = redactor.save(so)

30+ File Formats Supported

GroupDocs.Redaction supports redaction operations across all widely used business file formats.

GroupDocs.Redaction Achievements

Discover Key Metrics That Highlight Our Library’s Success

  • 30+

    Supported Formats

    GroupDocs.Redaction supports operations with over 30 widely used file formats.

  • 440k

    NuGet Downloads

    GroupDocs.Redaction for .NET has been downloaded more than 440,000 times from NuGet.

  • 12k

    Maven Downloads

    GroupDocs.Redaction has over 12,000 downloads on Maven, offering powerful Java redaction features.

  • 140+

    Happy Customers

    Both global enterprises and individual developers rely on GroupDocs products to build innovative solutions.

Our Happy Customers

GroupDocs libraries are trusted by globally recognized and respected brands.

Platform Independence

GroupDocs.Redaction library supports the following operating systems and frameworks:

.NET

.NET 6.0+
.NET Core 3.1
.NET Framework 4.6.2+
Windows
Linux
Mac OS
Microsoft Azure
Microsoft Visual Studio
JetBrains Rider
Microsoft Visual Code
30+ file formats

Java

Java 8 or higher
Kotlin
Windows
Linux
Mac OS
IntelliJ IDEA
Eclipse
NetBeans
30+ file formats

Python

Python 3.9+ and .NET 6+
Windows
Linux
Mac OS
IDLE
PyCharm
Visual Studio Code
30+ file formats

Ready to Get Started?

Try GroupDocs.Redaction features for free on your platform.

Useful resources

Explore documentation, code samples, and community support to enhance your experience.

Frequently Asked Questions

Answers to the most commonly asked questions.

  • Does the GroupDocs.Redaction library require any third-party software to manipulate documents?
    GroupDocs.Redaction does not require any external software like Adobe Acrobat, Microsoft Office, or others.
  • Can I try the GroupDocs.Redaction library before purchasing?
    Yes, you can try GroupDocs.Redaction without purchasing a license. It works in trial mode, which adds trial badges and limits output to the first 3 pages. To test without restrictions, request a 30-day temporary license. For more details, see.
  • What license options are available?
    We offer several license types based on your development and distribution needs. These include developer-based, site-based, and Metered licenses depending on usage. Learn more here.
 English