Appearance
Authentication
Nuxt SaaS Kit leverages Supabase for authentication, providing multiple sign-in methods to suit your users' preferences. This guide covers how to implement and use email/password, Google OAuth, and magic link authentication.
Getting Started
To get started, head over to Supabase and create a new project
Ensure you set your environment variables with your supabase config
SUPABASE_URL="The URL of your Supabase project"
SUPABASE_KEY="The public (anon) key for your Supabase project"
Configuring Redirect URLs
In order to properly manage user authentication flows such as password resets, magic links, and invitations, you need to configure the Redirect URL in Supabase. This URL is where users will be redirected after specific authentication actions, like clicking a magic link in their email or resetting their password.
In your project, go to Authentication > URL Configuration. This is where you can specify the redirect URLs for various authentication actions.
- For local development, set your Redirect URL to:
http://localhost:3000
- For production, update the Redirect URL to the correct production URL. For example
https://your-production-app-url.com
.
Providers
Proceed to the individual provider to setup your preferred auth method