# citusdata/citus

Distributed PostgreSQL as an extension

Repository: https://github.com/citusdata/citus
Canonical: https://ross.abutalabs.com/products/citus
Homepage: https://www.citusdata.com
Language: C
License: AGPL-3.0
License Family: copyleft
Topics: database, citus, multi-tenant, postgresql, scale, sharding, sql, distributed-database, postgres, citus-extension, database-cluster, relational-database
Last push: 2026-08-26T15:21:31+00:00

## Health v2 (maintenance only)
Score: 98/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 99, release rhythm 96, longevity 100
- inputs: {"age_days": 3866, "days_push": 7, "days_rel": 27, "gap_med": 17.5, "n_releases_24m": 13}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 12730, forks 784 (observed 2026-08-28T04:10:59.675444+00:00)

## What it is
Citus is an open-source PostgreSQL extension (written in C) that transforms Postgres into a distributed database by sharding tables across a cluster of nodes with a distributed query planner and executor. It supports row-based and schema-based sharding, reference tables, columnar storage, and querying from any node, all while remaining a Postgres extension rather than a fork.

## Use cases
- scale out a multi-tenant SaaS Postgres database by sharding on tenant_id
- run sub-second analytical queries over billions of rows in real time
- shard PostgreSQL horizontally without giving up SQL, joins, and transactions
- use Postgres as a storage backend for microservices with distributed schemas
- process large volumes of time series or IoT data for real-time analytics
- add worker nodes and rebalance shards as data grows
- compress and speed up scans with columnar storage on Postgres tables

## When to choose
- your multi-tenant SaaS app is hitting single-node Postgres limits on data size or concurrency
- you need real-time analytics dashboards with sub-second responses over large datasets
- you want horizontal scaling while keeping full SQL, ACID transactions, and the Postgres ecosystem
- you want to stay in sync with new Postgres releases instead of running a fork
- you need both transactional and analytical workloads on one database

## When to avoid
- your dataset fits comfortably on a single Postgres node with room to grow
- you need a fully managed distributed database without operating your own cluster
- your workload has no natural distribution key and doesn't fit schema-based sharding
- you require a license more permissive than AGPL-3.0 for your product
- you depend on Postgres features or extensions that Citus doesn't yet support on distributed tables

## Facets
- artifact type: library
- maturity: active
- function: database, caching, search-engine
- domain: databases, microservices, big-data, analytics, backend
- platform: cloud, self-hosted
- tags: postgresql-extension, sharding, distributed-sql, multi-tenant, columnar-storage, horizontal-scaling, real-time-analytics, database-cluster, linux, macos, docker

## Member repositories
- citusdata/citus (main) score 98

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:10:59.675444+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-29T17:13:50.099619+00:00, confidence not recorded.
  - readme: https://github.com/citusdata/citus (fetched 2026-08-28T04:10:59.675444+00:00, sha bd1538070b36)
  - homepage: https://www.citusdata.com (fetched 2026-08-29T08:10:09.426958+00:00, sha c8a173b74cc0)
  - site_page: https://www.citusdata.com/getting-started (fetched 2026-08-29T08:10:09.436675+00:00, sha 75ffd8d8bf25)
  - site_page: https://www.citusdata.com/about/contact_us (fetched 2026-08-29T08:10:09.441361+00:00, sha 0effa292fa4b)
  - site_page: https://www.citusdata.com/about/our-story (fetched 2026-08-29T08:10:09.443149+00:00, sha 49a842870f42)
  - site_page: https://docs.citusdata.com/en/stable/get_started/tutorial_microservices.html (fetched 2026-08-29T08:10:09.450743+00:00, sha 653acfb59878)
  - site_page: https://www.citusdata.com/faq (fetched 2026-08-29T08:10:09.439256+00:00, sha 820a14c28faa)
  - site_page: https://www.citusdata.com/blog/2026/02/17/distribute-postgresql-18-with-citus-14 (fetched 2026-08-29T08:10:09.444907+00:00, sha cfc98f21a98d)
  - site_page: https://www.citusdata.com/use-cases/multi-tenant-apps (fetched 2026-08-29T08:10:09.446853+00:00, sha 566d567c36a1)
  - site_page: https://www.citusdata.com/use-cases/real-time-analytics (fetched 2026-08-29T08:10:09.448655+00:00, sha 3e4ec9138d5c)
- Data as of 2026-08-30T08:39:29.467469+00:00.
