skillfed

aioodbc

ODBC driver for asyncio.

aioodbc v0.5.0 1.7M downloads/30d#3,665 on PyPI326
Permissive license Apache 2 DORMANT released

What it is and what it does

aioodbc is an asyncio wrapper around pyodbc that lets you query ODBC databases without blocking the event loop. It uses a thread pool internally to run blocking pyodbc calls, mirroring the approach taken by other async database drivers. The API mirrors pyodbc closely—you use await instead of synchronous calls—so if you know pyodbc, the transition is straightforward.

The package supports connection pooling with optional connection recycling, context managers for safe resource cleanup, and works with both the default asyncio event loop and uvloop. It targets Python 3.7+ and has been tested with versions up to 3.12. Since it delegates to pyodbc, it works with any ODBC data source depending on what drivers you have installed.

Use it for:

  • Building async web services that need to query legacy ODBC-only databases without blocking.
  • Async ETL pipelines that pull data from multiple ODBC sources concurrently.
  • Connection pooling for high-concurrency async applications to avoid exhausting system resources.
  • Migrating existing pyodbc code to async/await without rewriting database logic.
  • Testing async code paths that interact with ODBC databases using context managers.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

aioodbc provides async/await access to ODBC databases by wrapping pyodbc with asyncio support, using threads internally to avoid blocking the event loop.

Yes, if you need async access to ODBC databases and are comfortable with the dormant maintenance status. The package is stable, has no known vulnerabilities, and the API is mature. However, if you require active maintenance or are starting a new greenfield project, consider whether a more actively maintained async driver for your specific database might be a better fit.

Install

aioodbc on PyPI

pip

pip install aioodbc

uv

uv add aioodbc

poetry

poetry add aioodbc

Installing aioodbc

Before you install

Low friction install with a single runtime dependency (pyodbc). Maintenance is dormant—last release was 2023-10-28 over a year ago—but the repository remains active and the package is stable enough for production use in async contexts.

License in practice

Licensed under Apache 2 (permissive), so you can use it freely in commercial and open-source projects without copyleft obligations.

Quickstart

pip install aioodbc

import asyncio
import aioodbc

async def query():
    conn = await aioodbc.connect(dsn="Driver=SQLite;Database=db.db")
    cur = await conn.cursor()
    await cur.execute("SELECT 42;")
    rows = await cur.fetchall()
    await cur.close()
    await conn.close()

asyncio.run(query())

Requires unixODBC library and a corresponding ODBC driver installed on the system (e.g., libsqliteodbc for SQLite).

Verify before relying

  • Whether the dormant maintenance status poses risk for future Python or asyncio API changes.
  • Performance characteristics compared to other async database drivers in production workloads.
  • Thread pool sizing and tuning guidance for high-concurrency scenarios.

Package facts

License Apache 2 (permissive)
Python support supports the current Python release (>=3.7)
Install friction low — pure-Python wheel
Runtime dependencies 1 — pyodbc
Maintenance dormant — 1,021 days since the last release
Last repo commit
First released
Downloads 1,672,711/month — #3,665 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: aioodbc-0.5.0-py3-none-any.whl

Development Status :: 3 - AlphaEnvironment :: Web EnvironmentFramework :: AsyncIOIntended Audience :: DevelopersLicense :: OSI Approved :: Apache Software LicenseOperating System :: POSIXProgramming Language :: Python :: 3Programming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.7Programming Language :: Python :: 3.8Programming Language :: Python :: 3.9Topic :: DatabaseTopic :: Database :: Front-Ends

Tags

async odbc database accessasyncio sql drivernon-blocking odbc queriesasync database connection poolpyodbc async wrapperasyncio database clientasync cursor execution
async-databaseodbcconnection-pooling

More Database packages