Introducing Better Auth InfrastructureJoin the waitlist →
Own Your Auth

The most comprehensive authentication framework for TypeScript.

git:(main)x

npm i better-auth

Get Started
export const auth = betterAuth({
database: new Pool({
connectionString: DATABASE_URL,
}),
emailAndPassword: {
enabled: true,
},
plugins: [
organization(),
twoFactor(),
]
})

Framework Agnostic

Support for popular frameworks.

Supports popular frameworks, including React, Vue, Svelte, Astro, Solid, Next.js, Nuxt, Tanstack Start, Hono, and more.Learn more

Authentication

Email & Password Authentication.

Built-in support for email and password authentication, with session and account management features.Learn more

Social Sign-on

Support multiple OAuth providers.

Allow users to sign in with their accounts, including GitHub, Google, Discord, Twitter, and more.Learn more

Two Factor

Multi Factor Authentication.

Secure your users accounts with two factor authentication with a few lines of code.Learn more

Multi Tenant

Organization Members and Invitation.

Multi tenant support with members, organization, teams and invitation with access control.Learn more

Plugin Ecosystem

A lot more features with plugins.

Improve your application experience with our official plugins and those created by the community.Learn more

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

"using better-auth for the first time holy sh** is it good, works so nice with typescript + drizzle."

Josh Tried Coding avatar
Josh Tried Coding

devrel @upstash

"We've been using @better_auth in prod @IndexBI and absolutely love it. Super comprehensive from day one.👏."

Xavier Pladevall avatar
Xavier Pladevall

Founder of IndexBI

"i swear @polar_sh and @better_auth developer experience should be mandatory teaching for all CS students."

Code with Antonio avatar
Code with Antonio

Content Creator

"i have been using better-auth for exon todo and it is like so fast, I set it up once and it just works."

Ryan Vogel avatar
Ryan Vogel

Founder of exon

"better-auth is a work of art.."

Vybhav Bhargav avatar
Vybhav Bhargav

Founding engineer @glyfspace

Roll your own auth with confidence in minutes!