PostgreSQL Anonymizer
postgresql-anonymizer.readthedocs.io
What it is
PostgreSQL Anonymizer is an extension for masking or replacing personally identifiable and commercially sensitive data in PostgreSQL databases. Masking rules can be written in SQL with PostgreSQL DDL and kept in the database schema. Its documented approaches include anonymous dumps, static and dynamic masking, replica masking, masking views, and data wrappers. Functions can randomize, fake, partially scramble, shuffle, add noise, generalize, or apply custom transformations. A masked role can export anonymized data through pg_dump; masking rules should then be removed from the dump. Identifier detection searches common names in English and French, but may flag non-identifiers or miss identifiers. Installation instructions cover Linux and self-hosted PostgreSQL. The extension can be built from source on macOS, without community support there; Windows use is described through PostgreSQL on WSL2, as there is no native build. Installation requires superuser privileges, so a cloud database provider must offer the extension in its catalog. The plan is free. Commercial support is available separately.
Spec sheet
- Purpose
- A PostgreSQL extension for masking or replacing personally identifiable or commercially sensitive data.Read 29 Sep 2026 · postgresql-anonymizer.readthedocs.io
- Integrations
- Installation documentation includes Ansible, Docker, and Django, and lists compatible PostgreSQL forks and cloud database providers.Read 29 Sep 2026 · postgresql-anonymizer.readthedocs.io
- Support
- The project invites users to join its Matrix or Discord communities or open a public GitLab issue; enterprise support is available by contacting Dalibo.Read 29 Sep 2026 · postgresql-anonymizer.readthedocs.io
- License
- The project license permits use, copying, modification, and distribution without a fee, while disclaiming any obligation to provide maintenance, support, or updates.Read 29 Sep 2026 · gitlab.com
- Anonymous exports
- A masked database role can be used with pg_dump to export anonymized data, and the documentation says masking rules should be removed from the resulting dump.Read 29 Sep 2026 · postgresql-anonymizer.readthedocs.io
- Cloud limitation
- Installation requires superuser privileges, so a DBaaS provider must add the extension to its catalog for customers to use it.Read 29 Sep 2026 · postgresql-anonymizer.readthedocs.io
- Declarative rules
- Masking rules can be declared in SQL using PostgreSQL DDL and stored in the database schema.Read 29 Sep 2026 · postgresql-anonymizer.readthedocs.io
- Dynamic masking limitation
- Masked roles are not allowed to use EXPLAIN, and masking rules can break data integrity, for example when masking a UNIQUE column to NULL.Read 29 Sep 2026 · postgresql-anonymizer.readthedocs.io
- Identifier detection
- Its detection function searches for common identifier names using English and French dictionaries, and the documentation warns that detection can produce false positives and false negatives.Read 29 Sep 2026 · postgresql-anonymizer.readthedocs.io
- Masking functions
- Available function types include randomization, faking, partial scrambling, shuffling, noise, generalization, and custom functions.Read 29 Sep 2026 · postgresql-anonymizer.readthedocs.io
- Masking methods
- The documentation describes anonymous dumps, static masking, dynamic masking, replica masking, masking views, and masking data wrappers.Read 29 Sep 2026 · postgresql-anonymizer.readthedocs.io
- Supported deployment
- The extension has installation instructions for Linux distributions and self-hosted PostgreSQL; it can also be built from source on macOS, but community support for macOS is not provided.Read 29 Sep 2026 · postgresql-anonymizer.readthedocs.io
- Windows support
- There is no native Windows build; the documentation describes running PostgreSQL Anonymizer inside PostgreSQL on WSL2.Read 29 Sep 2026 · postgresql-anonymizer.readthedocs.io
Plans and prices
Strong points and limits
Strong points
- Rules are declared in SQL and stored in the schema.
- Includes static, dynamic, replica, and view masking.
- Offers several transformation functions and custom functions.
- Anonymous exports can be made with pg_dump.
- Free plan costs nothing.
Limits
- Installation requires superuser privileges.
- There is no native Windows build.
- macOS community support is not provided.
- Identifier detection can produce false positives and negatives.
Who it suits
It suits PostgreSQL users who need to mask data for exports, testing, or other database workflows. Cloud database customers need a provider that offers the extension, and Windows users need WSL2.
Verdict
PostgreSQL Anonymizer provides multiple ways to mask database data and create anonymized exports. Check provider availability and deployment requirements first; masking rules can also affect data integrity, and dynamic masked roles cannot use EXPLAIN.
Where Specifiction places it
- Data Masking Software#15 of 267.4