Last Updated on March 9, 2021 by Obaro Alidou K.
WordPress is the most targeted CMS by hackers. Why? Because it is the most used to start blogs, build website, or e-Commences. And, the default “admin” username makes it easier for hackers to attack your WordPress website. In this tutorial, I’m going to share with you 3 easy ways to change the default WordPress admin username to make it hard for hackers to break your site.
Why Should you Change the Default WordPress Admin Username?
By default, your WordPress login username is “admin”. This is predictable and makes your website vulnerable. The main reason for changing the default admin login username is a security concern. This puts an extra layer of protection since hackers will not just need to guess your password; they will also have to find your username.
The more difficult you can make it for malicious attacks to penetrate your website, the safer it will be. So changing your WordPress admin username is the first recommended way to keep your site out of hackers’ reach.
#3 Ways to Change WordPress Admin Username for Enhanced Security
There are actually 2 easy ways to change your admin username and one expert way which need some technical knowledge.
- Automatically Change WordPress Username With a Plugin
- Change WordPress Admin Username Manually (which I do prefer).
- Edit phpMyAdmin in cPanel to Change Username
Change WordPress Username Automatically Using a Plugins
This is the easiest and fastest way to change WordPress login username without overthinking or typing any line of code. All you need to do is to install a plugin and then let it do the job.
Yea, plugins are the key power of WordPress. They allow you to add functionalities to your site and changing WordPress admin username is no exception.
There are many plugins to help change the admin username in WordPress. But most of them have not been updated for over 2 years now. So I recommend the most recent which is Username Changer.
It is easy to set and doesn’t require any specific configuration. In fact, you just need to install the plugin and then change your username. Let me show you how it works.
Hover over Plugins and click Add New.
Search for “Username Changer” and install and activate the plugin.
Once activated, go to Users and Your Profile.
You will notice a new link with the anchor text “Change Username” next to your admin username. Click that link.
Now enter your new admin username, click on Save Username and you are done!
Now your old username has been changed. It is that simple.
Change WordPress Admin Username Manually
This method is the most recommended and the one I generally use. It is the most effective and safest way to change your admin username in WordPress without any risk of breaking your entire website.
Here is the exact process to follow:
Login to Your WordPress Dashboard
The first step is to log in to your WordPress dashboard as usual. Go to yourdomainname.com/wp-admin to land on your WordPress login page.
Enter your current Admin username and password to gain access to your WordPress dashboard.
Add New User as Administrator to Your WordPress Website
Now that you are in your WordPress dashboard, hover the mouse over Users and click on Add New.
Fill in your new username, password, name, email, etc. and select “Administrator” as the role. Once you are done, click the “Add New User” button to save the new Administrator user.
Tip: choose an Admin username different from your own name to make it hard to guest.
Log Out of Your Website
Hover the mouse over “Howdy, Admin” on the top right and click “Log Out”
Log in With the New User Account
Once again, log in to your WordPress dashboard. But, this time, log in with your new Admin username and password you have just created.
Delete the old admin user
Go to Users >>> All Users from the left menu.
Now, delete your old admin account. Just hover over the username and click on Delete.
Attribute all the Content to the New Admin
After clicking on Delete, you’ll be directed to the confirmation page. To save all your previous articles, just select “Attribute all content to” and choose your new admin username from the drop-down menu. Then click the Confirm Deletion button and you are all set.
After the process, your old unsecured WordPress admin username will disappear as if it had never existed. The cooler part is that all the consent you created in the past now goes to your new admin account.
Change WordPress Admin Username in cPanel
This method is not recommended for non-techies. The process is a bit complex and requires particular attention. The two methods described above are good to perform the task if you are not familiar with file editing.
Find Your Site Database Name
Before making any change to your database, you first need to know its name. Therefore, you have to open the File Manager in your cPanel. Then select your website’s Root Document.
Don’t be surprised as I clicked a sub-domain as root document because “guide.giantblogger.com” is the website I’m using for the demonstration. So click on what is right for your website.
Next, select the wp-config.php file and click the Edit button at the top of the page.
After clicking the Edit button, you may see a warning message. Just click Edit again to continue.
On the following page, locate the line where there is the code DB_NAME. What follows the code is your database name.
Locate Your Database in phphMyAdmin
Now that you know your database’s name you can go ahead and start editing its tables.
Go to phpMyAdmin in cPanel and select your database (the one you have just found the name) in the left bar.
Edit the wpze_users Table
Once you click on the database name, all its tables will be listed. Locate the wpze_users table and click on it.
Next, find your admin username in the list and click on Edit.
Fill in the New Username and Save the Changes
Enter your new username in each of the fields where the old one is displayed.
Usually, you just need to edit the user_login field to change your username. In case you would like to display another name than your username on your site’s front end, then change the display_name field.
The user_nicename field is the slug that will appear in the URL of your author page. What you enter here should not include spaces. It’s usually the same as your login username, but in case your username doesn’t look nice or simple like “GetMyDogReady2020” you can choose a different name to appear as the slug.
Finally, save the changes by clicking on the Go button.
After entering the new username into the three different fields, you will need to save your changes.
At the bottom of the page, you’ll see two drop-down boxes. Set the first one to Save and the second to Go back to previous page, then click Go to save your changes and you are all set!
Changing the WordPress default admin username helps safeguard your website. The 3 ways discussed are all good to perform the task. However, as your username is crucial for your website, I suggest you avoid the plugin method because plugins sometimes might harm your website. I do recommend you the manual method. This is the most trustworthy way to change your username and it is easy as well.
Finally, using phpMyAdmin is not required unless you are technically skilled, a serious learner or you could break your website. Anyway, be careful if you decide to use this method.
Hope it helps.
Sharing is caring; share, pin, and tweet this post to help others. We are all here to share and help. Also, make sure you subscribe to my newsletter just below to get posts like this directly in your inbox.
Have a wonderful day!-