Arama Yap Mesaj Submit
Request a Callback
+90
X
X

Select Your Currency

Turkish Lira $ US Dollar Euro
X
X

Select Your Currency

Turkish Lira $ US Dollar Euro

Contact Us

Location Halkali merkez neighborhood fatih st ozgur apt no 46 , Kucukcekmece , Istanbul , 34303 , TR
WordPress Technical Guide

WordPress Not Sending Mail: Password Reset, Form, and SMTP Guide

The WordPress wp_mail() function creates a message and delivers it to the server's email infrastructure; a successful return does not necessarily mean the recipient has received the message. Form, password reset, and WooCommerce email applications should be examined separately, including SMTP, DNS authentication, and delivery logs.

wp_mailSMTPSPFDKIMWooCommerce Mail
root@server:~SSH
wp_mail returned true but message not received
SMTP Error: Could not authenticate
Connection timed out on port 587
550 SPF/DKIM validation failed
WordPress LayerKernel, theme and plugin behavior.
PHP layerVersion, extension, limit, and fatal error
Server layerWeb service, database, disk, and logs
Secure MethodBackup, log, isolate, and verify
01
Technical description

Why WordPress Won't Send Email or Why Mail Won't Reach?

The issue can occur in one of three layers: WordPress does not generate a message, the SMTP/MTA does not accept the message, or the remote recipient rejects or marks the message as spam. Each layer requires different logs and tests.

Contact Form 7 or WooCommerce may display a 'sent' message, but this is no guarantee of delivery. The wp_mail_failed hook, SMTP log, and server mail log should be examined together

The from address should be compatible with the site domain; using a random Gmail address as From may break SPF/DMARC alignment. Visitor address should be used in the Reply-To field.

Port 25 may be blocked by the data center; authenticated SMTP typically uses 587 STARTTLS or 465 TLS. The correct host, port and encryption values provided by the provider should be used.

SPF, DKIM, DMARC, and PTR/rDNS determine the reliability of mail delivery. Even if DNS records are correct, the sender IP may be blacklisted or the domain reputation may be low.

Instead of storing your SMTP password in plain text in wp-config.php or the plugin database, use the environment/secret method whenever possible and use a limited-access application password.

02
Log messages and their meanings

WordPress wp_mail, SMTP, and delivery error messages

Search for the phrase you see in the email, browser, or SSH log. Each card includes meaning, probable cause, and safe initial action.

8 registration
01kritik

wp_mail() returned false

Meaning: WordPress/PHPMailer failed to deliver the message to the mail layer.

Possible cause: Invalid address, hook error or mailer issue.

Log wp_mail_failed details.
02warning

wp_mail returned true but mail not received

Meaning: Has accepted the local mail message but delivery has not been verified.

Possible cause: Spam, remote deny, DNS signature or queue.

Find the MTA/SMTP delivery log and message ID.
03kritik

SMTP Error: Could not authenticate

Meaning: The SMTP server has refused the username/password.

Possible cause: Incorrect identity information, 2FA, or app password.

Verify credentials from the provider panel.
04kritik

Connection timed out

Meaning: WordPress could not connect to the SMTP host/port.

Possible cause: Firewall, incorrect port, DNS, or service access.

Test the host:port connection from the server.
05kritik

Connection refused

Meaning: The target port is actively rejecting the connection.

Possible cause: Incorrect port or SMTP service closed.

Verify the correct port/encryption match.
06warning

550 SPF/DKIM/DMARC failed

Meaning: Remote server authentication has failed.

Possible cause: Missing or incorrect DNS records or From header mismatch.

Verify the Sender Domain's DNS Records.
07warning

Mailbox unavailable / user unknown

Meaning: Recipient address does not exist or has been rejected.

Possible cause: Grammar error, deleted mailbox.

Check recipient address and bounce message.
08warning

WooCommerce email pending/not sent

Meaning: The order email event has not been triggered or has been left in the queue.

Possible cause: Action Scheduler, template or SMTP.

Review order notes and Scheduled Actions.

No records matching this expression were found.

03
Secure first review

SSH diagnostic commands and what output to look for?

Commands are for root access. Collect only status and logs first; Do not change the permanent setting without seeing the reason.

WordPress test mail
wp eval 'var_dump(wp_mail("[email protected]","WordPress test","Test mesajı"));'

The result of the wp_mail function in the application layer is shown.

DNS identity records
dig +short TXT example.com
dig +short TXT default._domainkey.example.com
dig +short TXT _dmarc.example.com

Displays SPF, DKIM, and DMARC records.

SMTP port test
timeout 10 openssl s_client -starttls smtp -connect smtp.example.com:587 -servername smtp.example.com </dev/null

Tests SMTP connection and TLS handshake from the server.

Postfix logu
tail -n 150 /var/log/maillog 2>/dev/null || tail -n 150 /var/log/mail.log 2>/dev/null

Displays local mail delivery and bounce records.

Exim logu
tail -n 150 /var/log/exim_mainlog 2>/dev/null

cPanel/Exim send and queue logs are shown.

Cron and Action Scheduler
wp cron event list --fields=hook,next_run_relative | head -n 40

Checks the cron side of delayed email jobs.

04
By hosting environment

Controls to be applied on cPanel, Plesk and panelless server

The root cause of the WordPress error is the same, but log paths, PHP settings screens and service management vary depending on the hosting infrastructure used.

cPanel / WHM

Email Deliverability, Track Delivery, and Exim logs are used in cPanel.

  • Verify SPF/DKIM status from Email Deliverability.
  • Find the message ID and rejection reason with Track Delivery.
  • If external SMTP is being used, test port 587 access.
grep -i 'ALICI@DOMAIN' /var/log/exim_mainlog | tail

Plesk Obsidian

Mail Settings, Mail Log Browser, and DNS records are checked in Plesk.

  • Domain mail service should be suitable for local/external use.
  • Find sender, recipient and status records in the mail log.
  • Verify DKIM signing and SPF recommendations.
grep -i 'ALICI@DOMAIN' /var/log/maillog | tail

Panel-less Linux Server

In a panel-less server, Postfix/Exim or external SMTP connection is directly inspected.

  • Check MTA service and queue status.
  • Verify the firewall outbound 25/465/587 policy.
  • Check the PTR/rDNS record in the provider panel.
postqueue -p 2>/dev/null || exim -bp 2>/dev/null
05
Safe solution order

Steps to safely resolve WordPress mail sending issues

First, check if WordPress is producing messages, then SMTP/MTA acceptance and finally remote delivery with DNS verification.

1

Delineate the type of the issue

Determine if password reset, form, WooCommerce, or all wp_mail messages are affected.

2

Create a controlled test message.

Send a test email to a single recipient and record the time and From address.

3

Message ID not found in Mailer/SMTP log.

Application returns true even if MTA or SMTP response is not visible.

4

Verify host, port, encryption and auth values

587 Do not confuse STARTTLS with 465 implicit TLS.

5

Check SPF, DKIM, DMARC, and PTR

Ensure that from domain authentication is aligned.

6

Verify Gmail/Outlook delivery

Examine spam, bounce, and provider reputation records

06
Distinction by symptom

Special scenarios and decision trees

Contact Form 7 message not arriving

Check the form's To/From/Reply-To fields and SMTP log.

Password reset email is missing.

admin_email, user address, wp_mail and spam folder are checked.

WooCommerce order email is delayed.

Scheduled Actions, cron, and order status triggers are checked.

wp cron event list
SMTP authentication error

The application password, 2FA, and user name format are verified.

Only reaching Gmail

SPF/DKIM/DMARC, PTR, IP reputation, and Gmail bounce message are examined.

Absolutely don't

  • Do not store your SMTP password in a publicly accessible file.
  • Do not make the visitor's email address the From address.
  • Do not consider the result of wp_mail as a delivery confirmation if it returns true.
  • Do not add multiple separate SPF TXT records to the SPF record.
  • Do not test Port 25 block by completely closing the firewall.
  • Do not constantly change extensions without examining bounce and mail logs.

Post-solution verification

  • Test message is being accepted by SMTP/MTA with message ID.
  • The recipient sees the message in their inbox or spam.
  • SPF, DKIM, and DMARC validation is passing.
  • From and Reply-To fields are being used correctly.
  • WooCommerce/form/password reset working separately
  • No permanent deferred messages are accumulating in the mail queue.
07
Official technical resources

WordPress and WP-CLI official documentation

08
Internal SEO content set

Related WordPress error solutions

09
Frequently asked questions

WordPress Not Sending Mail Curiosities about

Does wp_mail return true, has the mail been delivered?

No. It only shows that WordPress successfully sent the message to the mail layer; delivery should be verified with a log.

What port should be used for SMTP?

Provider mostly uses 587 STARTTLS or 465 TLS.

Why should the from address be my domain's?

SPF/DMARC configuration and delivery reliability must be compatible with the sender domain.

Where should the visitor address be written in Contact Form 7?

Should be used in Reply-To field instead of From.

SPF, DKIM, DMARC gerekli mi?

Strongly recommended for delivery reliability and fraud prevention.

Why is the WooCommerce email delayed?

Cron, Action Scheduler, order status, or SMTP queue delay may occur.

Is external SMTP better?

A correctly configured reliable service usually provides an advantage in terms of delivery and logging.

EKA SOFTWARE AND INFORMATION SYSTEMS

Let's fix the error on your server permanently

By analyzing cPanel, WHM, CloudLinux, LiteSpeed, MariaDB, Exim and security layers together, we fix the root cause of the failure instead of just removing the service.

Get Server Support WhatsApp
Top