PHPMailer overview

Overview

PHPMailer is a fully-featured email creation and transport class for PHP which allows you to send email via SMTP. Visit PHPMailer’s GitHub page for further details on what it has to offer.

Installing PHPMailer on a Shared server

View the following article for instructions on installing on a Shared server.

Installing PHPMailer on a VPS or Dedicated server

View the following article for instructions on installing on a VPS or Dedicated server using Composer.

Important note about bulk email

Bulk email of any kind sent from a DreamHost account is subject to the DreamHost spam policy which is part of the terms of service. Please read those pages along with SMTP quota to ensure you’re not in violation of any of these policies.

Troubleshooting

Certificate errors using PHP 5.6

PHP 5.6 handles certificates differently than previous versions as explained on the following page:

If you use an incorrect mail hostname, you may see the following error when attempting to send email:

Warning: stream_socket_enable_crypto(): Peer certificate CN=`*.mail.dreamhost.com' did not match expected CN=`mail.example.com'

This is due to the hostname being used. View the following article for a detailed solution:

Allowing GMAIL to send from your mail application

If you're using your GMAIL address to send via SMTP, you must first allow your application access to your GMAIL address. If you do not do this, your email will not authenticate and not send. View the following article for details:

See also

Did this article answer your questions?

Article last updated PST.