WordPress Hacked Admin Users Added? How to Remove Them for Good
There’s an administrator on your site you never created. Maybe two. Before you click Delete, read this, because deleting the user first is exactly why most of them come back.
Rogue admins hide. You have to go looking.
You open Users and there it is. An administrator called help, or wp-admin2, or some random string with a Gmail address. You didn’t make it. Nobody on your team did.
That’s a WordPress hacked admin users added situation, and it’s one of the more serious kinds of hack. The extra admin isn’t the attack itself. It’s the attacker’s spare key. They made it so they can get back in whenever they want, even after you change your own password.
I’m Md Juwel Rana, and I clean up hacked WordPress sites as part of my work at Web Relife. Below is the order I actually follow, plus the places these accounts like to hide.
First: Don’t Delete the Rogue Admin Yet
Delete the code first, the user second. A lot of these backdoors check on every page load whether “their” admin still exists. If it doesn’t, they quietly create it again. Delete the account before removing the code and it’s back within minutes.
Sucuri documented exactly this in 2025. A fake plugin called “DebugMaster Pro” and a file named wp-user.php sitting in the site root both kept an admin named help alive. The plugin hid itself from the Plugins page and hid the user from the Users list. If the owner deleted the user, it came right back. (Sucuri’s write-up has the details.)
So with any WordPress hacked admin users added case, write down the username, email and registration date, and leave the account alone for now.
How Do Hackers Add Admin Users in WordPress?
Every WordPress hacked admin users added case starts with a way in. Knowing which one tells you what to close afterward. These are the ones I see most:
Some plugin bugs let a stranger register as an administrator. King Addons for Elementor (CVE-2025-8489) accepted a “role” value straight from the signup request. OttoKit (CVE-2025-27007) had a privilege escalation flaw that was exploited in the wild.
Fake plugins, a modified functions.php, a file in mu-plugins, or a PHP file pretending to be core. These create the admin and recreate it if you delete it.
Someone logs in as a real admin, then makes their own account so they keep access after you notice.
“Free” copies of paid plugins often ship with a backdoor already inside. You installed the hack yourself, without knowing.
One more sneaky trick: the attacker turns on Anyone can register and sets New User Default Role to Administrator in Settings → General. Now anyone who signs up becomes an admin. Check this right now. It takes ten seconds.
Found admin accounts you didn’t create? I can clean it up for you.
Get Help NowHow to Find Every Hidden Admin User
In a WordPress hacked admin users added case, the one you can see might not be the only one. Malware often hides a second admin from the Users screen while leaving the first one visible as a decoy.
Notice the count says 4 users, but only 3 rows show. That gap is a hidden account.
1. Compare the user counts
Look at the numbers at the top of Users. Then compare them with what a security, 2FA or activity-log plugin reports. Hiding code usually tweaks WordPress’s own count but forgets about other plugins. Numbers don’t match? Something’s hidden.
2. Check the database directly
Malware can filter the Users screen, but it can’t change what the database shows you in phpMyAdmin. Run this (change wp_ if your table prefix is different):
That lists every administrator, newest first. Anyone you don’t recognize goes on your list.
3. Or use WP-CLI
Handy, but treat the database as the final word. Smarter malware can mess with WP-CLI output too.
Red flags in an admin account
| Looks normal | Looks suspicious |
|---|---|
| Your own domain email, or a real team member | An @wordpress.org address (WordPress staff don’t get accounts on your site) |
| Created when you built the site | Created recently, often at an odd hour |
| Real name, has published posts | Names like help, admin1, wpadmin, support, or random letters |
| Shows up in the Users list | Exists in the database but not on the Users screen |
WordPress Hacked Admin Users Added: How to Remove Them in 7 Steps
Here’s the order that actually works for a WordPress hacked admin users added cleanup. Skipping ahead is how people end up doing this three times.
Take a full backup, even of the hacked site
Back up files and database before you touch anything. Yes, it’s infected. You still want it, in case you delete something you shouldn’t or need to look at the malware later. Download it, don’t just leave it on the server.
Find and remove the code that creates the admin
This is the step most WordPress hacked admin users added cleanups skip. Check these places:
- Your theme’s
functions.php, including the parent theme. Look forwp_insert_user,wp_create_user,set_role('administrator')or long blocks of encoded text. wp-content/mu-plugins/. These load automatically and don’t appear in the normal plugin list. Many sites don’t have this folder at all, so anything in it deserves a look.wp-content/plugins/. Any folder you don’t recognize, especially ones with recent dates.- The site root. Files like
wp-user.phpthat sound like core files but aren’t. Compare against a fresh WordPress download. wp-content/uploads/. There should be no.phpfiles in there. If there are, they’re almost certainly malicious.
A scanner like Wordfence helps here, but scanners miss custom code. Look yourself too.
Check the user is now visible
Reload Users. If a hidden admin suddenly shows up, good. You removed the code that was hiding it. If your SQL query still shows an admin that the Users screen doesn’t, there’s more code left. Go back to step 2.
Now delete the rogue admin users
Delete each one from Users. When WordPress asks what to do with their content, attribute it to your own account, then review those posts. Attackers sometimes publish spam pages under these accounts.
If the dashboard won’t let you, remove them in phpMyAdmin:
Change every password and reset the salts
- All WordPress admin passwords, not just yours.
- Hosting, cPanel, FTP/SFTP and the database password (then update it in
wp-config.php). - New security keys from the official WordPress salt generator, pasted into
wp-config.php. This logs everyone out, including the attacker.
Close the hole they used
Update WordPress core, every plugin and every theme. Delete anything you don’t use. Delete anything nulled, no exceptions. If one of your plugins had a known admin-creation bug, check its changelog and make sure you’re on the fixed version.
Fix the settings and watch for 2 weeks
Settings → General: turn off Anyone can register unless you need it, and set New User Default Role to Subscriber. Then install an activity log and check it every few days. If a new admin shows up again, you’ll know quickly and you’ll see exactly when.
Why Do the Admin Users Keep Coming Back?
If your WordPress hacked admin users added problem returns after you followed the steps, one of these is usually the reason:
- A second backdoor. Often a small PHP file in
uploadswhose only job is to rewrite the main one. - A cron job. Either a WordPress scheduled event or a server cron in cPanel that reruns the malware. Check both.
- Another admin you missed. The attacker logs back in with it and recreates everything.
- The original hole is still open. An old plugin, a reused password, another site on the same hosting account that’s also infected.
That last one catches a lot of people. If you have five sites on one cPanel account and only clean one, the others will reinfect it.
How to Stop Hackers Adding Admin Users Again
Once the WordPress hacked admin users added mess is cleaned up, make it hard to happen twice:
- Turn on two-factor login for every admin.
- Keep only the admins you really need. Editors don’t need to be administrators.
- Put a firewall in front of the site (Wordfence, Cloudflare, or your host’s WAF).
- Keep automatic backups stored off the server, so a clean restore point always exists.
- Stop using nulled plugins. I know they’re tempting. They’re also how a lot of these hacks start.
/lander page instead, that’s usually a DNS problem, not a hack. I explain the difference in WordPress redirecting to lander.Want Me to Clean It Up?
WordPress hacked admin users added cleanups are fiddly work. If you’d rather not dig through PHP files and database tables, send me the site. I’ll find every rogue admin, remove the code behind them, and close the hole they came through.
- Find hidden admin accounts the dashboard doesn’t show
- Remove backdoors in themes, plugins, mu-plugins and uploads
- Reset passwords, salts and database credentials
- Update or replace the vulnerable plugin
- Lock down registration, roles and logins