Lovable·FixauthSupabaseintermediate

A Lovable Password Reset Link Goes to the Preview URL Instead of Production

Quick Answer

How do I fix A Lovable Password Reset Link Goes to the Preview URL Instead of Production?

Supabase auth URL configuration still points at preview, localhost, or a stale deployment URL. The generated auth UI is fine, but the real email redirect target is wrong. Start with "Audit Supabase auth URLs" before making broader code changes.

Fix signals

What this answers
Why a lovable password reset link goes to the preview url instead of production happens and what to change first.
Fastest move
Audit Supabase auth URLs
Use this page if
Reset password emails send users to a preview URL

Quick Fix Summary

Most likely causeSupabase auth URL configuration still points at preview, localhost, or a stale deployment URL. The generated auth UI is fine, but the real email redirect target is wrong.
Fastest fixAudit Supabase auth URLs
Use this page ifReset password emails send users to a preview URL

You're in the right place if...

  • !Reset password emails send users to a preview URL
  • !Password reset lands on localhost or an old domain
  • !Users can request reset emails but cannot finish the flow on production

Why this happens

Supabase auth URL configuration still points at preview, localhost, or a stale deployment URL. The generated auth UI is fine, but the real email redirect target is wrong.

Fix

1

Audit Supabase auth URLs

Open Supabase Authentication → URL Configuration and verify Site URL plus Redirect URLs match the live production domain exactly.

2

Add both production and fallback deploy URLs deliberately

If you still need preview testing, list those URLs explicitly instead of letting a preview environment become the accidental default.

Site URL: https://gptsters.com
Redirect URLs:
https://gptsters.com/**
https://your-project.vercel.app/**
3

Re-send the reset flow after updating settings

Old reset emails often carry the old redirect target. Generate a fresh reset link after fixing the config.

4

Patch the generated auth assumptions

Tell Lovable to stop relying on preview URL defaults.

Copy this prompt

Audit the password reset flow so all reset emails use the production domain by default. Keep preview URLs explicit, but never let them become the default reset destination for real users.

Prevent this next time

Preview URLs are for testing, not for auth truth. Set the production domain first and treat preview URLs as optional extras.

Frequently Asked Questions

Because the UI can be correct while the actual email redirect target is still configured to an old preview or localhost URL.

No. Generate a new reset email after fixing the configuration so the link uses the new redirect target.

Related fixes

Weekly Signals

Get the next fix, switch, or warning before it hits your build.

Join builders getting the community signals, fix patterns, and tool shifts that matter before they show up everywhere else.

Follow the signals →