better-auth

Implement authentication and authorization for TypeScript applications with plugin-based features.

5|3|Updated Feb 21, 2026
One-click install
npx skills add https://github.com/mikkelkrogsholm/dev-skills --skill better-auth-mikkelkrogsholm
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: better-auth
Source: https://github.com/mikkelkrogsholm/dev-skills/tree/main/better-auth
Command: npx skills add https://github.com/mikkelkrogsholm/dev-skills --skill better-auth-mikkelkrogsholm

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) and assets (resource) components.

What problem does it solve?

This Skill simplifies the complex task of implementing robust authentication and authorization in TypeScript applications, providing a framework-agnostic solution with extensive features.

Core Features & Use Cases

  • Framework-Agnostic: Works with any TypeScript backend.
  • Comprehensive Features: Includes 2FA, Passkeys, Multi-tenancy, SSO, API Key Management, and more via plugins.
  • Use Case: Secure a SaaS application by implementing user login, team-based access control, and API key generation for third-party integrations.

Quick Start

Use the better-auth skill to generate a new user registration flow.

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 and authorization in a TypeScript application?

Authentication and authorization in TypeScript applications can be handled via a framework-agnostic solution using a plugin architecture. This approach manages user sessions, multi-factor authentication, and passkeys without locking you into a specific backend framework.

Can I add multi-factor authentication and passkeys to my TypeScript backend?

Yes, multi-factor authentication and passkeys can be added to TypeScript backends through dedicated plugins. The system requires registering the necessary plugins on both the server and client-side to enable full multi-factor and passkey functionality.

Does this authentication solution work with any TypeScript backend framework?

Yes, the authentication and authorization solution is framework-agnostic, meaning it works with any TypeScript backend. It handles user management and session control independently of your chosen web framework through its plugin architecture.

What is the best way to set up multi-tenancy and SSO for a SaaS application in TypeScript?

Setting up multi-tenancy and SSO for TypeScript SaaS applications is best handled through an authentication solution with dedicated plugins. You register the multi-tenancy and SSO plugins on both server and client sides to manage team-based access control.

How do I generate API keys for third-party integrations in a TypeScript app?

API keys for third-party integrations can be generated using an authentication system's API Key Management plugin. You must register the plugin on your server and client to securely handle API key generation and third-party access.

Why does a framework-agnostic auth solution require plugin registration on both server and client?

Framework-agnostic auth solutions require server and client-side plugin registration to ensure full functionality across the entire stack. This dual registration synchronizes user management and session control mechanisms between your backend and frontend.