# go-reform/reform

A better ORM for Go, based on non-empty interfaces and code generation.

Repository: https://github.com/go-reform/reform
Canonical: https://ross.abutalabs.com/products/go-reform-reform
Homepage: https://gopkg.in/reform.v1
Language: Go
License: MIT
License Family: permissive
Topics: go, golang, sql, orm, sql-orm, hacktoberfest
Last push: 2025-12-15T13:01:05+00:00

## Health v2 (maintenance only)
Score: 48/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 57, release rhythm 8, longevity 100
- inputs: {"age_days": 3842, "days_push": 261, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1458, forks 74 (observed 2026-08-28T04:04:47.157110+00:00)

## What it is
Reform is a type-safe ORM for Go built on database/sql, using non-empty interfaces, code generation, and initialization-time reflection instead of runtime reflection and interface{}. It supports PostgreSQL, MySQL, SQLite3, and Microsoft SQL Server.

## Use cases
- map Go structs to SQL database tables
- type-safe database queries in Go without runtime reflection
- work with PostgreSQL, MySQL, SQLite, or SQL Server from Go
- generate ORM model code with go generate
- CRUD operations over database/sql

## When to choose
- you want a simple, type-safe ORM layered on database/sql
- you prefer code generation over runtime reflection
- you need support for multiple SQL dialects including SQL Server

## When to avoid
- you need advanced ORM features like complex associations or migrations
- you prefer query builders or raw SQL without code generation
- you need a heavily maintained project with frequent updates

## Facets
- artifact type: library
- maturity: maintenance
- function: orm, database, database-driver, serialization
- domain: databases, backend, web-development, developer-tools
- platform: go, windows, cross-platform
- tags: sql, code-generation, postgresql, mysql, sqlite3, sql-server, database-sql, type-safe, linux, macos

## Member repositories
- go-reform/reform (main) score 48

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:04:47.157110+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T04:35:30.416218+00:00, confidence not recorded.
  - readme: https://github.com/go-reform/reform (fetched 2026-08-28T04:04:47.157110+00:00, sha d3a0be6dccfa)
  - homepage: https://gopkg.in/reform.v1 (fetched 2026-08-29T11:44:20.687477+00:00, sha 87ea8c84ee1a)
- Data as of 2026-08-30T08:39:29.467469+00:00.
