How to send email automatically and periodically


Warning: Parameter 2 to qtranxf_postsFilter() expected to be a reference, value given in /home/and-beyond/www/main/wp-includes/class-wp-hook.php on line 286

Warning: Parameter 2 to qtranxf_postsFilter() expected to be a reference, value given in /home/and-beyond/www/main/wp-includes/class-wp-hook.php on line 286

How do you do, when you should send email periodically? With Google Apps Script, we can send email automatically and periodically.

First, wrote the code to send email like below.

You can add CC and BCC on the email.

And now, select “Resources” from menu, and click “Current project’s triggers”, and follow the instructions and create a trigger to execute sending method periodically. You can send email everyday, or on the specific weekdays, or beginning or end of month, etc. Notification email is available, which tells you the information when program fails.

In the above case, I use MailApp for sending email、 You can send email according to you or other’s calendar, using CalendarApp. Detail of MailApp or CalendarApp, Utilities is on the online document published by Google.