# Zoek gebruikers-id op aan de hand van gebruikersnaam of e-mailadres

**URL:** <https://meta.discourse.org/t/lookup-user-id-from-username-or-email-address/198638>\
**Category:** Development\
**Created:** [30 juli 2021 om 01:08 UTC](https://meta.discourse.org/t/lookup-user-id-from-username-or-email-address/198638 "2021-07-30T01:08:40Z")\
**Posts on this page:** 1\
**Showing post:** 5

<div class="post-metadata">

**Author:** ![uckelman](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/uckelman/32/103854_2.png) [@uckelman](https://meta.discourse.org/u/uckelman)\
**Post date:** [1 september 2021 om 00:34 UTC](https://meta.discourse.org/t/lookup-user-id-from-username-or-email-address/198638/5 "2021-09-01T00:34:12Z")

</div>

What I was looking for turned out to be this:

```plaintext
User.find_by_username(username)&.id

```

---

_[View the full topic](https://meta.discourse.org/t/lookup-user-id-from-username-or-email-address/198638)._
