sqldef

Input—per 1M tokens
Output—per 1M tokens
Context—tokens
WeightsClosed

About

sqldef is ranked #17 of 32 in database migration tools on Inferse. It runs on Linux, macOS, Self-hosted, Web, Windows.

Compared on database migration tools

Rollback support
Yessqldef.github.io
Schema diff
Yessqldef.github.io
CI/CD automation
Yessqldef.github.io
Drift detection
Yessqldef.github.io
Self-hosted option
Yessqldef.github.io
Migration format
sqlsqldef.github.io

Facts

Purpose
sqldef is a CLI tool for diffing SQL schemas and managing RDBMS migrations with regular SQL DDLs.sqldef.github.io · 4 Oct 2026
Supported databases
The site lists MySQL, MariaDB, TiDB, PostgreSQL, SQL Server, and SQLite3 as supported databases.sqldef.github.io · 4 Oct 2026
Schema workflow
Users define a desired schema in SQL, and sqldef generates and applies migrations to bring the database to that state.github.com · 4 Oct 2026
Idempotency
The README says sqldef operations are idempotent and safe to run multiple times.github.com · 4 Oct 2026
Preview and offline modes
sqldef can preview migrations without executing them and compare SQL files without connecting to a database.github.com · 4 Oct 2026
Rename support
The README says the @renamed annotation supports renaming tables, columns, indexes, and ENUM values.github.com · 4 Oct 2026
Distribution
The project provides pre-built single-binary executables and Docker images.github.com · 4 Oct 2026
Platforms
The releases page lists downloadable binaries for Windows, macOS (Darwin), and Linux.github.com · 4 Oct 2026
Integrations
The README links to a GitHub Action that previews database schema changes.github.com · 4 Oct 2026
Security and licensing
The README states that sqldef source files are distributed under the MIT License, except the parser, which is under Apache License 2.0.github.com · 4 Oct 2026
Support
The project invites feature requests through pull requests or GitHub Discussions.github.com · 4 Oct 2026
Linux package limitation
The README says Debian packages are not currently available and directs Linux users to pre-built binaries or Docker images.github.com · 4 Oct 2026
Audience
The README describes a workflow for database schema changes that uses a single SQL file containing the complete schema.github.com · 4 Oct 2026
Online demo
The official site says its online demo uses a WebAssembly build of sqldef to diff schemas and generate DDLs.sqldef.github.io · 4 Oct 2026

Best sqldef alternatives

See all 12

Where it ranks on Inferse

Sources