Skip to content
Lovelace

Production Hardening

What This Is#

A release checklist for production Sign in with Lovelace deployments.

Who This Is For#

Engineers and operators responsible for release readiness.

What You Will Finish With#

  • A verified configuration and verification pipeline.
  • Predictable fallback behavior.
  • Safer operational defaults.

Going live#

Your app works on localhost, 127.x.x.x, and [::1] redirect URIs from the moment you create it. A redirect URI anywhere else, such as https://app.example.com/api/auth/callback, needs an approved developer account, because an app on a public site can sign in people other than you. The device authorization grant (urn:ietf:params:oauth:grant-type:device_code) needs one too: it has no redirect URI, and anyone who enters the app's code signs in to it.

  1. Your developer account was requested when you created your first app (or when you selected Register as a developer). The Apps page shows whether it is waiting for review or approved.
  2. Until it is approved, creating an app with a production redirect URI, or adding one to an existing app, fails with developer_approval_required. The response lists the redirect URIs that need approval in non_loopback_redirect_uris and the grant types in grant_types_requiring_approval, and nothing changes.
  3. Once it is approved, open Apps, select Edit redirect URIs on your app, and add the production redirect URI. You can also create a separate production app. Set the same client ID (and secret, for a server app) in your host's environment.

A rejected or suspended developer account cannot create apps, including localhost ones; requests fail with developer_not_approved.

Configuration Checklist#

  1. Set NEXT_PUBLIC_LOVELACE_OAUTH_CLIENT_ID.
  2. Register exact production redirect URIs in client configuration, after your developer account is approved.
  3. Set explicit Accounts URL overrides only when needed.
  4. Use HTTPS in production environments.

Verification Checklist#

  1. Verify route validates issuer and audience.
  2. Verify route creates app session only on successful token validation.
  3. User-facing UI messages remain generic and actionable.
  4. Server logs include structured diagnostic context.

Browser Behavior Checklist#

  1. FedCM path works in supported Chromium browsers.
  2. Unsupported browsers redirect immediately.
  3. No polling loops in auth initiation path.