Skip to content
Back

Login with google error, Error 400: redirect_uri_mismatch

  • 0
  • Auth
  • Web
  • Cloud
GomaPerrona
4 May, 2025, 04:10

Hi, when i login with Oauth2 , using createOAuth2Session( 'google', 'http://localhost:5173/', 'http://localhost:5173/' ); It gives me the error: You can't sign in to this app because it doesn't comply with Google's OAuth 2.0 policy.

If you're the app developer, register the redirect URI in the Google Cloud Console. Request details: redirect_uri=https://cloud.appwrite.io/v1/account/sessions/oauth2/callback/google/67e0efd00036b848eee4 flowName=GeneralOAuthFlow

I have made the correct settings in google with the client id for web application and i copied the URI from appwrite into the Authorized redirect URIs in google client id, with the client if and the client secret provided to appwrite google auth, so, i can't understand, why that error is popping

TL;DR
Developers facing 'Error 400: redirect_uri_mismatch' when trying to login with Google OAuth2. Ensure the redirect URI matches exactly in both the Google Cloud Console and Appwrite settings. Double-check client ID, secret, and authorized redirect URIs.
Reply

Reply to this thread by joining our Discord

Reply on Discord

Need support?

Join our Discord

Get community support by joining our Discord server.

Join Discord

Get premium support

Join Appwrite Pro and get email support from our team.

Learn more