It is a common requirement of websites to communicate via email. Whether it is an order confirmation for a customer, alerting the site administrators to an event, or simply transporting messages between machines, the PHP mail function underlies it all. This paper is a guide to the mail function; how it works, what it needs to work, and how you can easily implement it.