Skip to content
Agents tracked: 378 Downloads (7d): 244M down 5.7% GitHub stars: 8.4M VS Code installs: 151M Releases (7d): 407 Agent status: 1 with issues Updated Oct 10, 2026

SQLAlchemy

Python SQL toolkit and object-relational mapper for database abstraction.

Databases, ORMs and clients PyPI

Used in agent projects
250
2.0% of 12,697 public repos built with AI coding agents
Rank in databases, orms and clients
#5 of 30
by use in those projects
Downloads
85.7M
PyPI, last 7 days, sqlalchemy
GitHub stars
12.2K
last push Oct 9, 2026

How SQLAlchemy is used

SQLAlchemy is a dependency in 250 of the 12,697 public GitHub projects set up for AI coding agents that we scanned (2.0%), #5 of 30 in databases, orms and clients. The most used alternative there is Prisma. Projects that use it most often also use python-dotenv (71.6%), Pydantic (71.6%), FastAPI (68.4%). It is more common in projects set up for Roo Code (7.1%) than for OpenAI Codex (1.8%).

Often used with SQLAlchemy

python-dotenv71.6% of SQLAlchemy projects · 11.0× more than average
Pydantic71.6% of SQLAlchemy projects · 14.0× more than average
FastAPI68.4% of SQLAlchemy projects · 16.2× more than average
Uvicorn67.6% of SQLAlchemy projects · 15.8× more than average
Requests45.6% of SQLAlchemy projects · 8.6× more than average
Alembic44.8% of SQLAlchemy projects · 49.5× more than average
Pydantic Settings42.8% of SQLAlchemy projects · 21.7× more than average
NumPy42.4% of SQLAlchemy projects · 11.1× more than average

By coding agent

GitHub Copilot3.0% of projects set up for it
Claude Code2.7% of projects set up for it
Cursor3.0% of projects set up for it
Devin Desktop4.0% of projects set up for it
Gemini CLI2.1% of projects set up for it
Roo Code7.1% of projects set up for it
OpenAI Codex1.8% of projects set up for it
OpenCode1.9% of projects set up for it

Share of public repos configured for each agent that list SQLAlchemy as a dependency.

Install

Packagepip install sqlalchemy
Main stacksPython (243), Next.js (6), Other (1)
Example projectsJosh-XT/AGiXT, imbue-bit/AlphaGPT, learntocloud/learn-to-cloud-app, solana-developers/solana-cookbook, pavelzbornik/whisperX-FastAPI

Alternatives to SQLAlchemy

All databases, orms and clients

Tool Used in agent projectsDownloads / wk GitHub starsLicense
Prisma npm
Modern ORM with intuitive schema, migrations, and type-safe database queries.
381 (3.0%) 19M 23 Apache-2.0
pg npm
PostgreSQL client for Node.js with pure JavaScript and libpq API compatibility.
372 (2.9%) 63.4M 13.2K MIT
Drizzle ORM npm
TypeScript ORM for SQL databases with type safety and zero-runtime overhead.
323 (2.5%) 27.2M 36K Apache-2.0
Drizzle Kit npm
CLI migration tool for Drizzle ORM that auto-generates SQL migrations intelligently.
309 (2.4%) 22.3M 36K MIT
better-sqlite3 npm
Fastest and simplest SQLite library for Node.js with synchronous API.
162 (1.3%) 11.3M 7,513 MIT
psycopg2 pypi
Popular PostgreSQL adapter for Python with full database access and query execution.
143 (1.1%) 50.7M 3,656 LGPL with exceptions
Mongoose npm
MongoDB object modeling library providing schema validation and query building.
142 (1.1%) 6.6M 27.5K MIT
Neon Serverless Driver npm
PostgreSQL driver optimized for serverless environments from Neon.
126 (1.0%) 4.5M 552 MIT
Is SQLAlchemy right for your project? Ask AgentGid →