How to disable email notification in WordPress Cron job?

In this article, we will show you how to disable email notification you get whenever the cron job runs.

To disable it you will need to simply add the below line in cron job command.

>/dev/null 2>&1	

Here is an example command to demonstrate it.

15 * * * Mon     ${HOME}/exampletask.sh > /dev/null 2>&1	

To again start receiving the email notification simply remove > /dev/null 2>&1 from the command.

  • 0 Users Found This Useful

Was this answer helpful?