Skip to content
Back

[SOLVED} Google Auth (redirect url mismatch)

  • 0
  • Flutter
  • Android
  • Auth
  • Apple
SpencerSama
23 Oct, 2023, 14:18

Hi all, I have a problem with the Google Auth provider. I have followed the Appwrite guidelines but I get this error when I try to authenticate.

TL;DR
Developers had a redirect URL mismatch issue with Google Auth after self-hosting; it was working fine in Appwrite Cloud. The solution was not provided.
Aditya Oberai
23 Oct, 2023, 15:01

@SpencerSama can you show exactly what redirect URI is added to your Google Console?

Aditya Oberai
23 Oct, 2023, 15:06

Also, if you're self-hosting, please make sure that your hostname matches in your test environment and on the Google Developer Console

localhost and 127.0.0.1 can cause a mismatch too, even though they do point to the same application

SpencerSama
23 Oct, 2023, 16:28

They are the same

Aditya Oberai
23 Oct, 2023, 16:29

Can you share a screenshot once?

SpencerSama
23 Oct, 2023, 16:30

Sure, Appwrite or google cloud?

Aditya Oberai
23 Oct, 2023, 16:31

Both, if that's okay?

SpencerSama
23 Oct, 2023, 16:31

Sure

SpencerSama
23 Oct, 2023, 16:36

Voila

SpencerSama
23 Oct, 2023, 16:56

Problem solved. In fact, I had to add my http and https uri.

SpencerSama
23 Oct, 2023, 16:57

Thanks for your help 🙏

Aditya Oberai
23 Oct, 2023, 18:11

Ah perfect!

Aditya Oberai
23 Oct, 2023, 18:11

[SOLVED} Google Auth (redirect url mismatch)

Rabin Acharya
13 Feb, 2025, 05:59

I am getting this issue again

Rabin Acharya
13 Feb, 2025, 06:00

I am not sure why it happened, It was working fine when it was in appwrite cloud, I self hosted it and then it fails

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