Search⌘ K

Email Confirmation

Explore how to add an email confirmation feature in a full-stack app by verifying users through tokens. Learn to create a confirmation page with loader and alert components using Tailwind CSS, improving client-side authentication and user feedback.

An important step for any new user creating a new account is to verify their email through the confirmation link that they get in their mailbox.

Modify the backend

Initially, we redirect the user to the /verify/${confirmationToken} route to verify their account. Then, we modify the route to redirect the user to a front-end route so that we can display a nice message to indicate the status of confirmation. We change href=${process.env.API_URL}/verify/${confirmationToken} to href=http://localhost:4000/verify/${confirmationToken}.

...