SMTP for WordPress — emails that actually arrive
By default, WordPress sends mail through the web server's PHP mail function. That works technically, but without authentication: to Gmail and Outlook, such a message is barely distinguishable from spam. Everyone knows the result — contact forms that never arrive and password-reset emails that end up in the spam folder.
An SMTP relay solves this by sending your mail through a server with an established reputation and proper authentication. In WordPress you set this up with an SMTP plugin; the five fields below are all you need.
Why it goes wrong without a relay
The classic symptom: the contact form reports "sent" but nothing comes in, or only for some recipients. The mail does leave — it gets rejected along the way or flagged as spam because nothing proves it comes from your domain.
Setting up SMTP in WordPress
Collect your details
Log in to your 2mail account and retrieve your SMTP server, username and password there.
Fill them in inside WordPress
Install an SMTP plugin for WordPress. There are several; which one you choose makes no difference to the settings, because they all ask for the same SMTP details. Fill them in and send the test email the plugin offers.
Authenticate your domain
Make sure SPF, DKIM and DMARC are set correctly for your domain, so recipients can verify that the mail comes from you.
Test
Send a test message to an address at a major provider and check that it arrives in the inbox and not in the spam folder.
The fields WordPress asks for
Every platform names them slightly differently, but it is always the same five. The actual values are tied to your account and can be found in your 2mail account — take them from there, so you are sure to use the right ones.
| Field | What you enter |
|---|---|
| SMTP server (host) | The server name from your 2mail account. |
| Port | The port that matches your chosen encryption; your account shows which one. |
| Encryption | TLS. Never send unencrypted — your credentials would otherwise travel in plain text. |
| Username | The SMTP login of your 2mail account. |
| Password | The matching password. Never use the password of an employee's mailbox. |
Which emails WordPress sends
As soon as the relay is set up, all of these run through 2mail — you do not have to configure them one by one.
Pitfalls with WordPress
Sender address on your own domain
Set the "from" address to an address on your own domain, not to the address of the visitor who filled in the form. If you do the latter, you are sending mail on behalf of a domain that is not yours — exactly what spam filters trigger on. Put the visitor's address in the reply-to field.
One plugin that sends mail
If multiple plugins are running, each with its own SMTP settings, there is no telling which one wins. Pick one and switch the rest off.
Test after every migration
If your site moves to another server or URL, immediately check that mail still goes out. This is the part that most often breaks silently.
A different platform?
SMTP is a standard protocol: any system that speaks SMTP — a CRM, an ERP, a custom application or a server — can send through 2mail using the same five fields.