What is the legal and correct helo for my SMTP server.

  • Out going email only.
  • Behind a NAT with no inbound ports open.
  • SMTP server does not have a FQDN.
  • Send mail for 2 different domains

We are a small business that has multiple locations. We have 2 different web sites with email addresses eg.:

Our SMTP server will send email for both domains.

RFC2821 section

... and no reverse mapping record is available), the client SHOULD send an address literal (see section 4.1.3), optionally followed by information that will help to identify the client system.

4.1.3 Address Literals**

... To bypass this barrier a special literal form of the address is allowed as an alternative to a domain name. For IPv4 addresses, this form uses four small decimal integers separated by dots and enclosed by brackets such as [] ...

therefore I think that my helo name should be:

[] company name INC city, state

postfix configuration

smtp_helo_name = [] company name INC city, state

Using this I still get the following errors:

... status=bounced (host mx1c38.carrierzone.com[] refused to talk to me: 501 5.0.0 Invalid domain name

... status=bounced (host mta5.am0.yahoodns.net[] refused to talk to me: 501 Syntax error in parameters or arguments

... status=bounced (host kakllc.com[] said: 550 Access denied - Invalid HELO name (See RFC2821 (in reply to MAIL FROM command)

and other similar errors all pertaining to the helo.

Is this a correct helo?

2 Answers 2


Give the host a FQDN, e.g. foo.product1.com. Set the HELO to be this fully qualified domain name. Ensure that external DNS can resolve that name. Otherwise, you'll see lots of rejects, as observed, as blocking such (possibly via something like smtpd_helo_restrictions = reject_invalid_hostname reject_non_fqdn_hostname) is an inexpensive way to eliminate a certain percentage of incoming spam.

  • It may be worth adding that it's often a good idea to also set the hostname in reverse DNS (if possible), as many people also use the reject_unknown_reverse_client_hostname restriction. So yes, a FQDN is the way to go.
    – tarleb
    Commented Nov 24, 2015 at 20:34
  • The reverse DNS lookup record (DNS PTR) for my ip-address is what I used for my server FQDN in the helo.This has stopped the rejects due to invalid helo. My next step is to add a SPF entry to the DNS TXT record to the domains that I send email for.Please see my next question. SPF DNS TXT syntax
    – jc__
    Commented Dec 7, 2015 at 16:46

Using postfix (on Ubuntu 16.04.3), I was receiving the access denied message in the postfix log at /var/log/mail.log:

550 Access denied - Invalid HELO name (See RFC2821 (in reply to MAIL FROM command)

To try to get it working I added an FQDN entry for my host in /etc/hosts and changed the hostname. That alone did not work - by commenting out the following line to the postfix configuration at /etc/postfix/main.cf I was able to get it working:

#myhostname = ubuntu

You can read the default behavior for the myhostname setting in the documentation.

To restart postfix after I made the configuration change, I used the following command:

sudo service postfix restart

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .