Skip to content
Microsoft (Outlook.com and Microsoft 365) · permanent error

5.7.506: bad HELO name

Your server greeted Microsoft 365 with the name of the server it was connecting to, instead of its own fully qualified domain name.

Microsoft
Provider
Permanent (5xx)
Class
Sources checked
Author

At a glance

Code
5.7.506
Temporary or permanent
PermanentRefused for good: the message comes back to the sender, and resending it gets the same answer.
Who has to act
The sender. The fix is on the sending side: your domain, your server or your list.
What the server says
5.7.506 Access Denied, Bad HELO

What it means

At the start of every SMTP session the connecting server introduces itself with HELO or EHLO, and it should give its own fully qualified domain name. Microsoft 365 rejects connections where the client instead announces the name of the server it is connecting to, a habit Microsoft calls typical spambot behavior, and answers with 5.7.506 Access Denied, Bad HELO. The fix is in the sending server's configuration: set its HELO name to its own host name, ideally the name its IP address resolves to in reverse DNS.

Common causes

  • The sending server's HELO or EHLO name is set to the destination's host name.
  • A misconfigured or malicious program fills in the HELO name with the server it connects to.

How to fix it

  1. 01Set the sending server's HELO or EHLO name to its own fully qualified domain name.
  2. 02Make sure that name resolves in DNS and matches the PTR record of the sending IP.
  3. 03If you did not configure this machine to send mail, check it for malware.

Sources

What this page rests on, checked on 20 Oct 2026. The explanation is ours; the reply text is the server's.

Further reading

All 111 Microsoft codesEvery code in the wikiPaste your own bounce

Beat · paid monitoring

A heartbeat for your email.

Beat runs every check on this site on a schedule: 41 checks, 33 blacklists and real inbox placement. The moment something breaks, it tells you what broke, why it matters, and the exact fix.

example.comWatching
  • SPFpass
  • DKIMpass
  • DMARCp=none
  • Blacklists0 of 33

Illustrative. Your domain, every few hours.

Also from us:Pulse: your own sending infrastructureConsulting: $65/hr, no retainer