[SOLVED] Moralis firebase extention on next.js gives INTERNAL FirebaseError

I am trying to get authentication with Moralis and firebase to work on next.js. I have been following the tutorial here https://docs.moralis.io/authentication-api/integrations/firebase-nodejs#troubleshooting and here: https://moralis.io/web3-firebase-authentication-create-a-web3-sign-in-with-moralis/ to install the Moralis extension for firebase.

The extension seems to install fine, the functions are there, the MoralisAuth element is created, but once I run await signInWithMoralis(moralisAuth); I get “Unhandled Runtime Error, FirebaseError: INTERNAL”.

I have been troubleshooting on this for a week now and think I will need some help. I have tried to implement the solution for next.js bug in troubleshooting, but that didn’t help. Will appreciate any help. Thank you

Hi @Va55

Did you check the firebase console logs?
In case if the error is coming from extension you can check the firebase console for error details.

1 Like

wow John,

Thank you. That definitely was the clue that helped me to the solution. I had just put localhost for URI in the moralis-auth.env file, but that led to an invalid URL error. Replacing it with http://localhost:3000/ solved the issue!

Thank you!

1 Like