v2.0 is now live

Type safety,
elegantly resolved.

A zero-dependency, edge-optimized ORM that treats your TypeScript definitions as the absolute source of truth. No code generation, no boilerplate.

Read Docs
schema.ts
import { schema, string, number } from 'typeshift-orm';
      
      export const User = schema({
        id: string().uuid().primary(),
        email: string().email().unique(),
        age: number().min(18).optional(),
        role: string().enum(['ADMIN', 'USER']).default('USER')
      });
      
      // Infers totally rigorous TS types natively
      type UserType = Infer<typeof User>;

Refined architecture.
Uncompromising performance.

Built strictly for modern v8 runtimes, TypeShift leverages advanced type inference to eliminate runtime overhead while providing a graceful developer experience.

Zero-Cost Abstractions

Our query builder compiles down to raw SQL at build time. Experience bare-metal performance with the safety of a heavy ORM.

Rigorous Type Inference

Deeply integrated with TypeScript's type system. If it compiles, your database queries are syntactically and relationally correct.

Edge-Native Design

Weighing in at less than 5kb gzipped and completely stateless. Perfectly engineered for Cloudflare Workers and Vercel Edge.

"Switching to TypeShift removed thousands of lines of boilerplate schema definitions. It is the most elegant piece of data infrastructure our engineering team has ever adopted."
Avatar
Marcus Reynolds
Staff Engineer, Vercel