Overview
Thestart command launches the Better Auth Studio development server, providing a web-based interface for managing your Better Auth application.
Usage
Parameters
Port number to run the studio server on.Examples:
Host address to bind the studio server to.Examples:
Path to the auth configuration file. Can be relative or absolute.When not specified, the CLI automatically searches for config files in common locations:
auth.tssrc/auth.tslib/auth.ts- And other standard locations (up to 10 directories deep)
Path to MaxMind GeoLite2 database file (.mmdb) for IP geolocation features.Used to enhance session and event tracking with location data.Examples:
Enable watch mode to automatically reload the server when your auth config file changes.When enabled:
- Monitors the auth configuration file for changes
- Automatically restarts the server with the new configuration
- Updates the browser UI via WebSocket (no manual refresh needed)
- Perfect for development when iterating on your auth configuration
If the auth config file cannot be located, watch mode will be automatically disabled with a warning message.
Prevent the browser from automatically opening when the server starts.By default, the CLI opens your default browser to the studio URL. Use this flag to disable that behavior.Examples:
Examples
Basic Usage
Start the studio with default settings:Custom Port
Run on a different port:Development with Watch Mode
Enable auto-reload on config changes:Custom Configuration Path
Specify a non-standard auth config location:Production-like Environment
Bind to all interfaces without opening browser:Full Example with All Options
Combine multiple options for a complete development setup:Exit Codes
| Code | Description |
|---|---|
0 | Server stopped gracefully (Ctrl+C) |
1 | Failed to start server (auth config not found, port in use, etc.) |
Error Conditions
Auth Config Not Found
If the CLI cannot locate your auth configuration file:--config flag to specify the path explicitly.
Port Already in Use
If the specified port is already occupied:--port flag or stop the process using that port.
Watch Mode Without Config Path
If watch mode is enabled but config file cannot be located:Related Commands
better-auth-studio init- Initialize studio for self-hostingbetter-auth-studio --version- Show CLI versionbetter-auth-studio --help- Display help information
Notes
The start command is designed for local development. For production deployments, see the Self-Hosting Guide.