[wp-trac] [WordPress Trac] #64368: `Could not instantiate mail function` errors sending mail in 6.9
WordPress Trac
noreply at wordpress.org
Fri Dec 12 11:01:25 UTC 2025
#64368: `Could not instantiate mail function` errors sending mail in 6.9
--------------------------+-----------------------
Reporter: desrosj | Owner: SirLouen
Type: defect (bug) | Status: accepted
Priority: normal | Milestone: 6.9.1
Component: Mail | Version: 6.9
Severity: normal | Resolution:
Keywords: has-patch | Focuses:
--------------------------+-----------------------
Comment (by Monarobase):
Hello,
I understand that this ticket primarily addresses a PHP error related to
setting the Envelope-From.
However, I would like to comment on the broader decision to always define
an Envelope-From address, which is related but separate from the PHP error
itself.
The concern here is not whether an Envelope-From should exist, but that
RFC standards require the Envelope-From to be a valid mailbox. In many
real-world hosting environments, wordpress at domain.tld does not exist and
cannot be sure that it exists — particularly when email is hosted
externally.
The rationale given for defining an Envelope-From by default is to help
hosts that do not configure it correctly.
However, defining it with an invalid mailbox has the following
consequences:
- It reduces deliverability for WordPress sites on hosts that already
configure return paths correctly and prevents from receiving delivery
errors
- It negatively impacts IP reputation on hosts that do not enforce RFC
compliance.
- It blocks email entirely on hosts that do enforce RFC compliance and
reject invalid Envelope-From addresses.
While I agree that leaving the Envelope-From undefined is not ideal for
deliverability, it is still preferable to defining one that is invalid, as
the latter actively breaks previously working and RFC-compliant setups.
Given this, I would kindly ask the team to reconsider defining the
Envelope-From by default until a more complete solution is available — or
at least make it opt-in — ideally with:
- a configurable setting for the Envelope-From address, and/or
- detection and admin warnings when the configured Envelope-From is likely
invalid.
This would avoid breaking existing, correctly configured sites until
WordPress can improve email handling by allowing users to define the
"Envelope From" or the E-mail sender from WordPress's interface.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/64368#comment:42>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list