Skip to content

The best SWR alternatives

8 tools that do a similar job to SWR, 8 of them open source. Each entry says what it does and who it suits, so you can pick the one that fits instead of the most famous.

You're replacing

SWR

A React hook library for fetching data, with caching and automatic refresh.

  1. 1

    TanStack Query

    Open source · MIT · ★ 50.5k

    A library for fetching, caching, and updating data from servers in web apps.

    Best for: Frontend developers building apps that load data from a server; Teams using React, Solid, Svelte, or Vue who want less hand-written loading and caching code

  2. 2

    Apollo Client

    Open source · MIT · ★ 19.8k

    A JavaScript and TypeScript library for loading and caching GraphQL data in web apps.

    Best for: Developers building React apps that query a GraphQL API; Teams using TypeScript who want typed GraphQL operations

  3. 3

    useHooks

    Open source · MIT · ★ 11.5k

    A set of ready-made React hooks for common UI and browser tasks, built to be safe on the server.

    Best for: React developers who want ready-made hooks for common browser tasks; Teams building apps with React v18.0.0 or newer

  4. 4

    NativeBase

    Open source · MIT · ★ 20.4k

    Accessible React Native and web UI component library; now in maintenance mode, succeeded by gluestack-ui.

    Best for: Teams maintaining an existing app already built on NativeBase; Developers who need to keep an existing NativeBase v3 codebase running

  5. 5

    Zustand

    Open source · MIT · ★ 58.9k

    A small React state-management library built on hooks, with no providers needed.

    Best for: React developers who want simpler shared state than Redux; Apps that need state shared across many components without wrapping them in providers

  6. 6

    TanStack Table

    Open source · MIT · ★ 28.5k

    Headless library for building customizable data tables in TypeScript and JavaScript.

    Best for: Developers building custom data tables in React, Vue, Solid, Svelte or another supported framework; Teams that already have a design system and want a table that matches it

  7. 7

    why-did-you-render

    Open source · MIT · ★ 12.5k

    A development-only tool that logs React re-renders that may be avoidable, so you can find slow spots.

    Best for: React developers investigating slow screens with many memoized or pure components; Teams debugging why a large memo component keeps re-rendering after a prop like an inline style object changes

  8. 8

    react-i18next

    Open source · MIT · ★ 10.1k

    Adds translation support to React apps, built on the i18next ecosystem.

    Best for: React developers who need their app available in several languages; Teams already using the i18next ecosystem or planning to support server-side i18next too

How we pick: tools in the same category that solve the same problem, projects that name each other as alternatives, and open-source projects that describe themselves as an alternative to SWR. We don't take payment for placement.