# TanStack/db

The reactive client store for your API.

Repository: https://github.com/TanStack/db
Canonical: https://ross.abutalabs.com/products/db
Homepage: https://tanstack.com/db
Language: TypeScript
License: MIT
License Family: permissive
Last push: 2026-08-26T22:56:12+00:00

## Health v2 (maintenance only)
Score: 83/100 (v2, computed 2026-09-03T02:39:23.370411+00:00)
- activity 99, release rhythm 87, longevity 38
- inputs: {"age_days": 540, "days_push": 7, "days_rel": 8, "gap_med": 0.0, "n_releases_24m": 1479}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 3889, forks 259 (observed 2026-08-28T04:08:28.318087+00:00)

## What it is
TanStack DB is a reactive client-side store that turns API data into typed, normalized collections and runs sub-millisecond live relational queries over them. It extends TanStack Query with collections, live queries, and instant optimistic mutations, working with REST APIs, sync engines, or any data source.

## Use cases
- avoid endpoint sprawl by loading data into normalized client-side collections
- run live relational queries (joins, filters, aggregations) that update in real time
- apply optimistic writes that update the UI instantly while persistence catches up
- build fast React/Vue/Svelte/Solid dashboards without re-render storms
- add offline support and SQLite-backed persistence to a web app
- replace view-specific API endpoints with query-driven sync

## When to avoid
- you need a real server-side database or heavy transactional guarantees
- your project is not on TanStack Query or a compatible data-loading model
- you need a fully stable, non-beta library for production-critical systems
- your data model is tiny and simple enough that a query cache suffices

## Facets
- artifact type: library
- maturity: active
- function: database, caching, state-management, orm, http-client
- domain: frontend, web-development, databases, developer-tools
- platform: browser, cross-platform
- tags: client-database, reactive-queries, optimistic-updates, normalized-collections, tanstack-query, differential-dataflow, offline-support, react, vue, svelte, solid, nodejs, typescript

## Member repositories
- TanStack/db (main) score 83

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:08:28.318087+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-29T18:25:38.204279+00:00, confidence not recorded.
  - readme: https://github.com/TanStack/db (fetched 2026-08-28T04:08:28.318087+00:00, sha e428a20dffb5)
  - homepage: https://tanstack.com/db (fetched 2026-08-29T09:20:02.394577+00:00, sha 229121963b89)
  - site_page: https://tanstack.com/db/latest/docs/overview (fetched 2026-08-29T09:20:02.398887+00:00, sha 524faadb5ba7)
  - site_page: https://tanstack.com/db/latest/docs/guides/live-queries (fetched 2026-08-29T09:20:02.401268+00:00, sha b232dfbcae93)
  - site_page: https://tanstack.com/db/latest/docs/reference/index (fetched 2026-08-29T09:20:02.404842+00:00, sha 1c8d374e488a)
  - site_page: https://tanstack.com/db/latest/docs/blog (fetched 2026-08-29T09:20:02.406802+00:00, sha 4a92a980979d)
  - site_page: https://tanstack.com/db/latest/docs/framework (fetched 2026-08-29T09:20:02.408567+00:00, sha ed8279cee05c)
  - site_page: https://tanstack.com/db/latest/docs/contributors (fetched 2026-08-29T09:20:02.410243+00:00, sha 6a827e64a589)
  - site_page: https://tanstack.com/db/latest/docs/npm-stats (fetched 2026-08-29T09:20:02.411960+00:00, sha 01da04794294)
  - site_page: https://tanstack.com/blog (fetched 2026-08-29T09:20:02.397154+00:00, sha f45f670c0ce6)
- Data as of 2026-08-30T08:39:29.467469+00:00.
