Jailer
Database subsetter and data browser with AI-assisted SQL queries
Replaces Redgate Test Data Manager
Who it's for
Teams working against production-sized databases use Jailer to pull a small, consistent slice they can run locally or in CI. The extraction model defines which root records to include and the subsetter follows foreign keys to pull everything needed, so tests pass against realistic data without direct production access.
The database is small enough to copy in full, or the team already has synthetic data generation covering their test cases.
QA teams use Jailer to refresh test databases from production on a schedule, keeping their environment representative without growing to full production size. The extraction model is version-controlled alongside the schema, so it updates when the schema changes.
The testing requirement is for anonymized synthetic data rather than a production-derived slice; Jailer subsets rows but does not generate synthetic records or mask values.
Jailer can remove and archive obsolete rows from a production database while maintaining referential integrity, improving query performance without violating foreign key constraints. The topological sorting of exported SQL ensures inserts and deletes apply in dependency order.
The archival process requires complex data masking, transformation pipelines, or compliance workflows beyond referential subsetting and deletion.
The Data Browser lets engineers navigate a schema they did not design, following foreign-key chains in both directions to understand how tables relate. The SQL Console with AI query generation helps write correct queries against complex schemas faster than reading documentation alone.
The schema is well-documented and the team already has preferred query tooling; Jailer's value here is schema exploration rather than query execution speed.
The problem
Large production databases create a testing obstacle that does not go away. Full copies are too expensive to maintain for every developer, random samples break referential integrity, and manually curating a consistent subset is slow enough that teams simply skip it. The result is tests running against stale data, developers sharing a single production copy, and QA environments that behave differently from what is actually in production. The specific pain is referential integrity. Taking 10% of an orders table without also taking the matching customers, products, and inventory rows produces a database where every foreign key is either missing or dangling. Writing extraction scripts by hand that get this right for a schema of hundreds of tables takes days and breaks every time the schema changes.
How it works
Extracts consistent, dependency-complete row sets from production databases by following foreign-key chains. The output imports cleanly into development and test environments without broken references or orphaned records. Exports as topologically sorted SQL, JSON, YAML, XML, or DbUnit datasets.
Navigate through any database in both directions by following foreign-key-based or user-defined relationships between tables. Useful for exploring unfamiliar schemas or tracing how records connect across dozens of tables without writing manual join queries.
The AI Subsetting Assistant accepts plain-English descriptions of what data to extract and generates the subject table, WHERE condition, and association restrictions. The AI Query Assistant generates SQL from natural language using Anthropic or OpenAI-compatible APIs, with smart table selection for large schemas.
A full SQL console with code completion, syntax highlighting, pivot tables, and interactive charts. Results turn into charts directly in the result view with 11 chart types and export as PNG, JPEG, or SVG. A SQL Advisor analyzes, explains, and refactors existing queries with an inline diff view.
Reverse-engineers the data model of databases that lack foreign key constraints. Candidates are derived from column names and optionally from the data itself, then verified against the database and rated with a confidence score. Added in August 2026.
Generates DDL scripts for creating database objects through Liquibase integration, making it possible to build subset databases from scratch without external tooling. Supports creating a fresh target schema automatically from the extraction model.
Features
- Referentially Intact Subsetting
- Data Browser with Bidirectional Relationship Navigation
- AI Subsetting Assistant and SQL Query Generator
- SQL Console with Charts and Code Completion
- Schema Reverse-Engineering via Discover Associations
- DDL Script Generation via Liquibase
How to install
Setup requires cloning the repository and building with Apache Ant; binaries are also available as .msi and .deb installers on the releases page.
git clone https://github.com/Wisser/Jailer.git
cd Jailer
antRecommended for this setup
Strengths
- Apache 2.0 License with No Per-Seat Costs: Apache 2.0 permits commercial use, modification, and distribution without royalties or restrictions. Unlike Redgate Test Data Manager, there is no per-seat pricing or subscription. Download and run it on any number of machines at no cost.
- Works with Any JDBC-Compatible Database: Because it relies on JDBC, Jailer works with any database that provides a JDBC driver. Dedicated additional support is available for PostgreSQL, Oracle, MySQL, MariaDB, SQL Server, Db2, SQLite, Sybase, Amazon Redshift, Firebird, H2, Exasol, SAP HANA, Vertica, Snowflake, ClickHouse, and others.
- Actively Maintained Since 2011: The project started in 2011 and last pushed on 2026-10-16, with 3,212 GitHub stars and 144 forks. The 2026 release cadence added AI subsetting, natural-language SQL generation, spatial data previews, Mermaid ER diagram export, and BLOB/CLOB content previews.
- No Server Infrastructure Required: Runs as a desktop GUI on Windows, Linux, and macOS (with Java) or from the command line. Subsetting models are portable files, so extraction pipelines can run in CI/CD build systems without provisioning a persistent server.
Trade-offs
- Java Runtime Required for CLI and Zip Distribution: Jailer is written in Java. The Windows .msi and Linux .deb installers bundle their own JRE, but teams running the zip distribution or using the CLI in CI/CD pipelines need to provision a Java runtime in their build environment. This adds a dependency that Node.js or Go-based tools avoid.
- GUI-First Workflow for Model Setup: The primary interaction model is a desktop GUI. Teams building fully automated headless pipelines use Jailer's CLI interface, but it requires defining extraction models through the GUI first. There is no way to declare a subsetting model purely in code or config without opening the desktop application at least once.
- Initial Model Setup Time for Complex Schemas: For databases with hundreds of tables and complex relationship structures, building the initial extraction model takes time. The Discover Associations feature helps with schemas that lack documented foreign keys, but teams may need several hours to configure a complete subsetting model for a large production schema.
Tech stack
FAQ
Yes. Jailer is Apache 2.0 licensed, which permits commercial use, modification, and distribution without royalties or restrictions. Download and run it on your own infrastructure at no cost, including for commercial development and testing workflows.
Jailer works with any database that has a JDBC driver. It provides dedicated additional support for PostgreSQL, Oracle, MySQL, MariaDB, Microsoft SQL Server, IBM Db2, SQLite, Sybase, Amazon Redshift, Firebird, H2, Exasol, SAP HANA, Vertica, Snowflake, ClickHouse, and others. The JDBC fallback means obscure or internal databases are also covered, though without database-specific optimizations.
Download the .msi installer for Windows or the .deb package for Linux from the latest GitHub release. On any platform with Java, extract the zip distribution and run jailerGUI.sh on Linux and macOS, or Jailer.exe on Windows. A demo database ships with the tool so you can explore it without connecting to your own database first.
Jailer is a free, open source desktop and CLI tool focused on referential subsetting and relational data browsing. Redgate Test Data Manager is a commercial platform with additional features such as policy-managed data masking, team governance workflows, and vendor support contracts, at commercial licensing costs. For teams whose primary need is consistent, foreign-key-correct test datasets, Jailer covers that use case without the subscription. Redgate is the stronger choice when enterprise governance or structured masking policies are required.
Yes. The subsetter can be invoked from the command line for use in build pipelines and CI environments. Extract the zip distribution, define your extraction model using the desktop GUI, then invoke the CLI to run extractions headlessly on any schedule. The Jailer engine is also published as a Maven artifact at io.github.wisser/jailer-engine for programmatic integration in Java build systems.