SQLBoiler is a code generator that produces a Go ORM tailored to your database schema.
The tool addresses the verbosity and boilerplate inherent in working with Go's database/sql package by taking a database-first approach. Rather than defining your schema in code, you create your database structure first using migration tools, then SQLBoiler generates type-safe ORM code from that schema. The generated models are normal Go structs with methods for querying and managing relationships, avoiding reflection-based magic and providing performance comparable to hand-written database code.
SQLBoiler suits projects where you control the database schema and want to eliminate SQL boilerplate while maintaining Go's simplicity and performance characteristics. It works with PostgreSQL, MySQL, SQLite, and MSSQL. The README identifies two actively maintained alternatives: Bob, which was inspired by SQLBoiler and created by one of its former maintainers, and sqlc, which generates type-safe code from SQL queries but is not an ORM and takes a different architectural approach.
The project is in maintenance mode, accepting bug fixes and compatibility updates from the community but not pursuing new features. Maintainers generally do not resolve reported issues, instead encouraging community members to help each other. Only version 4 remains maintained, with earlier versions no longer supported.