# @privy-io/react-auth

> React client for the Privy Auth API

Latest version **3.48.1** (published 2026-10-09) · Apache-2.0 license · 0 weekly downloads

## Install

```sh
npm install @privy-io/react-auth
pnpm add @privy-io/react-auth
yarn add @privy-io/react-auth
bun add @privy-io/react-auth
```

## Health

**Score 55/100 (C)** — status: active.

Positive: no vulnerabilities; recently updated; high maintenance score.

Warnings: low downloads; no types; no esm support.

## Facts

| | |
|---|---|
| Version | 3.48.1 |
| Published | 2026-10-09 |
| First published | 2022-11-02 |
| Weekly downloads | 0 |
| License | Apache-2.0 |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | privy.io |
| Maintainers | payton-privy, sternhenri, asta-li, ahollenbach, ankushswar1, joshnaviprivy, ajin-privy, andrewprivyadmin |
| Keywords | authentication, authorization, identity, privacy, privy, user data, web3 |

## Links

- npm: https://www.npmjs.com/package/@privy-io/react-auth
- Homepage: https://docs.privy.io
- Issues: https://privy.io/slack
- npm.io page: https://npm.io/package/@privy-io/react-auth

## Alternatives

- [@clerk/clerk-expo](https://npm.io/package/@clerk/clerk-expo.md) — 133.6K weekly downloads
- [@pothos/plugin-authz](https://npm.io/package/@pothos/plugin-authz.md) — 12.4K weekly downloads
- [@bounded-sh/client](https://npm.io/package/@bounded-sh/client.md) — 3.2K weekly downloads
- [@luigi-project/plugin-auth-oauth2](https://npm.io/package/@luigi-project/plugin-auth-oauth2.md) — 2.3K weekly downloads
- [@nocobase/plugin-verification](https://npm.io/package/@nocobase/plugin-verification.md) — 2.0K weekly downloads

## Recent versions

- 3.48.1 (latest) — 2026-10-09
- 3.40.1-snapshot-20260904210808 (snapshot) — 2026-09-04
- 3.39.0-beta-20260828180615 (beta) — 2026-08-28
- 1.73.1-alpha-20240702142511 (alpha) — 2024-07-02
- 3.48.0 — 2026-10-07
- 3.47.0 — 2026-10-02
- 3.46.0 — 2026-09-28
- 3.45.0 — 2026-09-21
- 3.44.0 — 2026-09-18
- 3.43.0 — 2026-09-15
- 3.42.0 — 2026-09-09
- 3.41.0 — 2026-09-09
- 3.40.0 — 2026-09-03
- 3.39.0 — 2026-08-31
- 3.39.0-beta-20260827192706 — 2026-08-27
- … 1824 more at https://npm.io/package/@privy-io/react-auth/versions

## README

# @privy-io/react-auth

![pitch-2-slide-2](https://user-images.githubusercontent.com/3359083/234168988-04254782-0e67-420a-91f7-8e67b67207e5.png)

The Privy React Auth SDK allows you to authenticate your users with Privy in your React app.

Check out our [demo](https://demo.privy.io/)!

## Changelog

Our [changelog](https://docs.privy.io/reference/sdk/react-auth/changelog) contains the latest information about new releases, including features, fixes, and upcoming changes.

We use [Semantic Versioning](https://semver.org/) to track changes.

## Installing

```sh
pnpm install @privy-io/react-auth
```

## Basic Usage

Setup your integration by wrapping any React components that will use the Privy SDK with the `PrivyProvider`. This gives your wrapped components access to the Privy SDK and authentication context.

```tsx
// Import the PrivyProvider
import {PrivyProvider} from '@privy-io/react-auth';

// Wrap any components that will use the Privy SDK with the PrivyProvider – for example, in your `app` or `index` file
<PrivyProvider appId="<your-privy-app-id>">
  <Component {...pageProps} />
</PrivyProvider>;
```

Now, from within your React components, you can access the Privy SDK via the `usePrivy` hook!

```tsx
// Import the usePrivy hook
import {usePrivy} from '@privy-io/react-auth';

// Call usePrivy() from inside your React components
const {ready, authenticated, user, login, logout} = usePrivy();
```

---
_Source: https://npm.io/package/@privy-io/react-auth · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
