← All fixes
Supabase auth: magic link / confirmation email redirects to localhost:3000 in production
#128Error
Supabase email confirmation link redirects to http://localhost:3000 instead of my site
Why it happens, and why this works
Supabase builds email links from the project's Site URL, which defaults to http://localhost:3000, and only redirects to URLs on the allow list.
Fix
In the Supabase dashboard > Authentication > URL Configuration, set Site URL to your production URL and add your domains (including preview URLs like https://*-yourteam.vercel.app/**) under Redirect URLs. In code pass emailRedirectTo: `${location.origin}/auth/callback` to signUp / signInWithOtp.Did it work?
No reports yet0 worked0 didn't
Tried it yourself?
Related fixes
Supabase AuthApiError: Invalid login credentials (signInWithPassword)
#154AuthApiError: Invalid login credentials
supabaseNo reports yet
Supabase update/delete returns no error but changes 0 rows (RLS blocks it silently)
#135supabase.from('table').update(...).eq('id', x) returns { error: null } but nothing changes; data is [] / count 0. Same for delete. No 42501 error is raised.
[email]: Permission denied (publickey)
#108[email]: Permission denied (publickey). fatal: Could not read from remote repository.