Authdog

React Native / Expo

Mobile auth for React Native

Add secure sign-in to your React Native or Expo app: hosted login via deep links, pluggable secure storage, and familiar hooks that mirror the rest of the Authdog Web SDK.

One provider
Wrap your app in AuthdogProvider backed by a secure store and every screen's hooks resolve the verified session.
Validated before storage
Tokens are verified as a JWT and the identity host is allowlisted, so a malicious redirect can't slip a token into storage.
Pluggable secure storage
Use expo-secure-store for hardware-backed encryption, or plug in AsyncStorage or your own async store.
Expo or bare RN
react and react-native are the only peers, so the SDK drops into either setup.

Wrap your app

// App.tsx
import {
  AuthdogProvider,
  createSecureStoreAdapter,
} from "@authdog/react-native"

export default function App() {
  return (
    <AuthdogProvider
      publicKey={PK}
      storage={createSecureStoreAdapter(SecureStore)}
    >
      <RootNavigator />
    </AuthdogProvider>
  )
}

Sign in via deep links

// SignInScreen.tsx
import { useSignIn, useRedirectHandler } from "@authdog/react-native"

const { signIn } = useSignIn()
const { handleRedirect } = useRedirectHandler()

// open hosted login, finish via deep link
signIn({ redirectUrl: "myapp://callback" })

Built for mobile

Everything mobile apps need

Deep-link login, secure token storage, and familiar hooks for React Native and Expo.

01

React Native & Expo

A provider, hooks, and a deep-link login flow built for mobile. Works in Expo and bare React Native alike, with react and react-native as the only peers.

  • Expo and bare RN
  • Two peer dependencies
03

Pluggable secure storage

Bring expo-secure-store, AsyncStorage, or your own async store. Tokens are kept in hardware-backed, encrypted storage when you wire it up.

  • expo-secure-store adapter
  • Bring your own store
04

Secure by default

Tokens are validated as a JWT before storage and the identity host is constrained to the trusted-host allowlist, so tokens can't be exfiltrated.

  • JWT validated first
  • Trusted-host allowlist
05

Familiar hooks

useUser, useSession, useSignIn, and useSignOut mirror the rest of the Authdog Web SDK, so mobile feels like the web you already know.

  • Same hook names as web
  • Reactive session state
06

Typed SDK

A fully typed SDK gives you autocomplete for the session, user, and permissions returned to your screens.

  • Session, user, permissions
  • Autocomplete in screens
01

Install

Add @authdog/react-native and a secure storage adapter.

02

Add the provider

Wrap your root navigator in AuthdogProvider.

03

Open login

Call signIn() with your deep-link redirect and read the session from hooks.

Add auth to your mobile app.

Install the SDK, wrap your app in the provider, and open the hosted login flow today. Free to start, with secure defaults built in.