<authui />

Theming

Design tokens, dark mode, radius, custom colours and string overrides.

Auth UI follows the Appwrite Console design system: the shadcn "new-york" zinc palette, a 10px radius scale, system UI font and the console's focus ring. Every colour is a CSS custom property on the component host, so you can restyle it from your own stylesheet without touching the shadow DOM.

Dark mode

branding.theme defaults to auto, which resolves in this order:

  1. html.dark or html.light class (what next-themes, shadcn and the Appwrite Console use)
  2. data-theme="dark" or "light" on <html>
  3. prefers-color-scheme

Set theme: "light" or "dark" to force a scheme. Components watch for class changes, so a theme toggle in your app switches Auth UI live.

Tokens

Override any token on the elements you want to change, or on :root to affect all of them:

authui-modal,
authui-sign-in,
authui-account,
authui-button,
authui-user-button {
  --authui-primary: #fd366e;
  --authui-primary-foreground: #ffffff;
  --authui-radius: 0.875rem;
  --authui-font: "Inter", system-ui, sans-serif;
}
TokenPurpose
--authui-background, --authui-foregroundDialog surface and default text
--authui-card, --authui-card-foregroundPanel surface
--authui-popover, --authui-popover-foregroundUser menu
--authui-primary, --authui-primary-foregroundPrimary buttons and switches
--authui-secondary, --authui-secondary-foregroundPasswordless buttons
--authui-muted, --authui-muted-foregroundAvatars, hints, descriptions
--authui-accent, --authui-accent-foregroundHover states
--authui-destructive, --authui-destructive-foregroundDanger actions
--authui-border, --authui-input, --authui-ringBorders, inputs, focus ring
--authui-brand, --authui-brand-foregroundThe brand button variant (Appwrite pink by default)
--authui-success-*, --authui-warning-*, --authui-error-*, --authui-info-*Alert and badge tints
--authui-radiusBase radius; sm, md, lg, xl derive from it
--authui-font, --authui-font-monoTypography
--authui-shadow-lgPanel and dialog shadow
--authui-overlayModal backdrop colour
--authui-zStacking order of the dialog and menus

The primary and radius branding options are shortcuts that set --authui-primary and --authui-radius for you.

Parts

The main panels expose part="panel" and the trigger button exposes part="button" for ::part() styling:

authui-sign-in::part(panel) {
  box-shadow: none;
}

Locale

Set locale (attribute locale) to a BCP-47 short tag. Auth UI ships English defaults plus packs for cs, de and fr. Unknown tags fall back to English. Missing keys inside a pack also fall back to English.

Merge order: English defaults ← locale pack ← strings override.

<authui-config locale="cs" endpoint="https://cloud.appwrite.io/v1" project="p"></authui-config>
AuthUI.init({
  // ...
  locale: "de",
  strings: { signIn: "Einloggen" }, // wins over the German pack for this key
});

Adding a pack

  1. Add packages/core/src/locales/<tag>.ts exporting a full or partial AuthUIStrings object (reuse placeholders like {provider}).
  2. Register it in packages/core/src/locales/index.ts (localePacks).
  3. Keep tone Concise and avoid em dashes.

supportedLocales, localePacks, resolveLocale, getLocalePack and mergeStrings are exported from @getauthui/core for tooling and tests.

Strings

Every visible string can be replaced through strings. Placeholders in braces are substituted at render time. Overrides apply after the locale pack.

AuthUI.init({
  // ...
  strings: {
    signIn: "Log in",
    signInTitle: "Log in to {name}",
    continueAsGuest: "Browse without an account",
    errorInvalidCredentials: "That email and password do not match.",
  },
});

The full list of keys with their defaults is exported as defaultStrings from @getauthui/core.

On this page