Setting a random password on importing users

We’re importing a club membership list.

We’ve created random passwords for each member which will be SMS’d to them with the expectation they will change their password.

Say I have a password mozrT9M8Gp for a user we’re importing … how do I set the password_hash and salt such that if they decide to login without asking for a password reset it will work?

Is that easier than the passwordless first visit for new users invited via the usual method?

What’s the problem you’re trying to solve by doing this?

1 Like

Cool. I wasn’t aware of that.

I want to make it as seamless as possible for club members to be notified of community events. I think I have to make them active, approved with a password set in order to enable them to be able to respond via email.

As long as you’ve verified the email address somewhere else the risk is probably minimal, but I’ve found a lot of success using the existing invite/enrollment loop. Users typically respond to it very positively.


If you are creating the users with an import script, You can just send them a link to the reset password modal.

1 Like