User Authentication

User Authentication

User Authentication

Tutorial

Seamless User Authentication with UI Now

UI Now provides two built-in methods to authenticate your users: Magic Links and Google OAuth. These options ensure a secure and user-friendly experience for your SaaS product.

Once you’ve completed one of the tutorials above, directing users to the sign-in or sign-up page is simple. Here’s how you can implement it:

javascriptCopy code// SigninButton.js
"use client";

import Link from "next/link";

const SigninButton = () => {
  return (
    <Link className="btn btn-primary" href="/signin">
      Login
    </Link>

To manage post-login redirection, UI Now uses the callbackUrl variable defined in the config.js file. This variable ensures users are seamlessly redirected to the appropriate location, such as a private page like /dashboard, after successfully signing in or signing up.

Key Benefits:

  1. Effortless Integration: The authentication setup is pre-configured for ease of use.

  2. Customizable Redirects: Fine-tune user flows by updating the callbackUrl to align with your app's structure.

  3. User-Friendly Experience: Magic Links and Google OAuth provide secure and intuitive login options, perfect for modern SaaS products.