How Do Hackers Mine WordPress for Admin Email Addresses?
Attackers rarely hack for it: author slugs, avatar hashes, login form replies, plugin bugs and email logs give it away. Tested fixes for WordPress 7.1.

Hackers rarely break into WordPress to get an admin email address. They collect it from places the site already shows: an author URL built from an email login, the Gravatar hash in an avatar link, a contact page, a plugin bug that returns user records, a leaked backup or email log, and the login and lost-password forms, which tell anyone whether a guessed address has an account. Once they have the address, they use it for password-reset floods, password guessing (WordPress accepts an email address in place of the username) and phishing aimed at the person who runs the site.
This guide walks through each of those routes, shows what current WordPress core does and does not expose, and gives you tested code to close the gaps. We checked every core behaviour on WordPress 7.1.4 with PHP 8.5 on 18 November 2026, ran the snippets on a test install, and confirmed each plugin vulnerability on CVE.org the same day.
What counts as the “admin email” in WordPress?
There are two different addresses, and attackers care about both.
- The site’s Administration Email Address. It lives under Settings, General and in the
admin_emailoption. WordPress sends site notices there: new user registrations, core update results, recovery mode links. It is not a login. - The email on each administrator account. This is the address on the user profile. It can log in, because WordPress has accepted an email address in place of a username since version 4.5. Password reset links for that account go there too.
On many small sites both are the owner’s personal address, which is the worst case: one leak gives an attacker the login name, the reset channel and a phishing target at once. With WP-CLI you can see both in a few seconds:
# Checked on 18 November 2026 (WP-CLI, WordPress 7.1.4)
wp option get admin_email
wp user list --role=administrator --fields=ID,user_login,user_email,user_nicenameKeep that output handy. The rest of this guide is about which parts of it the outside world can already see.
Can hackers see the admin email through the REST API?
Not in WordPress core. The users endpoint at /wp-json/wp/v2/users returns each published author’s ID, display name, website, bio, author link, slug and avatar URLs to logged-out visitors. The email field is only returned in the edit context, which needs the edit_user capability, as the REST API users reference shows.
Search is locked down too. When someone without the list_users capability searches users, core limits the columns it searches:
// wp-includes/rest-api/endpoints/class-wp-rest-users-controller.php (WordPress 7.1.4)
if ( ! current_user_can( 'list_users' ) ) {
$prepared_args['search_columns'] = array( 'ID', 'user_login', 'user_nicename', 'display_name' );
}So ?search=you@example.com does not match on the email column for a guest. We confirmed it: a guest search for the admin’s email returned an empty list.
There are two catches in the very same response, and both come up below. The slug field can contain your email if your username is an email address. The avatar_urls field contains a hash of your email. The username side of this endpoint, plus the ?author= redirect, sitemaps and oEmbed, is covered in our guide to every way WordPress hands out usernames, so we will not repeat it here.
What happens when the WordPress username is an email address?
The email ends up in a public URL. WordPress builds each user’s user_nicename, the slug used in author archive links and in the REST slug field, from the login name. If the login is jane.doe@example.com, the slug becomes jane-doeexample-com. That is the email with the @ removed and the dots turned into hyphens, which anyone can reverse in their head.
We created exactly that user on our test site and published one post. The guest REST response and the author archive link both carried jane-doeexample-com. Changing the nicename fixed both at once:
# Checked on 18 November 2026. Find accounts whose login is an email address.
wp user list --fields=ID,user_login,user_nicename --format=csv | grep '@'
# Give that account a neutral slug (user ID 2 in this example).
wp user update 2 --user_nicename=jane-doeTwo things to know before you run it. The old author URL stops working, so add a redirect if that archive had links or traffic. And you cannot change the login name itself from the dashboard; WordPress does not allow it. The nicename change is enough to get the email out of public URLs. For new accounts, ask people to pick a username that is not their address.
How do Gravatar hashes leak email addresses?
Every avatar WordPress prints is a Gravatar URL with a hash of the user’s email in it. Since WordPress 6.8 that hash is SHA-256, per the get_avatar_url() reference; before 6.8 it was MD5. The current core code is one line:
// wp-includes/link-template.php, get_avatar_data() (WordPress 7.1.4)
$email_hash = hash( 'sha256', strtolower( trim( $email ) ) );A hash cannot be reversed, but it does not need to be. The hash has no secret salt, so anyone holding a list of candidate addresses (a breach dump, a scraped list, or just firstname@yourdomain.com variations) can hash each one and compare. A match confirms the address. SHA-256 is slower to compute than MD5, but for checking a list of guesses that difference is small. Gravatar’s own hashing docs describe the same lowercase-and-trim recipe, so the input format is no secret either.
Where the hashes show up on a normal site:
- The REST users endpoint, in
avatar_urls, for every author. - Comment threads, where every commenter’s avatar carries a hash of the email they typed.
- Author boxes and theme headers that print the author avatar.
If you do not use avatars, switch them off under Settings, Discussion by unticking Show Avatars. If you want avatars on the site but not in the API, this small must-use plugin removes avatar_urls from REST user responses for logged-out visitors. Drop it into wp-content/mu-plugins/:
<?php
/**
* Plugin Name: Hide REST Avatar Hashes From Guests
* Description: Removes avatar_urls (which carry a hash of the user's email) from REST user responses for logged-out visitors.
*/
add_filter(
'rest_prepare_user',
function ( $response ) {
if ( is_user_logged_in() ) {
return $response;
}
$data = $response->get_data();
unset( $data['avatar_urls'] );
$response->set_data( $data );
return $response;
}
);We tested it on WordPress 7.1.4: before, the guest response for user 1 included avatar_urls; after, it did not, and logged-in requests were unchanged. Avatars printed in your theme still carry the hash, so the setting is the complete fix and the snippet is the partial one.
Do the WordPress login and lost password forms confirm an email exists?
Yes. Out of the box, both forms answer differently for an address that has an account and one that does not. These are the exact messages WordPress 7.1.4 returned on our test site:
What the visitor typed | Form | WordPress response |
|---|---|---|
An email with no account | Login | “Unknown email address. Check again or try your username.” |
A real account email, wrong password | Login | “Error: The password you entered for the email address you@example.com is incorrect.” |
An email or username with no account | Lost password | “Error: There is no account with that username or email address.” |
A real account email | Lost password | Redirect to the “check your email” screen and a reset email is sent |
That is an oracle. A script can feed it a list of guessed addresses and keep the ones that come back “incorrect password” instead of “unknown email”. Those messages do help real users who forget which address they signed up with, so this is a choice, not a bug fix.
This must-use plugin makes both forms answer the same way whether or not the account exists. Save it as wp-content/mu-plugins/quiet-login-errors.php:
<?php
/**
* Plugin Name: Quiet Login Errors
* Description: Login and lost-password forms answer the same way whether or not an account exists.
*/
// One message for every failed login, so the form no longer says which part was wrong.
add_filter(
'login_errors',
function () {
return '<strong>Error:</strong> Those login details did not work. Check them and try again.';
}
);
// Unknown username or email on the lost-password form: show the normal "check your email" screen.
add_filter(
'lostpassword_errors',
function ( $errors, $user_data ) {
if ( $user_data || $errors->get_error_code() === 'empty_username' ) {
return $errors;
}
if ( isset( $GLOBALS['pagenow'] ) && 'wp-login.php' === $GLOBALS['pagenow'] ) {
wp_safe_redirect( add_query_arg( 'checkemail', 'confirm', wp_login_url() ) );
exit;
}
return $errors;
},
10,
2
);What we saw after adding it on the test site, checked on 18 November 2026:
- Login with an unknown email and login with a real email plus a wrong password both showed “Those login details did not work.”
- The lost password form redirected an unknown email and an unknown username to
wp-login.php?checkemail=confirm, the same screen a real account gets. - An empty lost-password submission still shows an error, so a blank form is not mistaken for a sent email.
There is a trade-off. Your real users also lose the hint about which part they got wrong, and the login filter replaces every login-form message, including the empty-field ones. On a membership or store site with many customers, you may prefer to keep core’s messages and rely on rate limiting instead. Our guide to WordPress login security and brute-force protection covers limiting attempts per IP, which also slows down address checking.
If registration is open, the registration form is a third oracle: core says “This email address is already registered” for a taken address. Hiding that would confuse real people signing up, so the practical answer there is a CAPTCHA or rate limit on the form.
Which plugin bugs have leaked WordPress user email addresses?
Plenty, and they are the route attackers like best, because one request returns many addresses with no guessing. Three recent, published examples, each checked on CVE.org on 18 November 2026:
Plugin | Advisory | Affected | Fixed in | What leaked |
|---|---|---|---|---|
Dokan Pro | CVE-2025-12809 (Wordfence, published 16 Dec 2025, CVSS 5.3) | 4.1.3 and earlier | 4.1.4 | A REST endpoint with no capability check returned a user’s email, username, role and registration date for any user ID, to logged-out visitors |
WP Directory Kit | CVE-2025-13920 (Wordfence, published 24 Jan 2026, CVSS 5.3) | 1.4.9 and earlier | 1.5.0 | An AJAX action returned email addresses of users with the plugin’s own roles to logged-out visitors |
Post SMTP | CVE-2025-11833 (Wordfence, published 1 Nov 2025, CVSS 9.8) | 3.6.0 and earlier | 3.6.1 | Logged-out visitors could read the plugin’s email log, including password reset emails with working reset links |
The Post SMTP case goes beyond mining. An email log is a copy of every message your site sent, so a readable log hands over the addresses and the reset links that come with them. Wordfence reported active attacks against that bug in November 2025. If you run any plugin that logs outgoing mail, keep it updated, and turn the log off or prune it when you no longer need it. Our SendGrid SMTP setup guide covers sending mail without keeping a long log on the site.
The pattern is the same in all three: a plugin endpoint that returns user data without checking who is asking. Core cannot protect you from that. Updates can. An outside scanner that knows your plugin versions can tell you when one of them gets a new advisory; our team’s free WP Vanguard scan does that check without a plugin install. Its limit is the same as any outside scan: it sees what the public sees, so it will not spot a leak that needs a login to reach.
What other public places give the admin email away?
Most of the time the address is simply published. Check these in order of how often we find them:
- Contact pages, footers and author bios. A
mailto:link or a plain address in the page is the easiest target there is. Address scrapers read plain HTML, so anything printed there gets collected. Use a contact form, or at least a role address you are happy to see spammed. - Emails your site sends. Every notification shows a From and often a Reply-To address. If your form plugin or store sends from your personal admin address, every customer, and every spam bot that fills in your forms, gets a copy of it.
- Backups, exports and logs in web folders. A database dump contains every user’s email. So does a user export CSV. If a backup lands in
wp-content/uploadsand the folder is browsable, the file name is no longer a secret. Our guide on turning off directory indexing shows how to check and close that in a few minutes. - Domain registration records. Many registrars now redact contact details in public lookups, but not all of them do, and older records may have been archived by lookup sites. Check what a public lookup of your domain shows.
- Code repositories. A theme or plugin pushed to a public repository can carry the owner’s address in commit metadata or in a config file.
What do attackers do with a WordPress admin email address?
Three things, in rough order of how often site owners notice them.
Password reset floods
Anyone who knows an account’s email can submit the lost password form and make WordPress send a reset email. That alone does not give them access, because the link goes to your inbox. It does create noise, and sometimes it is the cover for the next step: a fake reset email of their own.
Password guessing with the email as the login
Since WordPress 4.5 the login form accepts an email address in place of the username. An attacker with your address and a password from an old breach of some other site can try that pair directly. Two-factor authentication on every administrator account is the fix that makes a correct password useless on its own.
Phishing aimed at the site owner
This is where a known admin address pays off most. In late 2023, WordPress administrators received emails posing as the WordPress security team about “CVE-2023-45124”, urging them to install a “patch” plugin that actually created a hidden administrator named wpsecuritypatch and dropped a backdoor, as BleepingComputer reported on 4 December 2023 from Wordfence and Patchstack research. The CVE number in the email was not a real WordPress flaw; on CVE.org that ID is a rejected record. WordPress.org’s alert from the same day is blunt: “The WordPress Security Team will never email you requesting that you install a plugin or theme on your site.”
If a strange administrator account ever appears after an email like that, our hidden admin account audit walks through finding and removing it.
How can I check what my site leaks right now?
Run these from any terminal against your own domain. Each takes a second. Checked on 18 November 2026.
SITE=https://example.com
# 1. Author slugs and avatar hashes visible to guests
curl -s "$SITE/wp-json/wp/v2/users" | grep -o '"slug":"[^"]*"'
curl -s "$SITE/wp-json/wp/v2/users" | grep -o 'avatar_urls' | wc -l
# 2. Email addresses printed in the home page and contact page HTML
curl -s "$SITE/" "$SITE/contact/" | grep -Eio '[a-z0-9._%+-]+@[a-z0-9.-]+\.[a-z]{2,}' | sort -u
# 3. Does the lost password form treat unknown addresses differently?
curl -s -o /dev/null -w '%{http_code} %{redirect_url}\n' \
-d 'user_login=no-such-user-12345@example.com' "$SITE/wp-login.php?action=lostpassword"How to read the results:
Check | Bad result | Fix in this guide |
|---|---|---|
Slugs | A slug that looks like an address, such as | Change the nicename with WP-CLI |
avatar_urls count | Any number above 0, if you care about hash matching | Show Avatars off, or the REST snippet |
Emails in HTML | Your personal or admin address appears | Contact form or a role address |
Lost password | 200 with an error page, not a 302 to | The quiet login errors mu-plugin |
Note that check 3 sends a real request to your own form. Run it against your site only.
How do I protect the WordPress admin email address?
Here is the order we use on client sites, cheapest and most effective first:
- Split the addresses. Set the Administration Email Address to a role mailbox such as
webmaster@that a team can read. Give each administrator account a private address that is never printed on the site and is not their username. - Turn on two-factor authentication for every administrator. A leaked email plus a reused password is then not enough.
- Fix email-shaped usernames with the WP-CLI nicename change above.
- Update plugins promptly, especially anything that stores user data, form entries or email logs. Those are the ones with user-email advisories.
- Decide on the login messages. Use the quiet errors mu-plugin, or keep core’s messages and add rate limiting.
- Handle avatars with the Show Avatars setting or the REST snippet.
- Keep backups and exports out of web folders and switch off directory listing.
- Treat “security team” emails as suspect. Real WordPress.org mail never asks you to install a plugin or send your password.
None of these hides the address forever. Addresses leak through breaches of other services you have no control over. The goal is that knowing your email gets an attacker nowhere, which is mostly the job of two-factor authentication and updates.
Common mistakes people report
These come up again and again on the WordPress.org forums and in incident reports. Each links to the source, with its date. Checked on 18 November 2026.
- Signing up with an email as the username. A blogger found their personal address in their own author URL, because the slug was built from the email login. Creating a new user fixed new posts, but old URLs kept the address. WordPress.org forum, last updated August 2016. The nicename change above fixes existing URLs too.
- Changing passwords to stop reset emails. Administrators on one blog kept getting reset emails they never requested, while editors and subscribers did not. Changing passwords did nothing, and the emails turned out to be scams rather than real WordPress messages. WordPress.org forum, September 2017.
- Ignoring unknown accounts behind reset notices. A site owner got about two dozen reset-related notices a day; a moderator traced them to a user account the owner did not recognise, on a site with registration switched off. Deleting unknown accounts was the advice. WordPress.org forum, June 2017.
- Following a “WordPress security” email. Administrators who installed the “patch” from the fake CVE-2023-45124 email got a hidden admin account and a backdoor. BleepingComputer, December 2023.
- Leaving an email log plugin unpatched. Sites still on Post SMTP 3.6.0 or older were attacked through the readable email log; Wordfence saw exploitation begin in early November 2025, right after the advisory went public. Wordfence, November 2025.
Frequently asked questions
Can someone hack my WordPress site with just the admin email?
Not on its own. The email is half of a login and the address a reset link goes to. They still need the password or access to your inbox. That is why a strong unique password and two-factor authentication matter far more than hiding the address.
Is the admin email shown anywhere in WordPress by default?
Core does not print the Administration Email Address on public pages. The leaks come from email-shaped usernames, avatar hashes, the login form messages, themes and plugins, and content you publish yourself.
Should I change my admin email if it has leaked?
Changing it helps if the address is getting heavy spam or targeted phishing. When you change the Administration Email Address, WordPress sends a confirmation link to the new address and only switches after you click it. Do not expect a change to stop attacks by itself; turn on two-factor authentication first.
Do security plugins hide the admin email?
Some hide usernames, block user enumeration or rename the login URL, which removes a few of the routes above. None of them can fix a vulnerable plugin’s endpoint or an address you published. Check the specific routes in this guide rather than trusting a single toggle.
Why do I get password reset emails I did not request?
Someone, usually a bot, typed your username or email into the lost password form. The reset link goes only to you, so nothing happens unless you click it. If the emails are frequent, add rate limiting to the form, and check that the messages really come from your site rather than a lookalike sender.
Plugins we build and run
We maintain these ourselves, which is why we can support them on your site.
- BuddyNextThe self-hosted community engine for WordPress
- BuddyXFree community theme, Pro when you outgrow it
- ReignPremium community theme. Add pieces, build anything
- JetonomyCommunity forum and Q&A for WordPress
- EventonomyEvents and RSVPs for WordPress communities
- LearnomyCourses and learning communities on WordPress
- ListoraDirectories and listings your members can browse
- SnipShareCode sharing built for developer communities
- WB Ad ManagerAd placements that turn traffic into revenue
- WP Career BoardA job board your community actually uses
- WP Sell ServicesSell services with offers, orders, and payouts
- MediaVersePhotos, video, and media albums for members
- WB GamificationPoints, badges, and rewards that keep members active
- Product RoadmapPublic roadmaps with voting your users trust


