Features
Database
Type-safe PostgreSQL with Drizzle ORM and migration support.
Docs are in beta — content is improving rapidly. Found something missing? Open an issue on GitHub or reach out on Twitter.
BetterStarter uses Drizzle ORM with PostgreSQL — a lightweight, type-safe ORM with first-class migration support.
What's Included
- Schema definitions in
src/db/schema/with full TypeScript types - Migration workflow: generate SQL → review → apply
- Drizzle Studio for visual DB inspection
- Support for local Postgres, Supabase, Neon, and any PostgreSQL provider
Commands
pnpm db:generate # generate SQL migration from schema changes
pnpm db:migrate # apply pending migrations
pnpm db:push # sync schema directly (dev only)
pnpm db:studio # open Drizzle StudioSchema Location
src/db/schema/
index.ts # re-exports all tables
auth.ts # user, session, account tables (managed by Better Auth)
billing.ts # billing_customer, entitlement, subscriptionAdd your own tables by creating new files in src/db/schema/ and exporting them from index.ts.