@tanstack/react-query

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


Keywords
async, cache, data, fetch, graphql, hooks, query, react, rest, solid, stale, stale-while-revalidate, svelte, typescript, update, vue
License
MIT
Install
npm install @tanstack/react-query@4.27.0

Documentation

TanStack Query

TanStack Query

An async state management library built to simplify fetching, caching, synchronizing, and updating server state.

  • Protocol‑agnostic fetching (REST, GraphQL, promises, etc.)
  • Caching, refetching, pagination & infinite scroll
  • Mutations, dependent queries & background updates
  • Prefetching, cancellation & React Suspense support

Get Involved

Partners

Code Rabbit Cloudflare
Query & you?

We're looking for TanStack Query Partners to join our mission! Partner with us to push the boundaries of TanStack Query and build amazing things together.

LET'S CHAT

Explore the TanStack Ecosystem

… and more at TanStack.com »