Guide
Sign-up or login broken after publishing
Login worked in the preview. On the live site, users sign in and end up back on the login page, on a localhost address, or on an error. Or the confirmation link in the email opens the wrong site.
Why it happens
When someone signs in, your login service (usually Supabase) sends them back to your app. For safety, it only sends people to addresses on an approved list. Your preview address is on that list. Your published address often isn't, so the service falls back to its default, which is often localhost.
Confirm it
- After signing in, look at the address bar. If it says
localhost:3000or your preview domain, this is the cause. - Open the confirmation email a new user receives and check where the link points.
Fix it (Supabase)
- Open your Supabase project → Authentication → URL Configuration.
- Set Site URL to your live address, e.g.
https://myapp.com. - Under Redirect URLs, add your live address and, if you use more than one, each of them (with and without
www). - If you use Google sign-in, check the Google Cloud console lists the callback URL that Supabase shows you.
- Sign up with a fresh email on the live site and go through the whole flow once.
If it still fails
Some apps hard-code the preview address in the sign-in code. Ask your builder: "Find every place the code builds a redirect or callback URL and make it use the live site's address."
Sign-up is the one step every customer must pass. Paste your app's link at vibe-fixer.com: an AI agent tries it the way a new customer would and tells you how many problems it finds. Free, no account.
Still stuck?
Paste your app’s link for a free test — no account. Your AI agent goes through it like a first customer, shows you what breaks, then fixes it while you watch.