AddThisFeature

Email Verification

Confirm the user actually controls the address on the account.

moderate User Accounts

What it adds

A verification email with a single-use expiring link, a resend path, and defined behaviour for every way that link can be opened.

What your agent is told to do

5
  1. 1

    Issue single-use tokens with a stated expiry, stored hashed. A token you can read out of your own database is a token support can be tricked into using.

  2. 2

    Decide what unverified accounts may do and enforce it on the server. Hiding features in the UI while the endpoints stay open verifies nothing.

  3. 3

    When the user changes their email, verify the new address before it replaces the old one, and notify the old address that a change was requested.

  4. 4

    Rate-limit resends per address and per account, but keep a path forward when delivery genuinely fails — a hard lockout after three bounces turns into a support ticket.

  5. 5

    Never confirm or deny whether an address already belongs to an account in any response, including timing and error copy.

Edge cases it handles

6
  • Clicking an already-used link must show 'already verified', not an error.
  • Clicking a link while signed out, or while signed in as a different user, must be handled explicitly rather than verifying the wrong account.
  • Requesting a new link must invalidate the previous one, and the copy must say so — otherwise people click the older email.
  • Email clients and security scanners pre-fetch links; a GET that consumes the token will be burned before the user sees it.
  • An expired link must offer a one-click resend, not send the user back to the start.
  • Changing the email again before the first change is confirmed must not leave two pending addresses.

Definition of done

8
  • Verification tokens are single-use, expiring, and stored hashed.
  • Restrictions on unverified accounts are enforced server-side.
  • Already-verified, expired, and reused links each have their own clear state.
  • Email changes verify the new address before it takes effect and notify the old one.
  • Resends are rate-limited and always recoverable.
  • No response reveals whether an address is registered.
  • The feature matches the existing design system.
  • No existing functionality is broken.

Related features

How it works

  1. 1

    Copy the link

    Grab the Markdown instruction URL for this feature.

  2. 2

    Give it to your AI

    Paste it into Claude Code, Cursor, v0, Lovable — whatever you build with.

  3. 3

    It inspects, then implements

    Your agent reads your existing app first, then adds the feature to fit it.

Works with your stack

These instructions are written to adapt. They tell the agent to detect your framework, match your existing design system, and reuse what you already have — rather than assuming a particular stack.

Need it tighter than that? Customize the feature and tell it exactly what you're running.