pre-1.0 Open source · MIT · Go

Authentication without authentication servers.

An open-source OAuth 2.1 and OpenID Connect identity provider. Deploy it to your AWS account. Pay for what you use. Manage nothing but your application.

  • Lambda
  • DynamoDB
  • KMS
  • CloudFront
  • WAF
  • SES
# clone, then ask Claude Code to deploy it
$ git clone https://github.com/litelogin/litelogin
$ cd litelogin
$ claude "Deploy LiteLogin to prod with my
    litelogin-prod AWS profile, using login.example.com"
# it confirms the account, gives you the NS records
# and shows every plan before applying it

# then create an org and an app
$ claude "Create an org called Acme with a client
    for https://app.acme.com/callback"
# you get an issuer URL, a client ID and a secret

A complete identity provider, built from serverless parts

LiteLogin isn't an auth API in front of someone else's identity service, and it isn't a conventional identity server squeezed into a container. Every request is handled by a Lambda function, and all state lives in two on-demand DynamoDB tables.

What you don't run

  • Kubernetes, containers or VMs
  • An identity server to patch and upgrade
  • A PostgreSQL cluster, backups and failover
  • Capacity planning for traffic spikes
  • Compute that bills while nobody signs in

What you still own

  • The AWS account, its IAM and its security
  • Deployments and upgrades, via OpenTofu or Terraform
  • Service quotas: Lambda concurrency, SES production access
  • Monitoring, with the dashboards and alarms provided
  • The AWS bill, which is worked out in the open

The architecture is the product

Most identity providers hide their infrastructure behind an abstraction. LiteLogin's is a handful of AWS services you can read, audit and reason about, all deployed into your account by one set of OpenTofu/Terraform modules.

LiteLogin architecture Browsers and apps reach CloudFront and WAF, which forward to the Auth Lambda. The Auth Lambda reads and writes the DynamoDB Sessions and Config tables, signs tokens with KMS and sends email with SES. Operators use the litelogin CLI to call the Admin Lambda over IAM SigV4, which writes the Config table. Config table changes stream to the Worker Lambda. EventBridge Scheduler triggers the Worker reconciler and the key-rotation Lambda, which rotates KMS signing keys. Clients Edge Compute Data and keys IAM · SigV4 stream rotate signing keys Browser or app any OIDC library Operator litelogin CLI EventBridge Scheduler CloudFront + WAF login hosts, custom domains Auth Lambda sign-in pages, OAuth, OIDC Admin Lambda IAM-authenticated API Worker Lambda revocation, custom hosts Rotate Lambda daily key rotation DynamoDB · Sessions sessions, codes, refresh tokens KMS keys never leave KMS SES verification, resets DynamoDB · Config orgs, pools, clients, hosts

Edge

CloudFront terminates TLS for every login host and custom domain. WAF rate-limits per IP and applies AWS managed rules. A secret origin header means the Lambda can't be called around the WAF.

Compute

The Auth Lambda serves every browser and OIDC endpoint. Administration is a separate Lambda behind IAM, so management is never reachable from a login host. Background work runs from DynamoDB Streams, SQS and EventBridge.

State and keys

Two on-demand DynamoDB tables, with every access pattern documented. Signing keys are created in KMS and never leave it. Besides requests, only key rotation and a reconciler ever run.

Feature-complete for sign-in

Standards-based, so any OpenID Connect library works: point it at the issuer and it discovers the rest through /.well-known/openid-configuration.

OAuth 2.1 and OpenID Connect

  • Authorization code flow, PKCE (S256) required by default
  • Refresh tokens rotated on every use, with reuse detection
  • Discovery, JWKS, /userinfo, RP-initiated logout
  • An issuer per login host

Sign-in pages

  • Registration, email verification and password reset
  • Passkeys (WebAuthn)
  • Account settings: change password or email, manage passkeys, sign out everywhere
  • Per-host theming

Multi-tenant by design

  • Orgs, user pools, clients and login hosts in one deployment
  • Single sign-on across the apps on a host
  • Default hosts like acme.login.example.com
  • Custom domains like login.acme.com, with managed certificates

Security

  • Signing keys that never leave KMS, rotated automatically
  • argon2id password hashing and account lockout
  • Immediate revocation of sessions and refresh tokens
  • Signed, reproducible Lambda packages

Operations

  • A CLI over an IAM-authenticated Admin API; every command takes -o json
  • OpenTofu/Terraform modules for the whole deployment
  • CloudWatch dashboards and alarms
  • One script to deploy, resume and upgrade, and a Claude Code skill that runs it for you

Built for SaaS builders

  • Give each of your customers their own users and login domain
  • Many apps per org, with per-client redirect URIs, scopes and token lifetimes
  • Shared infrastructure, isolated tenants

Where it fits

Your identity provider, in your AWS account, without the identity server.

Self-hosted identity serverLiteLoginManaged auth service
Runs inYour containers or VMsYour AWS account, on LambdaThe vendor's cloud
DatabaseUsually PostgreSQL you operateOn-demand DynamoDBTheirs
Idle compute costAlways-onNear zeroPer-user or per-tier pricing
Servers to patchYesNoNo
Source and dataYoursYours, MIT-licensedVendor's
PortabilityAny cloudAWS onlyVendor only

Costs follow requests

A small fixed monthly cost for WAF, KMS keys and monitoring, then a fraction of a cent per sign-in. Every number below is derived step by step, from measured DynamoDB units, KMS calls and Lambda duration, in Cost.md.

Monthly AWS cost, us-east-1 list prices, 10 refreshes per sign-in
Sign-ins a monthLeanFull
1,000$4.60$21.02
10,000$6.05$23.43
50,000$12.50$34.20
100,000—$47.66
1,000,000—$231.01

Lean up to ~65k sign-ins/month

Uses CloudFront's free flat-rate plan, which includes the distribution, WAF and DNS zone. Default login hosts only, lighter monitoring, and tables encrypted with DynamoDB's own key. Fixed cost about $4.44 a month.

Full any size

Custom login domains, edge caching for discovery and JWKS, stricter WAF rules on credential endpoints, tables encrypted with a KMS key of your own, X-Ray, a dashboard and 15 alarms. Fixed cost about $20.74 a month.

Prices checked 2026-11-12, before AWS's free tier and taxes. Past roughly 100,000 sign-ins a month, requests dominate the bill, and refreshes cost more than sign-ins.

Load-tested in the open

50 sign-ins and 200 token refreshes per second for five minutes, through CloudFront, on a real deployment. No errors, no skipped arrivals, and no KMS, DynamoDB or Lambda throttling. Method and results.

164msp99 password sign-in
(argon2id included)
114msp99 code-for-token
exchange
137msp99 refresh-token
rotation
19msp99 KMS signing,
server side

From an empty AWS account to a working sign-in

You need an AWS account used only for LiteLogin, a domain you can delegate to Route 53 (such as login.example.com), OpenTofu or Terraform, Go and the AWS CLI. The first deploy takes about 30 minutes, mostly waiting for the certificate and CloudFront.

  1. Deploy with Claude Code

    The easiest way to deploy is with Claude Code. The litelogin skill in the repository runs scripts/deploy.sh and brings you each decision: it shows the AWS account for you to confirm, gives you the NS records to add and checks the delegation, and summarizes every plan before applying exactly that plan. It names the AWS profile on every command, never falls back to the default one, and asks before anything destructive. When it's done, it runs litelogin status to check the deployment.

    git clone https://github.com/litelogin/litelogin && cd litelogin
    claude "Deploy LiteLogin to prod with my litelogin-prod AWS profile, using login.example.com"
  2. Create an org and an app

    Ask Claude Code for the org and its first app. It runs litelogin init and gives you an issuer URL, a client ID and a client secret.

    claude "Create an org called Acme with a client for https://app.acme.com/callback"
  3. Sign in

    Point any OpenID Connect library at the issuer: it finds the rest through discovery. To check the whole flow first, ask Claude Code. It runs litelogin client test, which opens your browser to sign in as your app would, then checks the code exchange, the ID token, /userinfo and a refresh.

    claude "Test a sign-in with the Acme Portal client"

Without Claude Code

deploy.sh and the litelogin CLI do the same steps from your terminal. If deploy.sh stops, run it again: it continues where it left off. The same command upgrades later.

AWS_PROFILE=<your profile> \
  scripts/deploy.sh prod --domain login.example.com
dist/litelogin init --org "Acme" \
  --client "Acme Portal" \
  --redirect-uri https://app.acme.com/callback

SelfHosting.md has every step in full, including doing it all by hand.

Or try it locally first

No AWS account needed. With Go and Docker, run LiteLogin against DynamoDB Local, then sign in with a password and a passkey. It takes about ten minutes.

make local-up local-tables
make run-auth      # terminal 1
make run-admin     # terminal 2

Local.md walks you through it.

Honest status

LiteLogin is pre-1.0: feature-complete for sign-in and load-tested, but expect breaking changes before 1.0. Here's what it doesn't do yet.

TOTP multi-factor authentication
Social sign-in (Google, GitHub, …)
Integration examples for Go, React and Next.js
A browser-based admin console
Published OIDC conformance results
An independent security review
A stable 1.0 release
SAML and SCIM enterprise provisioning

Want to help with any of these? CONTRIBUTING.md covers building, testing and the code layout.

Own your authentication. Skip the servers.

MIT-licensed, written in Go, deployed by OpenTofu or Terraform into your own AWS account.