jotai vs @tanstack/react-query

@tanstack/react-query is downloaded 13.0× more often than jotai (225,327,948 vs 17,318,930 per month), so it has the larger community and more answered questions online. jotai ships 71% less gzipped JavaScript (3.8 kB vs 13.3 kB), which matters if bundle size is a priority. Both projects are actively maintained.

Metricjotai@tanstack/react-query
Weekly downloads4,384,35551,850,189
Monthly downloads17,318,930225,327,948
GitHub stars21,18149,542
Minified size9.1 kB45.1 kB
Minified + gzipped3.8 kB13.3 kB
Dependencies01
Open issues7172
Last commit2026-06-012026-06-02
Latest version2.20.05.100.14
LicenseMITMIT

When to choose which

jotai

Bottom-up atomic state for React.

Choose it when: Fine-grained, composable state where you build up from small atoms and want derived/async state with Suspense.

  • + Fine-grained reactivity
  • + Great derived & async atoms
  • + Tiny
  • - Atomic mental model takes adjusting
  • - Can sprawl in big apps

@tanstack/react-query

Async server-state: caching, refetching and mutations.

Choose it when: Managing data from an API — caching, background refetch, pagination, mutations. It complements (not replaces) a client store.

  • + Best-in-class server cache
  • + Great devtools
  • + Handles refetch/stale data
  • - Not for client/UI state
  • - More config than SWR

Feature comparison

Featurejotai@tanstack/react-query
ParadigmAtoms (bottom-up)Async server cache
First-class TypeScript✓ Yes✓ Yes
Works outside ReactPartialPartial
Dedicated devtools✓ Yes✓ Yes
Built-in async / server state✓ Yes✓ Yes
BoilerplateLowLow

jotai

👻 Primitive and flexible state management for React

@tanstack/react-query

Hooks for managing, caching and syncing asynchronous and remote data in React

Related comparisons

Embed this comparison

A live badge for your README — it updates as the numbers change.

jotai vs @tanstack/react-query downloads
[![jotai vs @tanstack/react-query](https://devcompare.dev/badge/jotai-vs-tanstack-react-query.svg)](https://devcompare.dev/compare/jotai-vs-tanstack-react-query)

Data from npm, Bundlephobia and GitHub. Last updated 2026-06-02.