clickhouse-driver
Python driver with native interface for ClickHouse
Decision gist · record as of 2026-08-14
Yes. The package is actively maintained, has no known vulnerabilities, supports modern Python versions, and provides both low-level and DB API interfaces suitable for different use cases. Medium install friction is typical for compiled drivers and poses no practical barrier. MIT licensing imposes no restrictions. Install if you need to query ClickHouse from Python.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- ClickHouse server must be running and accessible at the specified host.
- Medium install friction due to compiled wheels across multiple architectures and Python versions (3.9–3.14).
- Active maintenance with a recent release 28 days ago and ongoing repository activity suggests reliable support.
License · maintenance · safety
MIT (permissive) — MIT license permits use in commercial and proprietary projects with minimal restrictions; attribution is required but no copyleft obligations apply.
last release 2026-07-17 (28 days) · last repo commit 2026-07-22 · 1,302 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 16,838,476 downloads/mo, #1,136 on PyPI
Alternatives
Verify before relying
pip install clickhouse-driver
from clickhouse_driver import Client
client = Client('localhost')
result = client.execute('SELECT 1')
print(result)- Whether NumPy array support requires an additional optional dependency or is built-in.
- Default port and connection parameters for the Client.
- Support for asynchronous operations (description references aioch wrapper but does not detail native async support).
What it is and what it does
Clickhouse-driver is a native TCP client library for ClickHouse, the columnar analytics database. It provides two interfaces: a direct Client class for executing queries and retrieving results, and a DB API 2.0 compliant connection interface for applications expecting standard Python database semantics. The driver handles ClickHouse's native protocol directly rather than HTTP, supporting features like compression, TLS encryption, query settings, external data, and block-by-block result streaming. It includes comprehensive type support for ClickHouse's data types (integers, floats, dates, strings, arrays, tuples, maps, JSON, and more) and can work with multiple hosts.
The package depends on pytz and tzlocal for timezone handling, which is essential for ClickHouse's DateTime and DateTime64 types. It is actively maintained, supports Python 3.9 through 3.14, and has been in development since 2017. The library is positioned for developers building analytics applications, data pipelines, or tools that need to query ClickHouse clusters from Python.
Use it for
- Execute analytical queries against ClickHouse and retrieve results in a Python application.
- Build ETL pipelines that insert bulk data into ClickHouse tables using parameterized queries.
- Integrate ClickHouse as a backend for a web application using the DB API 2.0 interface.
- Stream large result sets block-by-block to avoid loading entire datasets into memory.
- Query ClickHouse with TLS encryption and compression for secure, efficient network communication.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes.
The package is actively maintained, has no known vulnerabilities, supports modern Python versions, and provides both low-level and DB API interfaces suitable for different use cases. Medium install friction is typical for compiled drivers and poses no practical barrier. MIT licensing imposes no restrictions. Install if you need to query ClickHouse from Python.
Install
clickhouse-driver on PyPI
Before you install
Medium install friction due to compiled wheels across multiple architectures and Python versions (3.9–3.14). Active maintenance with a recent release 28 days ago and ongoing repository activity suggests reliable support.
ClickHouse server must be running and accessible at the specified host.
License in practice
MIT license permits use in commercial and proprietary projects with minimal restrictions; attribution is required but no copyleft obligations apply.
Quickstart
pip install clickhouse-driver
from clickhouse_driver import Client
client = Client('localhost')
result = client.execute('SELECT 1')
print(result)
Verify before relying
- Whether NumPy array support requires an additional optional dependency or is built-in.
- Default port and connection parameters for the Client.
- Support for asynchronous operations (description references aioch wrapper but does not detail native async support).
Package facts
| License | MIT permissive |
| Python support | Supports the current Python release <4,>=3.9 |
| Install friction | Medium. Platform-specific wheel |
| Runtime dependencies | 2 packagespytztzlocal |
| Maintenance | Actively maintained 28 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 16,838,476 / month, #1,136 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Development Status :: 4 - BetaEnvironment :: ConsoleIntended Audience :: DevelopersIntended Audience :: Information TechnologyLicense :: OSI Approved :: MIT LicenseOperating System :: OS IndependentProgramming Language :: Python :: 3Programming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14Programming Language :: Python :: 3.9Programming Language :: Python :: Implementation :: PyPyProgramming Language :: SQLTopic :: DatabaseTopic :: Scientific/Engineering :: Information AnalysisTopic :: Software DevelopmentTopic :: Software Development :: LibrariesTopic :: Software Development :: Libraries :: Application FrameworksTopic :: Software Development :: Libraries :: Python Modules |
Evidence: clickhouse_driver-0.2.11-cp310-cp310-macosx_10_9_x86_64.whl; clickhouse_driver-0.2.11-cp310-cp310-macosx_11_0_arm64.whl; clickhouse_driver-0.2.11-cp310-cp310-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl; clickhouse_driver-0.2.11-cp310-cp310-manylinux2014_ppc64le.manylinux_2_17_ppc64le.manylinux_2_28_ppc64le.whl; clickhouse_driver-0.2.11-cp310-cp310-manylinux2014_s390x.manylinux_2_17_s390x.manylinux_2_28_s390x.whl; clickhouse_driver-0.2.11-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl; clickhouse_driver-0.2.11-cp310-cp310-musllinux_1_2_aarch64.whl; clickhouse_driver-0.2.11-cp310-cp310-musllinux_1_2_ppc64le.whl; clickhouse_driver-0.2.11-cp310-cp310-musllinux_1_2_s390x.whl; clickhouse_driver-0.2.11-cp310-cp310-musllinux_1_2_x86_64.whl; clickhouse_driver-0.2.11-cp310-cp310-win32.whl; clickhouse_driver-0.2.11-cp310-cp310-win_amd64.whl; clickhouse_driver-0.2.11-cp311-cp311-macosx_10_9_x86_64.whl; clickhouse_driver-0.2.11-cp311-cp311-macosx_11_0_arm64.whl; clickhouse_driver-0.2.11-cp311-cp311-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl; clickhouse_driver-0.2.11-cp311-cp311-manylinux2014_ppc64le.manylinux_2_17_ppc64le.manylinux_2_28_ppc64le.whl; clickhouse_driver-0.2.11-cp311-cp311-manylinux2014_s390x.manylinux_2_17_s390x.manylinux_2_28_s390x.whl; clickhouse_driver-0.2.11-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl; clickhouse_driver-0.2.11-cp311-cp311-musllinux_1_2_aarch64.whl; clickhouse_driver-0.2.11-cp311-cp311-musllinux_1_2_ppc64le.whl
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “clickhouse db api”
- clickhouse-driverA native TCP driver for ClickHouse that executes queries and returns…
- airflow-clickhouse-pluginProvides Apache Airflow operators and hooks to execute SQL queries…
- clickhouse-sqlalchemySQLAlchemy dialect for ClickHouse that enables ORM-style database…
Give your agent the search over MCP, or paste the wish link into any chat.
More Software Development packages
Provides backported and experimental type hints for Python 3.9+, allowing use of newer typing features on older Python versions and enabling early experimentation with type system PEPs before they enter the standard library.
NumPy provides an N-dimensional array object and a comprehensive suite of mathematical, linear algebra, Fourier transform, and random number functions for scientific computing in Python.
FastAPI is a Python web framework for building REST APIs using type hints, with automatic request validation, serialization, and interactive API documentation.
Provides a way to document function parameters, class attributes, return types, and variables inline using Python's `Annotated` type hint syntax instead of traditional docstrings.
Typer builds command-line applications from Python functions using type hints, automatically generating help text, argument parsing, and shell completion.
Install it if you are building CLIs in Python.
Distlib provides low-level packaging utilities for building, distributing, and managing Python software—including metadata handling, version specifiers, wheel support, script installation, and dependency resolution.
See also aiochclient · asynch · clickhouse-pool · clickhouse-sqlalchemy · infi.clickhouse-orm · django-clickhouse-backend · airflow-clickhouse-plugin · clickhouse-connect · chdb · chdb-core