Skip to content

Postman SMTP is now Post SMTP: setup, OAuth and limits

Postman SMTP is now called Post SMTP Mailer. Set it up with OAuth 2.0 for Gmail or Microsoft 365, read its email log, and see what it cannot fix.

Postman SMTP is now Post SMTP Mailer. It is the same plugin, renamed years ago, and it installs under the directory slug post-smtp. If you typed the old name, you are in the right place. The next thing worth knowing is that an old Postman SMTP install usually still carries an OAuth setup made under rules that Google and Microsoft have both tightened since. What the plugin does is narrow. It hooks WordPress on phpmailer_init, swaps the outgoing transport from the server’s mail() function to authenticated SMTP or a provider’s API, and writes every attempt to an email log you can read without shell access. What it cannot do is decide whether the message is accepted. SPF, DKIM and DMARC records on the sending domain decide that, and no plugin setting overrides DNS.

What you’ll accomplish

  • Confirm that “Postman SMTP” and “Post SMTP Mailer” are one plugin, and know what a legacy install is likely holding.
  • Place the plugin exactly in the wp_mail() chain, so you can separate a plugin fault from a DNS fault before touching either.
  • Configure a transport — SMTP password auth or OAuth 2.0 for Gmail and Microsoft 365 — and prove a send from the command line.
  • Read the plugin’s email log well enough to name a failure rather than guess at it.
  • Recognise the cases where Post SMTP is the wrong tool and the credentials should live somewhere other than WordPress.

Prerequisites

  • WordPress on a currently supported 6.x release, running PHP 8.x. Older PHP will run the plugin but not the TLS behaviour you want underneath it.
  • An account to send through: a mailbox on Google Workspace or Microsoft 365, an SMTP relay, or a transactional provider with an API key.
  • DNS control over the domain in the From address. Without the ability to publish TXT records you can configure the plugin correctly and still watch mail land in spam.
  • Shell access with WP-CLI and dig available, plus administrator access to the site.
  • If you want OAuth: an hour in the Google Cloud console or the Microsoft Entra admin center, and permission to register an application in that tenant. This is real work on their side, not a checkbox in WordPress.

How it works

WordPress core has exactly one outbound mail function, wp_mail(). Everything sends through it: password resets, new-user notices, comment moderation, WooCommerce order mail, contact-form submissions. Internally it builds a PHPMailer object, sets the From address, headers and attachments, and then fires the phpmailer_init action with that object passed by reference. That action is the last point at which anything can change how the message leaves. With no plugin listening, PHPMailer falls back to PHP’s mail(), which shells out to the server’s sendmail binary with no authentication at all — the reason so much WordPress mail is silently discarded by receivers.

Send path from wp_mail through PHPMailer and the phpmailer_init hook, showing Post SMTP replacing the transport with SMTP or an API mailer and writing to its email log

Post SMTP registers a callback on phpmailer_init and rewrites that object: isSMTP() with a host, port and credentials, or a provider transport that posts the message over HTTPS instead. It also wraps the send so the result — the SMTP conversation or the API response body — is stored as a log entry. That log is the plugin’s most useful feature and the reason to keep it on a site where mail matters, because it turns “the customer says they never got it” into a timestamped record with a server response attached.

Two consequences follow from the hook design. First, only one listener can win: if two mailer plugins both hook phpmailer_init, whichever runs last sets the transport, and the other one’s settings page will keep showing a configuration that never applies. Second, everything the plugin does happens before the message leaves your server. Alignment, reputation and filtering all happen after that, which is why a green test in the plugin and a message in the spam folder are entirely compatible states.

Step-by-step

1. Install and activate, and see what is already there. On a legacy site, check before you install — an old Postman SMTP install upgrades in place under the current slug:

wp plugin list --status=active --field=name | grep -iE 'smtp|mail'
wp plugin install post-smtp --activate
post-smtp
Plugin 'post-smtp' is already installed.
Plugin 'post-smtp' activated.

If that first command returns a second mailer — wp-mail-smtp, fluent-smtp, easy-wp-smtp — deactivate it now. Running two is the single most common reason a correct-looking configuration does nothing.

2. Find every plugin hooking the transport. This is worth doing even when the plugin list looks clean, because themes and custom mu-plugins hook it too:

grep -rn "phpmailer_init" wp-content/plugins wp-content/mu-plugins wp-content/themes --include='*.php' | cut -d: -f1 | sort -u
wp-content/mu-plugins/site-overrides.php
wp-content/plugins/post-smtp/Postman/PostmanWpMail.php

An mu-plugins file in that list is the one to read first. It loads before regular plugins but often re-hooks later, and a hard-coded $phpmailer->Host in there will quietly beat the settings page.

3. Register the OAuth application, if you are going that route. Be clear-eyed about the trade here. OAuth 2.0 means the site never stores a mailbox password and a compromised database does not hand over one — the real argument for this plugin. It also means a genuine setup task in someone else’s console: in Google Cloud, create a project, enable the Gmail API, configure the consent screen, create an OAuth client of type Web application, and add the redirect URI the plugin shows you on its setup screen; in Microsoft Entra, register an application, add the Microsoft Graph or SMTP send permission, grant admin consent, and create a client secret with an expiry you will have to diary. Paste the client ID and secret into the plugin, then run its authorisation link and approve it as the sending mailbox — not as your own admin account, unless that is genuinely the sender.

If the tenant will not allow an app registration, use SMTP with a mailbox password or an app password instead, and accept that WordPress now holds a credential.

4. Set the transport and the From address to something aligned. The From domain is the one that has to pass DMARC, so it must be a domain you control DNS for — not gmail.com, and not a customer’s address copied from a form field. Confirm what the plugin stored:

wp option get postman_options --format=json
{"transport_type":"smtp","hostname":"smtp.gmail.com","port":"587","enc_type":"tls","auth_type":"oauth2","sender_email":"noreply@example.com","sender_name":"Example Store"}

Check sender_email against the domain you are about to publish DNS for. A mismatch here is the root cause of most “configured everything and still in spam” tickets.

5. Prove outbound port 587 is actually open before blaming the plugin. Many shared hosts block it at the firewall:

openssl s_client -starttls smtp -connect smtp.gmail.com:587 -crlf -quiet
250 SMTPUTF8

A banner and a 250 mean the path is open. A hang with no output means the port is blocked outbound, and the fix is either a host firewall change or moving to an API transport on 443.

6. Send a real message through wp_mail(), not through a plugin test button. The plugin’s own test can bypass parts of the core path; this does not:

wp eval 'add_action( "wp_mail_failed", function( $e ) { echo "FAILED: " . $e->get_error_message() . "\n"; } ); var_dump( wp_mail( "you@example.com", "Post SMTP probe", "Sent from wp eval at " . gmdate( "c" ) ) );'
bool(true)

bool(true) means the transport accepted the message — nothing more. A false with a FAILED: line above it gives you the PHPMailer error verbatim, which is usually enough on its own.

7. Read the log entry for that send. Where the log lives depends on how old your install is: older releases stored each entry as a postman_sent_mail custom post, newer ones use a dedicated table. Check both:

wp post list --post_type=postman_sent_mail --format=count
wp db query "SHOW TABLES LIKE '%post_smtp%';"
412
wp_post_smtp_logs

Then open the entry in Post SMTP → Email Log in the admin. A successful send shows the transport used, the recipient, and the server’s closing response; a failure shows the SMTP transcript or the API error body, which names the cause far more precisely than any WordPress error message will.

8. Verify the DNS the plugin cannot touch. SPF authorises the sending host, DKIM signs the message, DMARC requires one of them to align with the From domain:

dig +short TXT example.com | grep spf1
dig +short TXT google._domainkey.example.com
dig +short TXT _dmarc.example.com
"v=spf1 include:_spf.google.com ~all"
"v=DKIM1; k=rsa; p=MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA..."
"v=DMARC1; p=none; rua=mailto:dmarc@example.com"

Substitute your provider’s selector for google — each one publishes its own. An empty result for any of the three is a finding, not a formality. DKIM, SPF and DMARC alignment on WordPress covers what to publish per provider.

Decision tree for a missing WordPress email: did it leave WordPress, did it leave the server, did the receiver accept it, did it align

Validate it works

A configuration is only proved by a message you received and inspected. Trigger a real WordPress email rather than a synthetic one — a password reset exercises the same path your users do. Run it against a disposable account you create for the purpose, never against your own administrator: reset-password changes the password immediately, and pointing it at the account you are logged in as is how people lock themselves out mid-migration.

wp user create smtpprobe smtpprobe@example.com --role=subscriber --porcelain
wp user reset-password smtpprobe
57
Success: Updated 1 user.

Delete it afterwards with wp user delete smtpprobe --yes.

Then open the received message and view its full source. In Gmail that is Show original; in most clients, “view source” or “message details”. Look for the receiver’s own verdict:

Authentication-Results: mx.google.com;
       dkim=pass header.i=@example.com header.s=google;
       spf=pass (google.com: domain of noreply@example.com designates 209.85.220.41 as permitted sender);
       dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=example.com

Three passes and header.from showing your own domain is the outcome you want. dkim=pass with a header.i on the provider’s domain instead of yours is the alignment trap: the message is signed, but not by you, so DMARC still fails. Finally, confirm the log agrees — the entry for that send should exist, show the transport you configured, and carry the receiver’s success response. Log entry present, headers passing, message in the inbox: those three together are the check.

Troubleshooting

OAuth stopped working after a password change. Changing or resetting the mailbox password, or an admin revoking app access, invalidates the refresh token — the plugin then logs an authentication failure on every send until someone re-authorises it in the admin. This is the operational cost of OAuth, and it is why a client secret with an expiry date belongs in a calendar reminder rather than in someone’s memory.

Port 587 is blocked outbound by the host. Step 5 hangs with no banner. Nothing in the plugin fixes a firewall. Ask the host to open 587, or switch to an API transport that posts over 443 — which is also the more reliable answer on hosts that block SMTP as policy rather than by mistake.

Another plugin is winning phpmailer_init. The settings page looks right, the log shows nothing, and mail still leaves unauthenticated. Step 2 lists the competitors. Deactivate all but one mailer; if a custom mu-plugin is the culprit, remove its hook rather than fighting it with priorities. Diagnosing silent wp_mail() failures walks the wider version of this.

Mail delivers but lands in spam. The log is green, Authentication-Results says otherwise. Almost always the From domain is not the domain you published DKIM for — a form plugin setting the sender to the visitor’s own address is the classic version. Set From to an address on your domain, put the visitor in Reply-To, and re-test.

The log is filling the database. A busy WooCommerce store writes thousands of entries a month, and the free tier caps retention low enough that it will roll over quickly while still occupying space. Check what it costs you and prune deliberately:

wp db size --tables | grep -iE 'postmeta|post_smtp'
wp_postmeta	184 MB
wp_post_smtp_logs	22 MB

Set a retention period in the plugin’s settings rather than deleting rows by hand, and if the log is the reason you keep the plugin, size the retention to how far back you would actually need to prove a send.

When this is the wrong approach

If you are sending real transactional volume, the plugin is the wrong layer to reason about. A provider with its own API — bounce and complaint webhooks, suppression lists, per-message event history, sending IPs someone else warms — models things no WordPress plugin does. Post SMTP can hand off to several such providers, and at that point the plugin is a shim: treat the provider’s dashboard, not the plugin log, as the record. Bulk newsletter sending belongs there too, not behind a mailbox with a per-day send cap.

If the site should not hold sending credentials at all, use a relay that authenticates the host rather than the application: WordPress hands the message to a local submission agent, and the secret lives in server configuration outside the web root, where a plugin vulnerability cannot read it.

And if what you actually have is a deliverability problem rather than a transport problem, installing this plugin will not move it. Fix the DNS first, then pick the mailer. Plugin details are on the Post SMTP directory listing.

Running WordPress that earns real money deserves an operator — Stack Harbor runs that stack under Enterprise WordPress; book an infrastructure consult.