Open Source Self-Hosted Keycloak Alternative

Auth Infrastructure
for Modern Apps

Self-hosted IAM with OAuth 2.0, OpenID Connect, SAML 2.0, MFA, WebAuthn, and SDKs for every platform. Deploy in 30 seconds. ~150MB RAM. Zero vendor lock-in.

OAuth 2.0 OIDC SAML 2.0 WebAuthn LDAP PKCE
48+
Modules
7
SDKs
100+
API Endpoints
~150MB
RAM Usage
30s
To Deploy
terminal
$ |
SDKs for
R
N
V
A
iOS
And
TS
Built with
N
R
P
TS
D
Pr
Re
K8
OAuth 2.0 OpenID Connect 1.0 SAML 2.0 PKCE (RFC 7636) TOTP (RFC 6238) WebAuthn / FIDO2 Device Auth (RFC 8628)
Features

Everything you need to secure your stack

Enterprise-grade IAM with 48+ modules, 7 SDKs, and zero vendor lock-in. Self-hosted, open-source, and ready in seconds.

Authentication & Security

OAuth 2.0 & OpenID Connect

Full OAuth 2.0 with PKCE, Authorization Code, Client Credentials, Device Authorization (RFC 8628), and Refresh Token grants. OIDC Core 1.0 with discovery, backchannel logout, and session management.

OAuth 2.0 OIDC PKCE Device Auth

SAML 2.0

Full Identity Provider and Service Provider modes. Issue SAML assertions, broker external SAML IdPs, metadata exchange, and assertion signing for enterprise SSO.

IdP Mode SP Mode Metadata SSO

Multi-Factor Authentication

TOTP-based MFA with Google Authenticator, Authy, and Microsoft Authenticator. Recovery codes, brute force protection with configurable lockout thresholds.

TOTP Recovery Codes Brute Force Protection

WebAuthn & Passwordless

FIDO2/WebAuthn support for passwordless authentication. Hardware security keys, biometric login with Face ID and fingerprint on supported devices.

FIDO2 Biometric Hardware Keys Passwordless

Step-Up Authentication

Progressive authentication requiring higher assurance (ACR levels) for sensitive operations. Configurable step-up duration and re-authentication flows.

ACR Levels Progressive Auth Re-Auth
Identity Management

Multi-Tenant Realms

Isolated tenants with independent users, clients, roles, groups, signing keys, themes, and configurations. Perfect for SaaS platforms needing tenant isolation.

Realms RBAC Groups Roles

B2B Organizations

Team and organization management for B2B multi-tenancy. Org-level roles, member invitations, and hierarchical structures for enterprise SaaS.

Organizations Teams B2B Invitations

Federation & Social Login

LDAP/Active Directory sync with on-demand or scheduled import. Broker external OIDC and SAML identity providers — Google, GitHub, Azure AD, or any compliant IdP.

LDAP Social Login IdP Brokering AD Sync

AI-Powered Risk Assessment

Intelligent risk scoring for login attempts with adaptive authentication. Detect anomalous behavior, flag suspicious patterns, and dynamically adjust security levels.

Risk Scoring Adaptive Auth Anomaly Detection
Developer Experience

7 Official SDKs

First-class SDKs for TypeScript, React, Next.js, Angular, Vue, iOS (Swift), and Android (Kotlin). Plus a CLI tool for server management. 5 lines to authenticate.

TypeScript React Next.js iOS Android

Plugin System

Extensible plugin architecture with custom event listeners, token enrichment, and authentication flow customization. Build exactly the auth logic you need.

Event Listeners Token Enrichment Custom Flows

Admin Console

Full-featured React dashboard for managing realms, users, clients, roles, groups, sessions, events, and more. Real-time data with a modern, responsive UI.

React Dashboard Real-Time Full CRUD
Operations & DevOps

Production Ready

Prometheus metrics, health checks, structured JSON logging (Pino), rate limiting (global + per-realm + per-user), and Helmet security headers. Ready for day one.

Prometheus Health Checks Rate Limiting Logging

Scalable Infrastructure

Fully stateless design for horizontal scaling. Docker and Kubernetes-ready with Helm charts. Optional Redis for session storage and caching. Multi-database support.

Docker Kubernetes Redis Horizontal Scaling

Webhooks & Audit Logs

Event-driven webhook system with AES-256-GCM encryption and retry logic. Comprehensive login event and admin action audit trail for compliance.

Webhooks Audit Trail Encrypted Compliance
SDKs

7 SDKs for every platform

First-class SDKs for web, mobile, and server. OAuth 2.0 + PKCE, automatic token refresh, and platform-native features like biometrics. Install and authenticate in 5 lines.

TypeScript · authme-sdk

Zero-dependency, ~5KB gzipped

React · @authme/react

Hooks: useAuth, useUser, ProtectedRoute

Next.js · @authme/nextjs

Middleware, Server Components, API routes

Angular · @authme/angular

AuthService, route guards, HTTP interceptor

Vue · @authme/vue

Composables, plugin, router guard

iOS · AuthmeSDK (SPM)

Keychain storage, Face ID / Touch ID

Android · authme-android (Gradle)

EncryptedPrefs, BiometricPrompt

npm install authme-sdk View all SDK docs
import { AuthmeClient } from 'authme-sdk';

const authme = new AuthmeClient({
  url: 'https://auth.example.com',
  realm: 'my-realm',
  clientId: 'my-app',
  redirectUri: 'http://localhost:5173/callback',
  refreshStrategy: 'rotation',
});

await authme.init();
if (!authme.isAuthenticated()) {
  await authme.login();
}

const user = authme.getUserInfo();
console.log(user.name, user.email);
Architecture

Built on proven technology

A modular, layered architecture with 48+ NestJS modules. Fully stateless for horizontal scaling.

Client Applications

Your apps connect via SDKs using OAuth 2.0 PKCE flows

React SPA Next.js SSR Vue / Angular iOS / Android CLI Tools APIs / M2M

Protocol Layer

Standards-compliant endpoints handling all auth protocols

OAuth 2.0 + PKCE OpenID Connect 1.0 SAML 2.0 (IdP & SP) Device Authorization Token Endpoint JWKS Discovery

Auth Engine

Core authentication logic with multi-factor and risk assessment

Login Flows MFA / TOTP WebAuthn Step-Up Auth Risk Scoring SSO Sessions Brute Force Consent

Identity Core

48+ NestJS modules managing identity resources and policies

Users Clients Realms Roles Groups Organizations Federation Identity Providers Custom Attributes Plugins

Operations Layer

Observability, events, and integration hooks

Webhooks (AES-256) Audit Events Prometheus Metrics Health Checks Rate Limiting Structured Logging

Data & Infrastructure

Persistent storage, caching, and external integrations

PostgreSQL 16 MySQL 8+ Redis / Sentinel LDAP / AD SMTP Email External IdPs
Backend
NestJS 11 · TypeScript 5.7 · Node 22
Database
PostgreSQL 16 · Prisma 7 ORM
Admin UI
React 19 · Vite 7 · Tailwind CSS 4
Security
Argon2id · RS256 JWT · Helmet
Auth Pages
Handlebars SSR · Per-Realm Theming
Observability
Pino JSON · Prometheus · Health
Deployment
Docker · Kubernetes · Helm Charts
Caching
Redis · Sentinel · In-Memory
Comparison

AuthMe vs. The Rest

See how AuthMe stacks up against the most popular identity solutions — self-hosted and cloud.

Feature comparison between AuthMe, Keycloak, Auth0, Clerk, and SuperTokens
Feature
Recommended
AuthMe
Keycloak Auth0 Clerk SuperTokens
Deployment
Self-Hosted
Open Source
Docker One-Liner
Kubernetes / Helm
Horizontal Scaling
Protocols
OAuth 2.0 + PKCE ~
OpenID Connect 1.0 ~
SAML 2.0
Device Authorization
Step-Up Authentication ~ ~
MFA & Passwordless
TOTP (Authenticator)
WebAuthn / FIDO2
Recovery Codes
Brute Force Protection
Identity
Multi-Tenant Realms
B2B Organizations ~ ~
RBAC (Roles & Groups)
LDAP / Active Directory
Social & Enterprise IdP
Custom Attributes ~
Developer Experience
Modern Admin Console
REST API (100+ endpoints)
Web SDKs (React/Vue/Angular) ~
Mobile SDKs (iOS/Android) ~
CLI Tool
Webhooks ~
Plugin / Extension System ~
Operations
Prometheus Metrics
Health Check Endpoints
Rate Limiting ~
Audit Logging
Realm Theming ~
Language TypeScript Java N/A (SaaS) N/A (SaaS) TypeScript
Memory ~150 MB ~1 GB+ N/A N/A ~200 MB
Setup Time 30 sec 5 min 2 min 2 min 5 min
SDK Count 7+ 2 10+ 5+ 4
Cost Free forever Free Freemium $$$ Freemium $$ Freemium
Full support
~ Partial
Not available
Getting Started

Deploy in 30 seconds

From zero to production-ready identity server in three simple steps.

01
01

Pull & Run

Pull the official image from Docker Hub and start AuthMe with one command.

terminal
docker run -d -p 3000:3000 islamawad/authme
02
02

Configure Your Realm

Open the Admin Console and create your first realm, client, and users.

terminal
curl -X POST http://localhost:3000/admin/realms \
  -H "Authorization: Bearer <api-key>" \
  -H "Content-Type: application/json" \
  -d '{"name": "my-app", "displayName": "My App"}'
03
03

Integrate Your App

Install the SDK and connect your application to AuthMe in minutes.

terminal
npm install authme-sdk
AuthMe is running at http://localhost:3000
Admin Console

Powerful Admin Dashboard

Full-featured React 19 admin console for managing realms, users, clients, roles, groups, sessions, identity providers, and audit logs — all in real time.

localhost:3000/console
AuthMe AuthMe Console production
A

Dashboard

Realm:
Total Users
2,847 +12%
Active Sessions
384 +5%
OAuth Clients
18
Login Events (24h)
4,291 -2%
Recent Users View all
AJ
Alice Johnson
alice@example.com
MFA Admin
BS
Bob Smith
bob@company.io
MFA User
CD
Carol Davis
carol@startup.dev
Manager
DW
Dave Wilson
dave@enterprise.com
MFA User
Login Events Audit log
LOGIN_SUCCESS
alice@example.com
192.168.1.42
2m ago
LOGIN_SUCCESS
bob@company.io
10.0.0.15
5m ago
LOGIN_FAILURE
unknown@test.com
203.0.113.5
12m ago
TOKEN_REFRESH
carol@startup.dev
172.16.0.8
15m ago
React 19 Real-time Data Full CRUD RBAC Management Audit Logs Session Control Realm Theming Responsive
Open Source

Built in the open.
Owned by you.

No vendor lock-in. No surprise pricing. Fork it, extend it, self-host it. Your identity infrastructure, your rules.

Support AuthMe

Help keep this project alive and growing

Buy me a Coffee
565+
Pull Requests Merged
689
Unit Tests
48+
Backend Modules
7
Official SDKs

How to Contribute

Report Issues

Found a bug? Open an issue on GitHub with reproduction steps.

Report Bug →

Submit PRs

Fix bugs, add features, or improve docs. All contributions welcome.

Contributing Guide →

Spread the Word

Star the repo, share on social media, write about your experience.

Star on GitHub →

For Developers

Get started with the SDK, explore the API, and contribute to the project.

Star on GitHub
Islamawad132/Authme
Install the SDK
npm i authme-sdk

For Teams

Deploy to your infrastructure and manage identity across all your applications.