Getting user$ as null and is isAuthenticated$ as false after successful login

hey can anyone help me out .
im getting user object as null and isAuthenticated false after loggong in to application

im using auth0 angular sdk .

can anyone tell whats the issue here

Hi @akash.dhiwar_6,

Thanks for reaching out to the Auth0 Community!

Could you please check your tenant logs to see if there are any details about the login event and share that information with me?

In the meantime, it might be worth trying checking out the Auth0 Angular SDK Quickstarts: Login as a reference.


hey @rueben.tiow ! thanks for the reply.

I looked into tenant logs here it is

The LOGIN EVENTS are successful but yet user$ and isAuthenticated$ are null and false.

And I’m following angular sdk quickstart as shown in docs , but still not able to see user details.

And also I’m not getting token after successful login. What can be the issue ???

facing this kind of issue

you can refer this

hey @rueben.tiow need solution for this.

Hi @akash.dhiwar_6,

Thanks for following up.

I have just downloaded the Angular Quickstart sample app and was able to successfully log in and the user is correctly authenticated.

In your logs, I do see that the user logged in successfully, but I do not see any successful exchange authorization code for an access token (type: seacft) logs.

This seems to be consistent with your statement that you are not getting the token after a successful login.

Typically, calling the loginWithRedirect method should initiate the login process and authenticate the user. After a successful login, Auth0 automatically handles the retrieval of tokens, like the Access token, as part of the authentication callback processing.

If you need the access token immediately after a successful login, you can use the handleRedirectCallback method to process the auth response and obtain tokens.

Could you please give it a try and let me know your findings?


1 Like

hey @rueben.tiow thanks for the solution this worked for me. :innocent:

1 Like

Hi @akash.dhiwar_6,

I’m glad it worked!

Please let me know if there’s anything else I can do to help.


1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.