This is a super simple Next.js Supabase auth setup. I followed the tutorial under:
Setting up Server-Side Auth for Next.js and
Build a User Management App with Next.js
It's a mix of both. 🥳
Next.js Version: 14.2.3
supabase-js Version: 2.43.1
supabase-ssr Version: 0.3.0
Please change the auth confirmation part in the email template as described (Step 6)
in the Setting up Server-Side Auth for Next.js.
Go to the Auth templates page in your dashboard. In the Confirm signup template,
change {{ .ConfirmationURL }} to
{{ .SiteURL }}/auth/confirm?token_hash={{ .TokenHash }}&type=signup.
First, install the dependencies:
npm install
# or
yarn install
# or
pnpm install
Then, run the development server:
npm run dev
# or
yarn dev
# or
pnpm dev
Open http://localhost:3000 with your browser to see the result.