# With Quickback

Account UI is part of the Quickback Stack. The compiler builds it from source and bundles it into your Worker — there is no separate npm package or standalone deploy path.

## Compiler-Embedded

Add `account` to your `quickback.config.ts`:

```typescript title="quickback/quickback.config.ts"
export default {
  name: "my-app",
  template: "hono",
  account: {
    domain: "auth.example.com",
    name: "My App",
    companyName: "My Company",
    auth: {
      password: true,
      passkey: true,
      organizations: true,
      admin: true,
    },
  },
  // ...providers
};
```

Then compile and deploy:

```bash
quickback compile
npx wrangler deploy
```

### What Happens During Compilation

1. The compiler reads your `account` config and generates a `.env` file with the correct Vite environment variables (`VITE_QUICKBACK_URL`, `VITE_QUICKBACK_API_URL`, `VITE_ENABLE_PASSWORD`, branding, etc.)
2. The Account SPA source is copied to a temp directory, with disabled feature routes excluded
3. Pre-installed dependencies are symlinked (no `npm install` during build)
4. Vite builds the SPA with your settings baked in
5. Built assets (content-hashed filenames) are placed in the output directory

When CMS is also enabled, Account assets go to `src/apps/account/` and are served at `/account/`. When Account is the only SPA, assets go to `src/apps/` and are served at root.

### Custom Domains

With a custom domain, the Account SPA is served at root (`/`) on that domain:

```typescript
account: { domain: "auth.example.com" }
```

Add an admin domain to serve the admin panel on its own subdomain:

```typescript
account: {
  domain: "auth.example.com",
  adminDomain: "admin.example.com",
}
```

See [Multi-Domain Architecture](/compiler/config/domains) for details on hostname routing and cross-subdomain cookies.

### Auth Feature Flags

Feature flags control which pages are included in the build:

```typescript
auth: {
  password: true,       // Email/password login + inline password change
  emailOTP: false,      // Email OTP login flow
  passkey: true,        // WebAuthn passkey setup + management
  organizations: true,  // Dashboard, org management, invitations
  admin: true,          // Admin panel (user management)
}
```

Disabled features are excluded at compile time — their route files are removed before the Vite build. See [Configuration](/compiler/config) for all options.

## Next Steps

- [Configuration](/compiler/config) — CMS and Account config reference
- [Multi-Domain Architecture](/compiler/config/domains) — Custom domains and hostname routing
- [Environment Variables](/stack/account-ui/environment-variables) — Complete variable reference
- [Feature Flags](/stack/account-ui/features) — Enable and disable features
- [Auth Hooks](/stack/account-ui/hooks) — Run project code on signup, login, and session events
- [Customization](/stack/account-ui/customization) — Branding, labels, and theming
