Are you experiencing email sending issues while using WP Mail SMTP? Our plugin includes built-in debugging functionality to help you troubleshoot problems you encounter while using it.
This tutorial will show you how to use the WP Mail SMTP Debug Events.
In This Article
What Are Debug Events in WP Mail SMTP?
WP Mail SMTP is capable of tracking activity related to the processes required to send emails from your site. This information is stored as “Debug Events.”
By default, WP Mail SMTP records all email sending errors. However, you can also optionally turn on debugging to track all activity related to email sending so you can see what’s happening behind the scenes.
Viewing these events or sharing them with our support team can help you more easily identify and troubleshoot problems with sending emails from your site.
Note: WP Mail SMTP Debug Events only record errors and activity related to email sending. Our plugin does not monitor or report other issues, such as PHP errors.
For general debugging, you’ll need to enable
WP_DEBUG_LOG in your WordPress site’s
wp-config.php file. If you need help with this, see WPBeginnner’s tutorial on setting up WordPress error logs.
Enabling Debug Email Sending
You can find the settings for the Debug Events feature by logging into your WordPress admin area and navigating to WP Mail SMTP » Tools. Then click on the Debug Events tab.
Here, you’ll see two options under Event Types. The Email Sending Errors event type is enabled by default and cannot be turned off.
These are errors that have occurred and prevented your site from sending emails.
You may choose whether or not to turn on the Debug Email Sending event type by checking or unchecking the checkbox.
This event type records all of the activities that take place when your site sends an email, not just errors.
Note: For security purposes, it is considered best practice to leave debugging turned off when you’re not using it to troubleshoot a problem on your site.
Viewing WP Mail SMTP Debug Events
If an email sending error occurs, you’ll see an error message in your dashboard. Click the error event link to go to the Debug Events page and view the issue.
You can also view all debug events at any time by going to WP Mail SMTP » Tools » Debug Events and scrolling down to the table at the bottom of the screen.
Here you can see all of the events WP Mail SMTP has recorded. The columns contain the following information:
- Event #: The unique ID for this debug event.
- Type: This will read “Error” or “Debug” depending on the event type.
- Content: The error or debug message.
- Source: The component that sent or attempted to send the email related to the event (usually WP Core or a plugin).
- Date: When the event occurred.
You can also click on the Event # for any event to open up a box with more details.
You can use this information to troubleshoot any errors or share it with our support team if you need help.
That’s it! Now you know how to debug email sending in WP Mail SMTP.
Next, want to learn how to enable email logging in WP Mail SMTP? Check out our tutorial on how to set up email logs for a step-by-step guide.