chDB

[Edit this page](https://github.com/ClickHouse/clickhouse-docs/blob/main/docs/chdb/index.md)

chDB is a fast in-process SQL OLAP Engine powered by [ClickHouse](https://github.com/clickhouse/clickhouse) v25.8.2.1.
You can use it when you want to get the power of ClickHouse in a programming language without needing to connect to a ClickHouse server.

## Key features[​](#key-features "Direct link to Key features")

- **In-process SQL OLAP Engine** - Powered by ClickHouse, no need to install ClickHouse server
- **Multiple data formats** - Input & Output support for Parquet, CSV, JSON, Arrow, ORC and [70+ more formats](/docs/interfaces/formats)
- **Minimized data copy** - From C++ to Python with [python memoryview](https://docs.python.org/3/c-api/memoryview.html)
- **Rich Python Ecosystem Integration** - Native support for Pandas, Arrow, DB API 2.0, seamlessly fits into existing data science workflows
- **Zero dependencies** - No need for external database installations
- **DataStore API** - Pandas-compatible API with SQL optimization, supporting 630+ methods

## DataStore: Pandas-Compatible API[​](#datastore "Direct link to DataStore: Pandas-Compatible API")

**NEW!** DataStore provides a pandas-compatible API that combines familiar pandas syntax with ClickHouse performance.

Get Started on Hex

- 📖 [**Getting Started Tutorial**](https://app.hex.tech/partnerships/app/chDB-Tutorial-032XsQ4qoKtlXxcw49joav/latest) — set up your first connection
- 🚀 [**Extended 30-day Hex Trial**](https://app.hex.tech/signup/clickhouse-30) — full access to ClickHouse integrations

### One-Line Migration[​](#one-line-migration "Direct link to One-Line Migration")

```
# Just change your import - your pandas code works unchanged
- import pandas as pd
+ from chdb import datastore as pd

df = pd.read_csv("data.csv")
result = df[df['age'] > 25].groupby('city')['salary'].mean()
```

### Performance Highlights[​](#performance-highlights "Direct link to Performance Highlights")

|  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |
| --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- |
| Operation pandas DataStore Speedup|  |  |  |  |  |  |  |  |  |  |  |  | | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | | GroupBy count 347ms 17ms **19.93x**| Complex pipeline 2,047ms 380ms **5.39x**| Filter+Sort+Head 1,537ms 350ms **4.40x** | | | | | | | | | | | | | | | |

*Benchmarks on 10M rows*

### DataStore Features[​](#datastore-features "Direct link to DataStore Features")

- **630+ API methods** - 209 pandas DataFrame methods, 185+ accessor methods
- **Lazy evaluation** - Operations compile to optimized SQL
- **SQL pushdown** - Filters and aggregations run at the data source
- **Universal data sources** - Read from files, S3, databases, data lakes

Learn more: [DataStore Documentation](/docs/chdb/datastore)

## What languages are supported by chDB?[​](#what-languages-are-supported-by-chdb "Direct link to What languages are supported by chDB?")

chDB has the following language bindings:

- [Python](/docs/chdb/install/python) - [API Reference](/docs/chdb/api/python)
- [Go](/docs/chdb/install/go)
- [Rust](/docs/chdb/install/rust)
- [NodeJS](/docs/chdb/install/nodejs)
- [Bun](/docs/chdb/install/bun)
- [C and C++](/docs/chdb/install/c)

## How do I get started?[​](#how-do-i-get-started "Direct link to How do I get started?")

- If you're using [Go](/docs/chdb/install/go), [Rust](/docs/chdb/install/rust), [NodeJS](/docs/chdb/install/nodejs), [Bun](/docs/chdb/install/bun) or [C and C++](/docs/chdb/install/c), take a look at the corresponding language pages.
- If you're using Python, see the [getting started developer guide](/docs/chdb/getting-started) or the [chDB on-demand course](https://learn.clickhouse.com/user_catalog_class/show/1901178).

### For pandas Users[​](#for-pandas-users "Direct link to For pandas Users")

Start with the DataStore API for a familiar pandas experience with ClickHouse performance:

- [DataStore Quickstart](/docs/chdb/datastore/quickstart) - Installation and one-line migration
- [Migration from pandas](/docs/chdb/guides/migration-from-pandas) - Step-by-step migration guide
- [Pandas Cookbook](/docs/chdb/guides/pandas-cookbook) - Common patterns
- [Key Differences](/docs/chdb/guides/pandas-differences) - Important differences from pandas
- [Performance Guide](/docs/chdb/guides/pandas-performance) - Optimization tips

### DataStore API Reference[​](#datastore-reference "Direct link to DataStore API Reference")

- [Factory Methods](/docs/chdb/datastore/factory-methods) - Create from files, databases, cloud storage
- [Query Building](/docs/chdb/datastore/query-building) - SQL-style operations
- [Pandas Compatibility](/docs/chdb/datastore/pandas-compat) - 209 compatible methods
- [Accessors](/docs/chdb/datastore/accessors) - .str, .dt, .arr, .json, .url, .ip, .geo
- [Configuration](/docs/chdb/configuration) - Engine, logging, profiling
- [Debugging](/docs/chdb/debugging) - explain(), profiling, logging

### SQL API Guides[​](#sql-guides "Direct link to SQL API Guides")

- [Python API Reference](/docs/chdb/api/python) - Complete SQL API documentation
- [JupySQL](/docs/chdb/guides/jupysql)
- [Querying Pandas](/docs/chdb/guides/pandas)
- [Querying Apache Arrow](/docs/chdb/guides/apache-arrow)
- [Querying data in S3](/docs/chdb/guides/querying-s3)
- [Querying Parquet files](/docs/chdb/guides/querying-parquet)
- [Querying remote ClickHouse](/docs/chdb/guides/query-remote-clickhouse)
- [Using clickhouse-local database](/docs/chdb/guides/clickhouse-local)

## An introductory video[​](#an-introductory-video "Direct link to An introductory video")

Watch a brief introduction to chDB and learn how it brings ClickHouse's power to your Python environment:

## Performance benchmarks[​](#performance-benchmarks "Direct link to Performance benchmarks")

chDB delivers exceptional performance across different scenarios: