Aayush Shukla
Aayush Shukla

Reputation: 15

How to check if the user entered a valid email address in an android app (Firebase)?

I'm creating a simple app for Android, and the authentication system is powered by Firebase.

When a user registers for a new account, the Firebase system only checks if the email is correctly formatted, and if it is, it creates a new user with that email address. But this causes the problem that the user can use an invalid email address in the email format, and Firebase does not validate it; it creates the user with that email address only even though it is invalid.

I have tried looking for many solutions online, but they are either not clear enough or are not the solution to this problem.

I'm looking for any standard process to verify an email address, or any library or dependency that does the work for me.

Upvotes: 0

Views: 527

Answers (1)

09fgjbHH90_
09fgjbHH90_

Reputation: 53

What exactly is meant by valid email address? do you mean a valid email service provider e.g gmail? If so you can use email link to verify emails. take a look at the firebase docs: https://firebase.google.com/docs/auth/android/email-link-auth

Upvotes: 2

Related Questions