What 521 means
The host you connected to does not accept email at all. It is defined in RFC 7504 for systems that should never receive mail.
Typical bounce message
The exact wording differs between providers, but the code is what matters. Many providers add a link after the text that explains their specific policy.
Common causes
- The domain points its MX to a server that does not handle mail.
- You are connecting to a web server instead of a mail server.
If you sent the email
- Check the recipient address and domain.
If you manage the mail server or domain
- Look up the domain MX records to see where mail should go.
How to read this code
- 521 is the basic SMTP reply code. The first digit, 5, means a permanent failure: retrying the same message will not help.
Because this is a permanent failure, your mail server stops trying and returns the message to you with this explanation.
521 from each side of the email
| If you are | What you see | What to do first |
|---|---|---|
| The sender | A bounce message (also called a non-delivery report) in your inbox, usually within seconds or minutes. | Check the recipient address and domain |
| The recipient | Nothing. The message never reaches the inbox, so the recipient usually does not know it was sent. | Tell the sender through another channel which address works, or ask your IT team to check your mailbox and filters. |
| The mail admin | A rejected delivery in the server logs with status 5.0.0. | Look up the domain MX records to see where mail should go |
What the full bounce report looks like
Most mail servers send a delivery status notification in a standard format defined by RFC 3464. The human-readable part comes first, and a machine-readable part follows. For this error, the important lines look like this:
Action: failed
Status: 5.0.0
Remote-MTA: dns; mx.example.com
Diagnostic-Code: smtp; 521 5.3.2 This host does not accept mail
Action tells you whether the server gave up (failed) or is still trying (delayed). Status is the enhanced code. Remote-MTA names the server that refused the message, which tells you whether the problem is at the recipient's provider or somewhere in between. Diagnostic-Code is the exact reply that server gave, and it is the line to copy when you ask for help.
Should you resend?
Not until something has changed. A permanent error means the receiving server looked at the message and decided it will not accept it in its current form. Sending the same message to the same address again will fail the same way, and repeated hard bounces tell mailbox providers that you do not keep your list clean. That can push your future mail into spam folders for everyone, not just for this recipient.
Fix the cause first, using the steps on this page. Then send one test message, ideally to an address you control at the same provider, before you resend to the original recipient. If you send newsletters or app notifications, remove the address from your list after the first hard bounce of this kind.
Diagnose it: 521 usually points to a problem in the receiving mail system
- Check whether the problem is on your side or theirs. If every message to that domain fails while other domains work, the receiving system is the likely cause.
- Look at the time of the failures. System errors that cluster in one window often line up with an outage or a maintenance period.
- If the code is permanent, read the text closely. Some providers use x.3.x for features they do not support, such as a message format or an extension your server asked for.
Stop it from happening again
- Let your server retry temporary system errors on its normal schedule instead of resending by hand, which only adds duplicates.
- Subscribe to status pages for the providers your users rely on most, so you know when an outage is theirs.
Test your fix without bothering real people
Once you have changed a DNS record, a server setting or a message template, send a test to a free temporary inbox. It accepts mail from anywhere, shows the message within a second of arrival, and the Email X-ray on each message shows whether SPF, DKIM and DMARC passed. That tells you whether your authentication is working before you send to customers, and it keeps test messages out of real inboxes and out of your bounce statistics.
Codes in the same family
| Code | Meaning | Type |
|---|---|---|
| 451 | Local error in processing | Temporary |
| 552 5.3.4 | Message too big for system | Permanent |
| 421 4.3.0 | Temporary system problem | Temporary |
| 451 4.3.0 | Mail server temporarily rejected the message | Temporary |
A real-world example
A company's emails to one partner domain fail for two hours with system errors while mail to everyone else works. The partner's status page shows an outage at their provider. The sending server keeps retrying, and every message is delivered once the outage ends, with no action needed.
Terms used on this page
- Bounce
- A message returned to the sender because it couldn't be delivered.
- MTA
- Mail Transfer Agent, server software that receives and relays email between servers.
- Spam
- Unsolicited bulk email, usually commercial, sent without the recipient's consent.
- Hard bounce
- A permanent delivery failure, usually because the address does not exist.
- DNS
- The Domain Name System, which translates domain names into the information computers need, like IP addresses and mail servers.
- SPF
- Sender Policy Framework, a DNS record listing which servers may send mail for a domain, helping receivers detect spoofing.
Related guides
Related codes
FAQ
What does SMTP error 521 mean?
The host you connected to does not accept email at all. It is defined in RFC 7504 for systems that should never receive mail.
Is 521 a permanent error?
Yes. 521 is a permanent failure, so the sending server will not retry. Fix the cause and send the message again.
How do I fix 521?
If you sent the email: Check the recipient address and domain. If you run the mail server: Look up the domain MX records to see where mail should go.
Does 521 mean I am blacklisted?
Usually not. 521 points to a problem in the receiving mail system, not to your reputation. Blocklist rejections normally use codes in the x.7.x family, often 550 5.7.1 or 554 5.7.1.
Can the recipient fix it?
Rarely. Most causes of this error are on the sending side or in the receiving server's policy, so the sender or the sender's mail admin has to act.
Will I see 521 in Gmail or Outlook?
Yes, if your message fails this way. Gmail shows it in a message from "Mail Delivery Subsystem", and Outlook shows it in a non-delivery report that starts with "Delivery has failed" or "Undeliverable". The code is printed in the technical details near the bottom.
Codes and meanings follow RFC 5321, RFC 3463 and related standards, plus the published error references of major providers. Provider wording changes over time.