For a TypeScript-first ORM for SQL databases, the strongest matches are sequelize/sequelize (Sequelize is a TypeScript ORM library that maps database), prisma/prisma (Prisma is a TypeScript-native ORM that generates type-safe clients) and mikro-orm/mikro-orm (Mikro-ORM is a TypeScript-native ORM that provides a type-safe). typeorm/typeorm and drizzle-team/drizzle-orm round out the shortlist. Each is ranked by relevance to your query, popularity and recent activity.
Type-safe object-relational mapping libraries designed specifically for TypeScript applications interacting with SQL databases.
Sequelize is an object-relational mapping library that provides a unified interface for managing relational data through code. By implementing the Active Record pattern, it maps database tables to application objects, allowing developers to perform standard create, read, update, and delete operations using high-level method calls. The library abstracts complex database interactions by translating these calls into optimized, engine-specific SQL statements, ensuring consistent behavior across different database systems. The project distinguishes itself through a comprehensive suite of tools for
Sequelize is a TypeScript ORM library that maps database tables to objects, supporting multiple SQL backends, schema migrations, transactions, and connection pooling, making it a comprehensive and flagship choice for your search.
Prisma is a database toolkit that provides a unified access layer for interacting with relational and document databases. It centers on a declarative schema modeling approach, where developers define their data structures in a human-readable language. This schema serves as the single source of truth, from which the toolkit automatically generates type-safe database clients that provide compile-time validation and editor autocomplete for all data operations. The project distinguishes itself through a high-performance, Rust-based query engine that handles query planning and connection pooling o
Prisma is a TypeScript-native ORM that generates type-safe clients from a declarative schema, supports multiple SQL databases, includes schema migrations, transactions, and connection pooling – exactly what the visitor needs.
Mikro-ORM is a TypeScript-based object-relational mapping system that provides a unified persistence layer for Node.js applications. It translates TypeScript entities into relational or document-based database schemas, supporting a variety of engines including PostgreSQL, MySQL, MariaDB, MS SQL Server, SQLite, and MongoDB. The project implements the data mapper pattern to decouple in-memory domain models from the database persistence layer. It utilizes a unit of work pattern to track entity changes in memory and commit them in a single coordinated database transaction. The library covers com
Mikro-ORM is a TypeScript-native ORM that provides a type-safe query builder, supports multiple SQL databases, includes schema migrations, transactions via its unit of work pattern, and connection pooling, matching all the required features.
TypeORM is an object-relational mapper for TypeScript and JavaScript that bridges the gap between object-oriented application code and relational database tables. It provides a comprehensive data persistence layer that allows developers to define database entities using class decorators or configuration objects, enabling seamless interaction with data through object-oriented patterns. The project distinguishes itself through a flexible architecture that supports both the data mapper and repository patterns, alongside a fluent query builder that translates high-level method calls into platform
TypeORM is a TypeScript-native ORM that provides a type-safe query builder, supports multiple SQL databases (MySQL, PostgreSQL, SQLite, etc.), includes a full schema migration system, and handles transactions — covering all the requested features for a modern, strongly-typed developer experience.
Drizzle ORM is a TypeScript-native database toolkit providing type-safe SQL query building, schema management, and automated migrations across PostgreSQL, MySQL, SQLite, and SingleStore.
Drizzle ORM is a TypeScript-native ORM with a type-safe query builder, automated schema migrations, and support for multiple SQL backends (PostgreSQL, MySQL, SQLite, SingleStore), directly matching your search for a modern, strongly-typed database toolkit.
Knex is a programmatic SQL query builder for Node.js applications. It provides a unified interface for generating database statements and managing structural versioning through a schema migration tool. The project features a multi-dialect database layer that translates programmatic queries into specific syntax for relational databases including PostgreSQL, MySQL, SQLite3, and MSSQL. This allows for writing database logic that remains compatible across different systems. The system includes infrastructure for managing reusable database connection pools and handling relational transactions to
Knex is a programmatic SQL query builder with schema migrations, not an ORM, and it is written in JavaScript rather than being TypeScript-native, so it does not provide the strong typing and ORM features you're looking for.
GORM is a developer-focused object-relational mapping library for Go that provides a comprehensive data persistence framework. It serves as a database access layer, allowing developers to map application structures to database tables and perform CRUD operations using a fluent, type-safe query builder instead of writing raw SQL. The library distinguishes itself through its association-aware persistence, which automatically tracks and synchronizes complex entity relationships during database operations. It utilizes a driver-agnostic interface to maintain consistent behavior across various stora
GORM is a Go ORM with comprehensive features like type-safe queries, migrations, transactions, and connection pooling, but this search is for a TypeScript-native ORM, so the language is a mismatch.
Ent is a statically typed entity framework for Go that models database structures as a graph of nodes and edges. It functions as a code generation engine that transforms schema definitions into type-safe database clients, query builders, and migration scripts. By representing data as interconnected entities, the framework enables intuitive traversal of complex relationships and ensures that database interactions remain consistent with the application model at compile time. The framework distinguishes itself through its graph-based approach to data modeling and its reliance on compile-time cod
Ent is a statically typed entity framework for Go, so it does not meet the TypeScript-native language requirement, though it shares the ORM and type-safe query builder concept.
Knex is a multi-dialect database client that provides a programmatic SQL query builder, a connection pool manager, and a versioned schema migration tool. It enables programmatic database interaction across multiple SQL engines, including PostgreSQL, MySQL, SQLite3, SQL Server, CockroachDB, and Oracle. The project distinguishes itself through a fluent interface for constructing complex SQL statements and a dedicated framework for database seeding. It utilizes specialized dialects to translate generic query representations into database-specific syntax while maintaining a consistent API across
Knex is a powerful multi-dialect SQL query builder and migration tool, not a full ORM — it gives you programmatic SQL control but lacks the object‑mapping layer and TypeScript‑native design this search requires.
Gel is an object-relational database system that models data as a graph of interconnected objects. By utilizing a strongly typed schema, it enables complex relational queries and polymorphic data structures without the need for traditional join tables. The system integrates native vector storage and similarity search operators, allowing it to function as both a relational and a vector database for semantic data retrieval. The platform distinguishes itself through a comprehensive suite of developer-centric automation tools. It features a declarative migration system that tracks and versions sc
Gel is a graph-relational database system, not a TypeScript ORM library for SQL databases — it is a database itself with its own query language, so it does not serve as a type-safe query builder or ORM for SQL backends.
This project is a MySQL database driver and client for Node.js. It provides a JavaScript implementation of the MySQL protocol to facilitate connecting to, querying, and managing data within MySQL databases. The driver includes a connection pool manager to maintain a cache of reusable database connections, reducing the overhead of frequent network handshakes. It also supports row-by-row result streaming to process large datasets without loading entire result sets into memory. Core capabilities cover SQL query execution, the management of database transactions, and the coordination of multiple
This repository is a MySQL database driver for Node.js, not a TypeScript-native ORM—it handles low-level connection and query execution but lacks the type-safe query builder, schema migrations, and database-agnostic abstraction that a TypeScript ORM provides.
This project is a pure JavaScript database driver for Node.js that implements the native MySQL binary protocol. It serves as a comprehensive connector for managing persistent network links to MySQL servers, enabling applications to execute queries, manage transactions, and handle complex data operations without requiring external middleware. The driver distinguishes itself through its integrated support for connection pooling and distributed database routing. It maintains managed sets of reusable network sockets to optimize resource usage under high request volumes, while simultaneously provi
This is a low-level MySQL database driver for Node.js, not an ORM — it provides direct query execution and connection pooling but lacks a type-safe query builder, database-agnostic support, schema migrations, and the TypeScript-native typing you are seeking.
| Repository | Stars | Language | License | Last push |
|---|---|---|---|---|
| sequelize/sequelize | 30.3K | TypeScript | MIT | |
| prisma/prisma | 46.4K | TypeScript | Apache-2.0 | |
| mikro-orm/mikro-orm | 9.1K | TypeScript | MIT | |
| typeorm/typeorm | 36.5K | TypeScript | MIT | |
| drizzle-team/drizzle-orm | 34.8K | TypeScript | Apache-2.0 | |
| tgriesser/knex | 20.3K | JavaScript | MIT | |
| go-gorm/gorm | 39.8K | Go | MIT | |
| ent/ent | 17.1K | Go | Apache-2.0 | |
| knex/knex | 20.3K | JavaScript | MIT | |
| geldata/gel | 14.1K | Python | apache-2.0 |