The Auth Platform
Native to Go. Built for Any Stack.
An open-source authentication solution that scales with you. Embed it as a library in your Go app, or run it as a standalone auth server for any language or framework.
Two Ways to Build
GoBetterAuth is designed to grow with your needs. Start simple as a library, or deploy as a centralised auth service for your entire platform.
- Native http.ServeMux compatibility
- Zero network latency (in-process)
- Full access to internal Go APIs
- Share database connections
- Compile into a single binary
- Centralised auth service
- Works with any language
- Live config updates
- Scales independently
- Docker & K8s ready
Flexible Configuration
Whether you're embedding as a library or running as a server, GoBetterAuth gives you full control over your authentication logic.
Library Configuration
Configure directly in Go using type-safe structs. Compiler verification ensures your config is always valid and consistent.
gobetterauth.New(config.NewConfig(...))Standalone Configuration
Configure your server with a simple TOML file, then continue with Dynamic Configuration with all the settings stored in your database and update them via the API in real-time.
Everything you need for Auth
Production-ready features that would take months to build yourself.
Email & Password
Secure authentication with Argon2 hashing, email verification, password reset, and change email flows.
Social OAuth
Connect with Google, GitHub, Discord, and more. Extensible provider system.
Multiple Databases
First-class support for PostgreSQL, MySQL, SQLite, and custom adapters with migration scripts.
Secondary Storage
Redis/Key-Value support for high-performance sessions and rate limiting.
Enhanced Security
Built-in CSRF protection, secure session management, and configurable rate limiting.
Minimal Dependencies
Standard library first design. Production-ready and framework-agnostic.
Webhooks
Trigger external workflows on user signup, login, and other key events with configurable webhooks.
Engineered for Performance
GoBetterAuth brings the power of Go to authentication. Experience unmatched speed, efficiency, and flexibility compared to other solutions.
Blazing Fast
Go's compiled nature means sub-millisecond response times for authentication flows, even under heavy load.
Memory Efficient
Run your entire auth service with just a few megabytes of RAM. Perfect for edge deployments and cost-saving.
Truly Flexible
Not just for Go apps. Use it standalone and connect it with any web frontend such as React, Vue, and more.
Extensible Plugin System
Easily extend authentication flows with our plugin system—add custom logic, integrations, or providers with minimal effort.
Microservices Ready
Built for distributed systems—deploy as a lightweight service in your microservices architecture. Easily configure separate instances with different auth flows or plugins.
Security First
Built with Go's strong type safety and robust security features to keep your users and data protected.
The Hooks System
Deeply customise behavior without forking. Inject logic at any stage of the authentication pipeline.
Endpoint Hooks
Modify requests and responses of the HTTP lifecycle.
Database Hooks
Intercept data before or after it hits the database.
Event Hooks
Execute workflows after key authentication actions.
Webhooks
Notify external services when auth events occur.
Event Bus
Pub/Sub architecture for async workflows
Custom Routes
Add new endpoints to the auth server
Core Logic
Extend the core authentication engine
Your Plugin
Implement the Plugin interface
Extensible Plugin System &
Event-Driven Architecture
GoBetterAuth isn't just a black box. It's a platform designed to be extended. Use the built-in Event Bus to trigger external systems, or write full plugins to add custom business logic and routes.
Plugin Interface
Implement a simple Go interface to inject custom services, repositories, and HTTP handlers into the main application.
Event Bus
Subscribe to system events like user.signed_up or user.logged_in and more to trigger emails, analytics, or webhooks.
Built Natively in Go
No complex frameworks or adapters needed. GoBetterAuth works with the standard library and integrates seamlessly into your existing Go stack.
Standard Library Compatible
Works directly with net/http and http.ServeMux.
Type-Safe Context
Retrieve user data and claims with full type safety.
Zero Dependencies
Minimal external dependencies to keep your binary small.
Extensible Hooks
Hook into any stage of the auth pipeline with Go functions.
Open Source & Community Driven
GoBetterAuth is seeking community collaboration and open-source contributions. Your involvement—sharing code, offering feedback, and support will help shape the future of authentication. Join us on this journey to build the most flexible, configurable, and more secure authentication solution for everyone.
Released under the Apache 2.0 License