Skip to main content

msmtp and Google's SMTP Relay Service

If you’re using msmtp to send email through Google’s SMTP Relay Service, you might get this error: “the server sent an empty reply”.

To fix, try setting a domain in your /etc/msmtprc file. For example, if you’ve configured SMTP Relay to allow email from your server’s IP with TLS and no authentication, and your Google Workspace domain is awmb.uk, your /etc/msmtp file might look like:

defaults
auth        off
tls         on
logfile     /var/log/msmtp
domain      awmb.uk
from        [email protected]

account     default
host        smtp-relay.gmail.com
port        587

Next post:

Previous post: