Search Over 30,000 FREE Plugins from the Official WordPress Plugin Directory Repository

Stop Emails

Stop all outgoing emails sent from WordPress.

Stops outgoing emails sent from WordPress. This plugin stops outgoing emails generated by WordPress core, plugins, and themes. Emails sent using the wp_mail() function, will not be sent. In the case where an author does not use the recommended wp_mail() function and instead sends the email using another mechanism, an email will still be sent.

This plugin allows you to suspend sending emails when doing development work. Any calls to wp_mail() will fail silently. WordPress will operate as if the email were sent successfully but no email will actually be sent.

On the admin menu page Settings > Stop Emails, there is the option to log all emails to the PHP error log. By default this logging is disabled.

NOTE: If using the PHP mail() function directly, this plugin will NOT stop the emails.

Built by Sal Ferrarello / @salcode

Author Sal Ferrarello
Contributors salcode
Tags development, email
  1. stop-emails screenshot 1

    When the plugin is running, there will be a warning on the backend of the website.

  2. stop-emails screenshot 2

    Lies! The email wasn't really sent, we're running Stop Emails

  1. Install plugin from WordPress plugin repository
  2. Activate Stop Emails through the 'Plugins' menu in WordPress.

Manual Installation

  1. Upload the entire stop-emails directory to the /wp-content/plugins/ directory.
  2. Activate Stop Emails through the 'Plugins' menu in WordPress.

mu-plugin Installation

  1. If the directory wp-content/mu-plugins/ does not exist, create it.
  2. Upload the single file stop-emails.php to the wp-content/mu-plugins/ directory


  • Add filter to force BuddyPress to use wp_mail() rather than its own BP_PHPMailer class



  • No changes to code functionality
  • "Tested Up To:" version bump to 4.2
  • Update to readme.txt to more clearly communicate plugin functionality
  • Version bump to 1.0.1


  • Overhaul of plugin includes: fixing issue with plugin not stopping emails, moving to a class structure, changing email stopping behavior to use the same technique as WordPress core tests, improved inline documentation, addtion of phpunit tests. Introduces a breaking change with


  • Added check for supporting files before loading them. Since the primary functionality is in stop-emails.php, adding this check allows stop-emails.php to be used in the mu-plugins/ directory (previously, it would throw warnings)


  • Added filter fe_stop_emails_log to allow other logging of blocked emails


  • "Tested Up To:" version bump to 4.0
  • Add plugin icons


  • "Tested Up To:" version bump to 3.9
  • Add Settings link to plugin page


  • Add admin settings page with option to enable logging of stopped emails to PHP error log


  • Correct breaking change


  • Add Spanish translation (es_ES), thanks to Andrew Kurtis from


  • Added support for localization


  • Added filter fe_stop_emails_log_email for $log_email value, which allows a programmer to add code to log the blocked emails in the php_error.log
  • Renamed functions and classes to follow WordPress standards


  • First release

Where do the emails go?

The emails are lost forever.

Why are some of my emails still being sent?

Most likely, this is due to a plugin you have running. There are two different things the plugin could be doing to cause emails to still be sent.

  1. The plugin is overriding our overriding of the sending mechanism.
  2. The plugin is calling the PHP function mail() directly.

Unfortunately in either of these cases, this plugin will not be able to stop the email.

I want to log the emails that are stopped

You can enable logging of stopped emails on the admin menu page Settings > Stop Emails.

Emails will be logged to your PHP error log.

Why would I want install in the mu-plugins directory?

Activating a plugin normally requires logging into the site. Installing the file in the mu-plugins directory allows you to activate the plugin without logging in. This can be helpful when setting up an existing site locally.

Where can I report a bug?

Please report bugs at

Version 1.2.0

Requires WordPress version: 3.6 or higher

Compatible up to: 4.7.2

Last Updated 05 Dec 2016

Date Added: 20 Aug 2013

Plugin Homepage


5 stars
8 ratings


Not Enough Data

Works: 0
Broken: 0