INSTALLATION

Get Better Auth Studio up and running in your project.

⚠️

Beta Version Notice

Better Auth Studio is currently in beta and in early development. You may encounter bugs or incomplete features. Please report any issues you find on our GitHub repository to help us improve the project. Your feedback is greatly appreciated!

🚀

Try the Beta Version

Experience the latest features, patches, and improvements by installing the beta version. The beta includes recent bug fixes, performance enhancements, and new functionality that may not be available in the stable release yet.

pnpm add -g better-auth-studio@beta

Note: The beta version may include experimental features.

QUICK START

Installation

Stable version:

pnpm add -g better-auth-studio

Beta version (recommended):

pnpm add -g better-auth-studio@beta

Or use pnpx to run it without installation:

pnpx better-auth-studio@beta

Basic Usage

1. Navigate to your Better Auth project directory

cd your-better-auth-project

2. Start the studio

pnpx better-auth-studio start

3. Open your browser

  • The studio will automatically open at http://localhost:3000
  • Or manually navigate to the URL shown in the terminal

PREREQUISITES

Before using Better Auth Studio, ensure you have:

  • Node.js (v18 or higher)
  • A Better Auth project with a valid auth.ts configuration file
  • Database setup (Prisma, Drizzle, or SQLite)

CONFIGURATION

Supported Database Adapters

Better Auth Studio automatically detects and works with:

Prisma (prismaAdapter)
Drizzle (drizzleAdapter)
SQLite (new Database() from better-sqlite3)
PostgreSQL (via Prisma or Drizzle)
MySQL (via Prisma or Drizzle)

Example Configuration Files

Prisma Setup

// auth.ts
import { betterAuth } from "better-auth";
import { prismaAdapter } from "better-auth/adapters/prisma";
import { PrismaClient } from "@prisma/client";

const prisma = new PrismaClient();

export const auth = betterAuth({
  database: prismaAdapter(prisma, {
    provider: "postgresql", // or "mysql", "sqlite"
  }),
  // ... other config
});

Drizzle Setup

// auth.ts
import { betterAuth } from "better-auth";
import { drizzleAdapter } from "better-auth/adapters/drizzle";
import { db } from "./database";

export const auth = betterAuth({
  database: drizzleAdapter(db, {
    provider: "pg", // or "mysql", "sqlite"
  }),
  // ... other config
});

SQLite Setup

// auth.ts
import { betterAuth } from "better-auth";
import Database from "better-sqlite3";

export const auth = betterAuth({
  database: new Database("./better-auth.db"),
  // ... other config
});

FEATURES

📊 Dashboard

  • Overview statistics - User counts, organization counts, session data

👥 User Management

  • View all users - Paginated list with search and filtering
  • Create users - Add new users with email/password
  • Edit users - Update user information, email verification status
  • Delete users - Remove users from the system
  • Bulk operations - Seed multiple test users
  • User details - View user profiles, and accounts

🏢 Organization Management

  • View organizations - List all organizations with pagination
  • Create organizations - Add new organizations with custom slugs
  • Edit organizations - Update organization details
  • Delete organizations - Remove organizations
  • Team management - Create and manage teams within organizations
  • Member management - Add/remove members from teams
  • Bulk seeding - Generate test organizations and teams

⚙️ Settings & Configuration

  • Plugin status - Check which Better Auth plugins are enabled
  • Database configuration - View current database adapter and settings
  • Social providers - Configure OAuth providers (GitHub, Google, etc.)
  • Email settings - Configure email verification and password reset

COMMAND LINE OPTIONS

Start Studio

pnpx better-auth-studio start [options]

Options:

  • --port <number> - Specify port (default: 3000)
  • --host <string> - Specify host (default: localhost)
  • --no-open - Don't automatically open browser
  • --config <path> - Path to auth config file (default: auto-detect)

Examples:

Start on custom port:

pnpx better-auth-studio start --port 3001

Start without opening browser:

pnpx better-auth-studio start --no-open

Use custom config file:

pnpx better-auth-studio start --config ./custom-auth.ts

Other Commands

Check version:

pnpx better-auth-studio --version

Show help:

pnpx better-auth-studio --help

DEVELOPMENT

Running from Source

Clone the repository:

git clone https://github.com/better-auth/better-auth-studio.git
cd better-auth-studio

Install dependencies:

pnpm install

Build the project:

pnpm run build

Start development server:

pnpm run dev

Contributing

  1. 1.Fork the repository
  2. 2.Create a feature branch
  3. 3.Make your changes
  4. 4.Add tests if applicable
  5. 5.Submit a pull request

SUPPORT

If you encounter any issues or have questions:

  • Search existing issues on GitHub
  • Create a new issue with detailed information