Google OAuth doesn't work with Netlify

  • Netlify site name: rushil-markitdown
  • URL: https://rushil-markitdown.netlify.app/
    This is a markdown editor. I am saving the notes on firebase. Everything was fine till here.
    Then I decided to add Firebase Auth with Google sign-in.
    google pop up appears for a split second and then disappears.
    I get the invalid API key error in the console.
  • No build problems
  • Did you try Ask Netlify, our generative AI chatbot, before posting? It pulls info from Support Guides and recent solved forums posts.
    Yes
  • Now I know there are no errors in my code, because when I deployed the same repo from Github using Vercel, it works perfectly.
    I added the same environment variables in both Netlify and Vercel, but it doesn’t work.

While I don’t doubt it’s what was/is happening for you, it’s not what I saw when checking it for you just now.

The window to select a google account remained open.

I didn’t want to sign in so I closed it manually, and saw an appropriate error in the console:

image

Did you change something since posting?

I have applied changes to a few styles of divs, that too, right now.
So no, I didn’t apply any changes between posting this and your comment.
You’re right. It works well at the moment.
Thanks.