Categories

Featured templates

WordPress. How to create new admin user via database

Margarett Ortiz February 2, 2015
Rating: 3.7/5. From 3 votes.
Please wait...

Hello! This tutorial will show you how to create new admin user via database.

WordPress. How to create new admin user via database

Note: You should always make a backup of your database before performing any MySQL edits.

In order to create new admin user via database, you should perform the following steps:

  1. Log into phpMyAdmin section on your hosting control panel and locate your WordPress database:

    WordPress._How_to_create_new_admin_user_via_database-1

  2. Click on wp_users table. We need to insert our new admin user’s information, so click on the Insert tab:

    WordPress._How_to_create_new_admin_user_via_database-2

    In the insert form, add the following:

    • ID – pick a number (in our example, we will use number 4).
    • user_login – insert the username you want to use to access the WordPress Dashboard.
    • user_pass – add a password for this username. Make sure to select MD5 in the functions menu (Refer to the screenshot below).
    • user_nicename – put a nickname or any “nice” name for this admin user.
    • user_email – add the email you want to associate with this account.
    • user_url – this would be the URL to your website.
    • user_registered – select the date/time for when this user is registered.
    • user_status – set this to 0.
    • display_name– put the name you like to display for this user on the site (it can be your user_nicename value as well).
    • Click on the Go Button:

    WordPress._How_to_create_new_admin_user_via_database-3

  3. Next, we have to add the values to wp_usermeta table. Click on the wp_usermeta table and then click on the Insert tab like in the previous step:

    WordPress._How_to_create_new_admin_user_via_database-4

    Then add the following information to the insert form:

    • unmeta_id – leave this blank (it will be auto-generated).
    • user_id – this will be the id of the user you created in the previous step. Remember we picked 4.
    • meta_key – this should be wp_capabilities.
    • meta_value – insert this: a:1:{s:13:”administrator”;s:1:”1″;}

    Insert another row with the following information:

    • unmeta_id – leave this blank (it will be auto-generated).
    • user_id – this will be the id of the user you created in the previous step. Remember we picked 4.
    • meta_key – this should be wp_user_level
    • meta_value – 10.
    • Then click on Go button:

    WordPress._How_to_create_new_admin_user_via_database-5

Now you will be able to log into your WordPress dashboard with the username and password you specified for this user.

Feel free to check the detailed video tutorial below:

WordPress. How to create new admin user via database

Best Responsive Wordpress Themes
This entry was posted in WordPress Tutorials and tagged admin, create, database, user, WordPress. Bookmark the permalink.

Submit a ticket

If you are still unable to find a sufficient tutorial regarding your issue please use the following link to submit a request to our technical support team. We'll provide you with our help and assistance within next 24 hours: Submit a ticket