
How to add hundreds of random WordPress users quickly
Sometimes you might need to add hundreds of wordpress users quickly to test out your wordpress site.
You can follow this method to do that:
- A general users account
For your domain, select any common email address say [email protected]. You will be using this same email address for all user accounts.
Can be anything – like say gmail address. Can also be a fake email. But it’s better to have an actual one.
- Install WordPress plugins
For this to work, you’ll need 2 wordpress plugins:
- Allow Multiple Accounts Plugin
This plugin will allow you to have multiple user accounts using same email
Plugin:
https://wordpress.org/plugins/allow-multiple-accounts/
Go to settings of this plugin and in the textbox: Multi-account email addresses
type your common email address: [email protected]
- Add Multiple Users Plugin
https://wordpress.org/plugins/add-multiple-users/
This plugin helps add multiple user accounts using a csv.
Now in WordPress left panel go to AMU — Plugin Settings
Uncheck “Send each new user a registration notification email?”
Section “CSV Column Ordering”:
In “Choose which method of column ordering you would like to use:” select “Predefined Below”
In “Predefined column order to use when importing CSV data (no spaces, separate with commas):”
Just add:
first_name,last_name,user_login,user_pass,user_email,role
Then do “Save Settings”
- Create random usernames
Get a random name generator php script here:
https://tricksty.com/tricks/php-script-generate-random-usernames
Modify the email address, password, total no of usernames to be generated etc in this script and run it.
You can generate hundreds or thousands of users as per your liking.
It will echo out a comma separated list of user account details like this:
Angelo,Slyton,aslyton75,password,[email protected],Editor Lloyd,Silbert,silbert39,password,[email protected],Editor Terisa,Hiciano,thiciano55,password,[email protected],Editor Milagro,Munerlyn,munerlyn66,password,[email protected],Editor
Copy this text.
- Add users to WordPress
Now in WordPress left panel go to: AMU — Import CSV data
Paste your generated csv text here and click on “Next Step”.
If you want to see all users in a form before inserting users then click on “Create User Information Form”
And then do “Add All Users”
But if you have too many users then this can take time. So instead you could just do:
“Skip form and add users”. You can always delete the users later on and re-add as per your need.
If the RandomNameGenerator php script ever gives a duplicate username, then AMU plugin will give error:
“Error: a user with this user_login already exists. This user was not registered.”
and not register the user.
Let me know in the comments below if you have any issues with this.
Or any other easier method you might have to do this 🙂
Peace.