Send email from your website with SMTP
Send email from your website with SMTP
SMTP hosting is for sending automated mail โ password resets, order confirmations, contact-form messages โ reliably and authenticated.
Your credentials
From your SMTP service details: host, port, username, password and the encryption type (SSL/TLS or STARTTLS).
WordPress
Install an SMTP plugin (for example WP Mail SMTP or FluentSMTP), choose Other SMTP and paste the credentials. Send the built-in test email.
PHP (PHPMailer)
$mail->isSMTP();
$mail->Host = 'SMTP_HOST';
$mail->SMTPAuth = true;
$mail->Username = 'SMTP_USER';
$mail->Password = 'SMTP_PASSWORD';
$mail->SMTPSecure = PHPMailer::ENCRYPTION_SMTPS;
$mail->Port = 465;
Node.js (Nodemailer)
const transporter = nodemailer.createTransport({
host: 'SMTP_HOST',
port: 465,
secure: true,
auth: { user: 'SMTP_USER', pass: 'SMTP_PASSWORD' },
});
Keep credentials in environment variables, not in code.
Good practice
- Send from an address on your own domain and set up SPF, DKIM and DMARC.
- SMTP hosting is for transactional mail, not bulk marketing blasts.
- Watch bounce rates and remove invalid addresses.
If mail lands in spam see Why your emails go to spam.
Was this not what you needed?
Tell us what you're trying to do and our team will help directly.
Open a support ticket Ask on Discord