# Forgot password by username says email is not valid

**URL:** <https://community.auth0.com/t/forgot-password-by-username-says-email-is-not-valid/183648>\
**Category:** Get Help\
**Tags:** new-universal-login-experience, login-experience\
**Created:** [March 10, 2025, 4:33pm UTC](https://community.auth0.com/t/forgot-password-by-username-says-email-is-not-valid/183648 "2025-03-10T16:33:45Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![autumn.evans](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/autumn.evans/32/72182_2.png) [@autumn.evans](https://community.auth0.com/u/autumn.evans)\
**Post date:** [March 10, 2025, 4:33pm UTC](https://community.auth0.com/t/forgot-password-by-username-says-email-is-not-valid/183648/1 "2025-03-10T16:33:45Z")

</div>

When trying to change a password using a username (which is not in an email format), it’s giving the error “Email is not valid.” It looks like the form is forcing the username to be in an email format:

How do I get around this?

---

<div class="post-metadata">

**Author:** ![gerald.czifra](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/gerald.czifra/32/75301_2.png) [@gerald.czifra](https://community.auth0.com/u/gerald.czifra)\
**Post date:** [March 10, 2025, 7:43pm UTC](https://community.auth0.com/t/forgot-password-by-username-says-email-is-not-valid/183648/3 "2025-03-10T19:43:52Z")

</div>

Hi @autumn.evans

Welcome to the Auth0 Community!

This error most likely occurs because the Database Connection is only accepting Email as an Attribute and does not accept Username. To overcome this, you will need to add Username as an attribute, please find the relevant steps in the following [documentation](https://auth0.com/docs/authenticate/database-connections/require-username).

Hope this helped!  
Gerald

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/auth0/original/3X/b/5/b560f266932fcce5d57f09a6595bd50518cae3f3.jpeg) [@system](https://community.auth0.com/u/system)\
**Post date:** [March 24, 2025, 7:44pm UTC](https://community.auth0.com/t/forgot-password-by-username-says-email-is-not-valid/183648/4 "2025-03-24T19:44:03Z")

</div>

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