Skip to content

The account with no address

For: an app developer who turns on a sign-in that needs no address, and who reads user.email.

What it does: this page explains the user whose email is null: where it comes from, its rules, and its limits.

From schema version 15, user.email is string | null. These flows make a user with no address:

No other flow writes a null. The unique key on the address stays, and two users with no address exist side by side on every adapter.

  • A null claims nothing, and nothing claims a null. The claim rule needs an address to compare.
  • Mail and notices skip a user with no address, and write no line for it.
  • The sign-up rule takes a null: signUp: "open" lets the user in. "invited" and false answer sign_up_closed, because an invitation names an address.
  • A session JWT, an ID token, and the userinfo answer omit email and email_verified for such a user.
  • Core never asserts that an address is present. A source test refuses a ! or an as string on an address in core.

A user has a proved handle when it holds a verified address, a phone that signs in under the phone config, or a passkey.

  • A user with no address and a proved handle can update the profile, set a username, add a phone, and make an API token.
  • It can register a passkey, and turn on TOTP and the passkey method of the second factor, when it is not anonymous.
  • It can add an address with POST /user/change-email and a fresh session. The proof of the new address then verifies it.
  • An anonymous user has no proved handle. Its session is its only key, and anonymous_refused holds every way in.
  • It gets no magic link, no email code, no reset mail, and no notice. Those need an address.
  • It cannot accept an invitation to an organization, because the invitation names an address.
  • A provider address never links it. A social sign-in finds it by the identity alone.
  • No mail can recover such an account. A person who loses the passkey or the phone loses the account. Ask the person to add a second passkey or an address.
  • Your own code that reads user.email must handle null. A TypeScript build with strict names each read.