Auth0 Home Blog Docs

Auth with google

login

#1

Hi :smiley: I am quite new in the service auth0. firebase auth was very easy to create a login with google, but with auth0 it’s costing me a lot of work they are too steps.

firebase auth just had to create credentials for app etc

example of code in an app with react:

// App.js
import firebase from ‘firebase’;

handleAuthGoogle() {
const provider = new firebase.auth.GoogleAuthProvider();

firebase.auth().signInWithRedirect(provider)

.then(result => console.log(${result.user.email} ha iniciado secion))
.catch(error => console.log(Error ${error.code}: ${error.message}));

}

you can do something similar in auth0 the quick start guides have not helped me much


Remove screen default of Auth0 sign in or login
#2

Hey there @MAPESO!

If you want to create a login form in your react app so that your user can login using Google connection, then following these two quick tutorials will get you going in a few minutes:

Have you tried it? Let me know if that helps!


#3

when I press the login button with google redirects me to this page that is not the result that I expect

the result that I hope is the following:

1.- press the login button with google
2.- open a google pop up or redirection
requesting the user to access your account


3.- the user accepts and accesses my application

I hope you can help me, thank you very much for answering :blush:


#4

I would like to know how I can remove this screen every time the user presses the login button
34

the right thing would be to open a google pop up asking for access to my account when I click on the login button. I am new with auth0 and I would like someone to explain to me how to eliminate that.

Thanks :slight_smile: :heart:


#6

@MAPESO the flow that you see - the user presses Login with Google and then a Google pop up/redirection happens - is the intended behavior. If you remove the username-password you will only see the Log in with Google button. You can customize the Lock Page, you wouldn’t be able to remove it.


#7

Hi @MAPESO

In addition to what Kim said getting back to what you mentioned comparing using Google Firebase and our Auth0 stack, those products and companies are totally different.They are for different purposes and there are advantages and disadvantages using either of those tools.

Since you’re using our service it will be a bit different than Google by adding an extra step, however using our stack you gain the authorization, rules, etc. that Firebase do not provide.