Microsoft message-format rejection
Fix Outlook 550 5.7.512 invalid From header
Microsoft 365 returns 5.7.512 when the message does not contain a valid RFC 5322 From email address. Fix the software that generated the message; DNS authentication changes do not repair malformed headers.
The NDR can state:
550 5.7.512 Access denied, message must be RFC 5322 section 3.6.2 compliant
The message is permanently rejected. Generate a corrected message and submit it as a new delivery.
Common causes
- The From header is missing or empty.
- The application inserts a display name without a valid address.
- A template creates malformed angle brackets or address syntax.
- A gateway strips or rewrites the header incorrectly.
How to fix it
- Open the original raw message and find the RFC 5322 From header.
- Configure one valid mailbox address, optionally with a display name.
- Validate generated messages before SMTP submission.
- Check gateway rewrite rules.
- Send a newly generated test message.
Frequently asked questions
Is Outlook 5.7.512 a DNS error?
No. Microsoft describes an invalid or missing RFC 5322 From address in the message.
Which From field matters?
The message's visible RFC 5322 From header, not only the SMTP envelope MAIL FROM command.
Who should fix it?
The application, device, template, or mail library that constructs the message.
Related email diagnostics
Primary sources: Microsoft Exchange Online NDR reference and RFC 5322 Internet Message Format.