Error 400: redirect_uri_mismatch
- Google sign-in
- OAuth
What it means
Google only sends people back to addresses you listed in advance. The address your app asked for is not on that list, so Google refused to continue.
Why it happens
- The live site's callback address was never added in Google Cloud (only localhost was).
- A small difference: http vs https, www vs no www, a trailing slash, a different port.
- With Supabase Auth, Google must list Supabase's callback address, not your app's.
How to fix it
- Read the exact redirect_uri in the error details.
- Add that exact address to Authorized redirect URIs in Google Cloud Console.
- With Supabase, add https://<your-project>.supabase.co/auth/v1/callback there, and your site's address to Supabase's allowed redirect URLs.
Let your AI find the cause
Paste this into Claude Code, Cursor, Lovable or whichever AI built your app. It looks first and changes nothing until you have read the answer.
Google sign-in fails with 'Error 400: redirect_uri_mismatch' on my live site. Without changing anything yet, tell me which redirect address my app sends to Google, where that is configured in the code, and every place (Google Cloud, Supabase or my auth provider) that must list it.