Seamlessly integrate Better Auth with Convex databases for modern authentication patterns in full-stack TypeScript applications.
npm install @convex-dev/better-authConvex + Better Auth
Framework Agnostic
Support for popular frameworks.
Supports popular frameworks, including React, Vue, Svelte, Astro, Solid, Next.js, Nuxt, Tanstack Start, Hono, and more.
Authentication
Email & Password Authentication.
Built-in support for email and password authentication, with session and account management features.
Social Sign-on
Support multiple OAuth providers.
Allow users to sign in with their accounts, including GitHub, Google, Discord, Twitter, and more.
Two Factor
Multi Factor Authentication.
Secure your users accounts with two factor authentication with a few lines of code.
The @convex-dev/better-auth component provides adapters and utilities to connect Better Auth's authentication system with Convex's database layer. It handles session management and user data synchronization between Better Auth and your Convex schema.
This component enables you to use Better Auth's OAuth providers (Google, GitHub, etc.) while storing user data in Convex. It automatically syncs authentication events with your Convex database and provides type-safe access to user sessions in queries and mutations.
Install @convex-dev/better-auth and configure it to bridge Better Auth's authentication handlers with Convex's database operations. The component provides middleware and adapters that handle user creation, session management, and authentication state synchronization.
The @convex-dev/better-auth component supports all authentication providers that Better Auth offers, including OAuth providers like Google, GitHub, and Discord, as well as email/password and magic link authentication. The component handles syncing user data from any provider to your Convex database.
The @convex-dev/better-auth component automatically syncs Better Auth sessions with your Convex database. It provides utilities to access authenticated user data within Convex queries and mutations, maintaining session state consistency between the authentication layer and your database operations.
Yes, the @convex-dev/better-auth component allows you to define custom Convex schemas for user data while maintaining compatibility with Better Auth's authentication flow. You can extend user profiles with additional fields and relationships specific to your application needs.
The @convex-dev/better-auth component works with server-side rendering frameworks by providing utilities to validate sessions and access user data on the server. It integrates with Better Auth's SSR capabilities while maintaining access to Convex database operations.