What Is the WordPress Email Not Sending Issue?
WordPress email not sending happens when WordPress can’t deliver emails from your site. You’ll notice:
- Contact form submissions aren’t received
- Password reset emails don’t arrive
- New user registration emails missing
- Administrator notification emails not showing up
- WooCommerce order confirmations not received
- Comments notification emails not working
The site itself works fine, but the email functionality is broken. You don’t get error messages—emails simply vanish without being delivered. This can cripple customer communication, password resets, and administrative notifications.
Unlike other WordPress errors that appear on screen, email problems are silent failures—you only notice when emails start piling up as undelivered.
Common Causes of Email Not Sending
- Mail function disabled on server — Hosting provider disabled PHP mail() for security
- SMTP not configured — WordPress using unreliable mail() instead of SMTP
- Incorrect SMTP credentials — Wrong username, password, or server address
- Firewall blocking SMTP port — Port 25, 465, or 587 blocked by server
- SPF/DKIM/DMARC records missing — Emails marked as spam due to authentication failures
- Plugin conflict — Email plugin interfering with WordPress core email functions
- Hosting email account issues — Email account deleted or quota exceeded
- Rate limiting — Too many emails sent too quickly, triggering server blocks
Solution 1: Install and Configure a Proper Email Plugin
This is the most reliable fix. WordPress’s default mail() function is unreliable. Use a dedicated email plugin.
Install WP Mail SMTP:
- Go to Plugins → Add New
- Search for “WP Mail SMTP”
- Click “Install Now” then “Activate”
- Go to Settings → WP Mail SMTP
- Choose your email service:
- Gmail (most common)
- SendGrid
- Mailgun
- Amazon SES
- Custom SMTP (your hosting provider’s mail server)
Configure with Gmail:
- Enable 2-factor authentication on your Gmail account
- Create an app password: https://support.google.com/accounts/answer/185833
- In WP Mail SMTP:
- Mailer: Gmail
- Client ID: (get from Google Cloud Console)
- Client Secret: (get from Google Cloud Console)
- Or use basic auth with your app password
- Send test email from the plugin settings
Configure with Mailgun (recommended for production):
- Sign up for Mailgun (free tier available)
- Get your API key from Mailgun dashboard
- In WP Mail SMTP:
- Mailer: Mailgun
- Domain: your Mailgun domain
- API Key: (from Mailgun)
- Add your domain to SPF/DKIM (Mailgun handles this)
- Send test email
This solution works 90% of the time because it removes reliance on unreliable mail() function.
Solution 2: Check If PHP Mail Function Is Disabled
If mail() is disabled, WordPress can’t send any emails.
Check if mail() is available:
Create a file named test-mail.php:
<?php
if (function_exists('mail')) {
echo "mail() function is ENABLED";
} else {
echo "mail() function is DISABLED";
}
?>
Visit yoursite.com/test-mail.php. If it says “DISABLED,” contact your hosting provider to enable it.
If mail() is enabled but still not sending:
Your hosting likely blocks it behind SMTP requirements. Use Solution 1 (email plugin) instead.
Delete test-mail.php after testing.
Solution 3: Configure SMTP Server Manually
If you don’t want a plugin, configure SMTP in wp-config.php directly.
Add to wp-config.php:
// Configure SMTP
define('WP_MAIL_FROM', '[email protected]');
define('WP_MAIL_FROM_NAME', 'Your Site Name');
// For Gmail
define('SMTP_HOST', 'smtp.gmail.com');
define('SMTP_PORT', 587);
define('SMTP_USER', '[email protected]');
define('SMTP_PASS', 'your-app-password'); // Use app password, not Gmail password
define('SMTP_SECURE', 'tls');
// For custom SMTP (ask your host for these values)
// define('SMTP_HOST', 'mail.yourhostingserver.com');
// define('SMTP_PORT', 587);
// define('SMTP_USER', 'your-email-account');
// define('SMTP_PASS', 'your-email-password');
// define('SMTP_SECURE', 'tls');
Then install a code-based SMTP plugin like “Easy WP SMTP” or “SMTP Mailer” to use these constants.
Solution 4: Check Email Plugin Configuration
If you already have an email plugin installed, verify it’s configured correctly.
-
Go to Settings and look for “Email,” “SMTP,” “Mail,” or “WP Mail SMTP”
-
Check that:
- From Email: Valid email address you control
- From Name: Your site name
- SMTP Host: Correct mail server address
- SMTP Port: Correct port (usually 587 or 465)
- Authentication: Enabled with correct username/password
- Encryption: TLS or SSL selected
-
Click “Send Test Email”
-
Check if you receive the test email
If test email succeeds but normal emails don’t send, the issue is with how WordPress calls the mail function, not the plugin.
Solution 5: Disable Plugins and Test
A plugin might be interfering with email functionality.
- Go to Plugins → Installed Plugins
- Deactivate all plugins except your email plugin
- Try sending a test email (contact form, password reset)
- If it works, reactivate plugins one by one to find the culprit
Common problematic plugins:
- Security plugins blocking email functionality
- Backup plugins interfering with mail functions
- Custom code snippet plugins with email-related code
Solution 6: Check SPF, DKIM, and DMARC Records
Emails get blocked as spam without proper authentication records. Configure these:
Add SPF record:
Log in to your domain registrar (GoDaddy, Namecheap, etc.):
- Go to DNS records
- Add a TXT record:
- Name:
@or your domain name - Value:
v=spf1 include:sendgrid.net ~all(for SendGrid) orv=spf1 include:mailgun.org ~all(for Mailgun) - Or ask your email service provider for SPF value
- Name:
- Save
Add DKIM record:
- Get DKIM public key from your email service (Mailgun, SendGrid, etc.)
- Add a TXT record:
- Name:
default._domainkey(or service-specific) - Value: (from your email service)
- Name:
- Save
Add DMARC record:
- Add a TXT record:
- Name:
_dmarc - Value:
v=DMARC1; p=none; rua=mailto:[email protected]
- Name:
- Save
These records tell email providers that you authorize the sending service to send emails on your behalf, preventing spam folder placement.
Solution 7: Check Email Provider Limits
Free email services (Gmail, etc.) have sending limits.
Gmail limits:
- 500 emails per day
- If you send more, emails queue for later
Solution: Switch to dedicated email service:
- SendGrid: 100 free emails/day, pay-as-you-go after
- Mailgun: Free tier includes 5,000 emails/month
- Amazon SES: Very affordable, per-email pricing
Use WP Mail SMTP to switch providers easily.
Solution 8: Check Contact Form Plugin Configuration
If only contact forms aren’t sending emails:
- Go to the contact form plugin settings (Contact Form 7, WPForms, Gravity Forms, etc.)
- Verify:
- Email notification enabled: Checkbox is checked
- Recipient email: Correct email address
- From email: Valid email from your domain
- Email subject: Not empty
- Send a test form submission
- Check spam folder if email arrives late
Solution 9: Check Hosting Provider Mail Server Status
Sometimes the hosting company’s mail server goes down.
- Contact hosting support
- Ask:
- “Is your mail server currently operational?”
- “What is the correct SMTP server address and port?”
- “Are there any rate limits on email sending?”
- Verify the SMTP host/port match what you configured
If their mail server is down, temporarily switch to external SMTP (Gmail, Mailgun) via WP Mail SMTP.
Solution 10: Monitor Email Logs
Check if emails are being sent but not delivered.
With WP Mail SMTP:
- Go to Settings → WP Mail SMTP → Logs
- Look for your test emails
- If they show “sent” but recipient doesn’t receive them, check:
- Spam/junk folder
- Email service bounce notifications
- SMTP server error messages in the log
Via hosting control panel:
- Log in to cPanel
- Go to “Email” or “Mail”
- Check “Emails” or “Mail Queue”
- Look for bounced or failed emails
- Failed emails show why they weren’t delivered
Solution 11: Test Email Function via Code
Add this to your theme’s functions.php temporarily:
function test_wordpress_email() {
$to = '[email protected]';
$subject = 'WordPress Email Test';
$message = 'This is a test email from WordPress.';
$headers = array('Content-Type: text/plain; charset=UTF-8');
$result = wp_mail($to, $subject, $message, $headers);
if ($result) {
error_log('Email sent successfully');
} else {
error_log('Email failed to send');
}
}
add_action('wp_footer', 'test_wordpress_email');
Visit your site homepage. Check /wp-content/debug.log for the result.
Remove this code after testing.
Solution 12: Enable Debug Logging
Capture detailed email sending information:
Add to wp-config.php:
define('WP_DEBUG', true);
define('WP_DEBUG_LOG', true);
define('WP_DEBUG_DISPLAY', false);
// Additional email debugging
define('PHPMAILER_PROVIDER', 'gmail'); // Use your provider
Send test emails and check /wp-content/debug.log for detailed error messages showing exactly why emails fail.
Prevention Tips
- Use a dedicated email plugin from day one (don’t rely on mail())
- Set up SPF/DKIM/DMARC records before launching
- Use reputable email services (Mailgun, SendGrid) instead of hosting mail server
- Monitor email deliverability regularly
- Create automated backups of important emails
- Set up email notifications for admin alerts
- Test email functionality after plugin updates
- Keep email plugin updated to latest version
From experience: A client once complained that customer emails weren’t being delivered. I discovered they were using their hosting company’s unreliable mail server without any email plugin. Switching to Mailgun via WP Mail SMTP immediately fixed the issue, and customer emails now arrive reliably within seconds. The hosting company’s mail server was being deprioritized because of poor SPF/DKIM configuration.
Related: If you’re having multiple WordPress issues alongside email problems, check How to Fix WordPress Server Error After Update or How to Fix WordPress Memory Exhausted Error for additional troubleshooting.
Conclusion
WordPress email not sending is usually caused by unreliable mail() function or missing SMTP configuration. Installing WP Mail SMTP and configuring it with a service like Mailgun solves this 95% of the time. If you want to diagnose the exact issue, enable debug logging and check the logs for specific error messages. The key is understanding that hosting company mail servers are often unreliable—professional sites use dedicated email services with proper SPF/DKIM authentication. Set this up properly and email delivery becomes reliable and automatic.