How to get one time login for all the users?
drush

To get one-time login for the specific user, use this syntax:

drush uli &lt;user&gt;


Where &lt;user&gt; is either uid (e.g. 5), user name, or email address for the user.

To get one-time login URL for multiple users or all, you need to run drush in the loop, e.g.

for uid in $(drush sqlq "SELECT uid FROM users"); do drush uli $uid; done


Run drush help uli for help with syntax.

To correct your http://html part, add -l http://example.com parameter, or set your $base_url in your settings file.

Custom code

If you're interested in sending one-time login via e-mail using Drupal, you can use user_pass_reset_url() function in your custom code.


  Generates a unique URL for a user to login and reset their password.


Contrib module

Or use Login one time module (for D8, check this issue).


  Login one time provides the ability to email one-time login links to users.