better-auth

Implement authentication and authorization in TypeScript applications with Prisma ORM.

1|Updated Jan 31, 2026
One-click install
npx skills add https://github.com/allanninal/claude-code-skills --skill better-auth-allanninal
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: better-auth
Source: https://github.com/allanninal/claude-code-skills/tree/main/skills/better-auth
Command: npx skills add https://github.com/allanninal/claude-code-skills --skill better-auth-allanninal

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill simplifies the complex process of implementing robust authentication and user management in TypeScript applications, reducing boilerplate code and common security pitfalls.

Core Features & Use Cases

  • Authentication Flows: Handles email/password sign-up, sign-in, and social OAuth (Google, GitHub, Discord).
  • Session Management: Securely manages user sessions with configurable expiry and update intervals.
  • Use Case: Integrate secure user login and registration into your new Next.js application using Google OAuth and email verification with minimal custom code.

Quick Start

Configure the basic authentication setup in your TypeScript application using the provided example.

Frequently Asked Questions about better-auth

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I implement authentication in a TypeScript application with minimal boilerplate?

Authentication in TypeScript applications can be implemented using a framework that handles email/password sign-up, sign-in, and social OAuth flows. This reduces boilerplate code and avoids common security pitfalls.

Can I use Google OAuth and email verification for user login in Next.js?

Google OAuth and email verification are supported for Next.js applications. The framework provides adapters for Next.js to integrate secure user login and registration with minimal custom code.

Does this authentication framework support session management with configurable expiry?

Session management is fully supported, allowing you to securely manage user sessions with configurable expiry and update intervals without building the logic from scratch.

How does Prisma ORM integration work for database persistence in TypeScript auth?

Prisma ORM integration provides database persistence by connecting the authentication framework directly to your database. This stores user credentials and session data efficiently within your TypeScript application.

What is the best way to add social logins like GitHub and Discord to an Express app?

Adding social logins like GitHub and Discord to an Express app is handled through built-in OAuth integrations. The framework provides specific adapters for Express to streamline this process.

Why should I use a dedicated TypeScript framework instead of building authentication from scratch?

Using a dedicated TypeScript authentication framework reduces common security pitfalls and boilerplate code. It provides pre-built authorization flows, session management, and ORM integrations out of the box.