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

5.4.1: server does not accept mail for this domain

The server that answered does not accept mail for the recipient's domain, which usually points to a wrong MX record or server setting.

Microsoft
Provider
Permanent (5xx)
Class
Sources checked
Author

At a glance

Code
5.4.1
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 recipient's side. Their mail admin has to change something; you can tell them.
What the server says
5.4.1 Relay Access Denied

What it means

Microsoft lists Relay Access Denied under 5.4.1 for a mail server that does not accept mail for the recipient's domain. A server only takes messages for the domains it is responsible for; delivering anything else would be relaying, which it refuses. Microsoft attributes the error to mail server or DNS misconfiguration: the MX record sends the mail to the wrong server, or the right server is not set up for the domain. The recipient's admin is the one who can fix it. The same words appear in 5.7.64 TenantAttribution, which has a different cause.

Common causes

  • The recipient domain's MX record points to a server that does not handle that domain.
  • The domain was removed from, or never added to, the accepted domains of the receiving server or tenant.

How to fix it

  1. 01Check the recipient domain's MX record with an MX lookup.
  2. 02Tell the recipient's admin which server refused the message, as named in the report.
  3. 03The recipient admin should point the MX record at the right server, or add the domain as accepted on the server it points to.

Sources

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

  1. 550 5.4.1Recipient rejected by Directory-Based Edge Blocking.Microsoft 365 rejected the message at its edge because the recipient address does not exist in the destination tenant.MicrosoftPermanent
  2. 550 5.7.64Relay not attributed to your tenant.Microsoft 365 could not match your on-premises server to an inbound connector, so it refused to relay its mail.MicrosoftPermanent
  3. 5.7.1Unable to relay.The receiving system refused to pass the message on because it is not the final destination for the recipient domain.MicrosoftPermanent

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