To add an admin user to a WordPress website via phpMyAdmin, you would typically perform the following steps:
- Access your hosting control panel and open phpMyAdmin.
- Select the database your WordPress site uses from the list on the left.
- Once the database is open, search for the table
wp_users(the prefixwp_It might be different if you changed it during installation). - Click the tab
Einfügen, to the tablewp_usersto add a new line. - Please fill in the required fields:
user_login: The username you want to use to log in.user_passThe password for the user. This must be converted into an MD5 hash, which phpMyAdmin can do for you (select "MD5" in the dropdown menu on the left).user_nicename: A URL-friendly version of the username.user_emailThe user's email address.user_status: Put this on0.display_name: The name that will be displayed to this user on your website.
- Click the button
OK, to add the new user data to the tablewp_usersinsert. - Next, you need to grant this user administrator rights. To do this, navigate to the table.
wp_usermetaand click on the tabEinfügen. - You need to add two lines to define the skills and user level of the new admin user.
- In the first line:
user_id: The ID of the user you are currently viewing in the tablewp_usershave created.meta_key: Shouldwp_capabilitiesbe (the prefixwp_(It could be different again).meta_value: Adda:1:{s:13:"administrator";s:1:"1";}one, to grant administrator rights.
- In the second line:
user_id: The same user ID as before.meta_keyThis shouldwp_user_level.meta_value: Put this on10, in order to grant the highest level of access.
- In the first line:
- Click the button
OK, to insert these values.
Once you've done this, you should be able to log in to your WordPress site with the new admin user account. Always make sure you use a strong password for each admin account to ensure the security of your website.
Please note that directly editing the database can be risky; a mistake could potentially damage your website. Always back up your database before making any changes.








Be the first to leave a comment!