Returns null when loading the login

Hello I have a login screen with firebase and when it loads it returns null and I can’t figure out where the error is if someone can help me I appreciate it.

Thank you.


Could you show your blocks and What you’ve tried,
This Will help us find the issue.

1 Like

here are the blocks

1 Like

These blocks has nothing to do with Firebase.

You need first make sure you supplied the Firebase API key and the Database URL in the project settings page and then use the Sign In block to login / Sign Up using Firebase.

I already checked it is well configured
this is the login block

Check if your Firebase rules allow read/write access.

Also do a simple test to see if you can assign a label’s text to cloud variable users/userid after logging in. Do you see a value there?

If everything is correct

If the issue is with storing the email and then retrieving it when the user opens the app again, then this topic might solve your problem:

what error are you recieving?


It may be that the error is in firebase but where

1 Like

You’re not giving enough information to help you.

Have you tried what @tatiang suggested?
What was the output?
Can you share the code you used to try the suggestion?

You can test your Firebase rules by following these instructions:

If your Firebase rules are wrong, you won’t be able to access Firebase data from Thunkable now matter what you try.

1 Like

I already checked the rules and everything is correct, authentication everything
Sin título 1

the problem is in this block when I remove the email_input text to value the null is removed but the email is not saved in the label

1 Like

I will reiterate what I said earlier

This has nothing to do with Firebase. This is a Local Storage block that only saves information in the device and reads the information from device storage. This block does not read or store anything in Firebase.

You are getting null because there is nothing stored locally under the key you are specifying.

1 Like

How can I solve it

1 Like

You need to save (store) something first under the key. Only then you can read the same key and retrieve the value stored under it and assign it to the variable or a label.

You cannot retrieve data from an empty key.

1 Like

Ok I know thank you very much

1 Like

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