5.7.512: message has no valid From address
Microsoft 365 rejected the message because its From header does not contain a valid email address, as RFC 5322 section 3.6.2 requires.
- Microsoft
- Provider
- Permanent (5xx)
- Class
- Sources checked
- Author
At a glance
- Code
- 5.7.512
- 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.512 Access denied, message must be RFC 5322 section 3.6.2 compliant
What it means
Every message must carry a From header with a properly formatted email address, as RFC 5322 section 3.6.2 sets out. Microsoft 365 rejects messages without one with 5.7.512. Microsoft states the format it expects: the address inside angle brackets, for example <security@contoso.com>. The problem nearly always comes from a script, application or device that builds the header itself and leaves out the address or the brackets.
Common causes
- The From header is missing or contains only a display name.
- The address is written without angle brackets or is otherwise malformed.
How to fix it
- 01Inspect the raw headers of a sent copy and check the From line.
- 02Fix the sending application so it writes the header as From: Name <address@domain>.
- 03Resend once the header is valid.
Sources
What this page rests on, checked on 20 Oct 2026. The explanation is ours; the reply text is the server's.
- Email nondelivery reports and SMTP errors in Exchange Onlinelearn.microsoft.com
Related codes
- 550 5.1.20Several From addresses but no Sender.The message lists more than one address in its From header and none in its Sender header, which RFC 5322 does not allow.
- 550 5.6.241HVE: From header missing or invalid.The message submitted through HVE has no valid From header, or the header is formatted incorrectly.
Further reading
All 111 Microsoft codesEvery code in the wikiPaste your own bounce