SMTP Response Codes Reference
Understanding SMTP Response Codes
The Simple Mail Transfer Protocol (SMTP) uses numerical response codes to indicate the status of a command. Understanding these codes is crucial for diagnosing email delivery issues and ensuring smooth communication between mail servers. This cheat-sheet provides a quick reference for common SMTP status codes.
SMTP Status Code Meanings
Status Code | Description |
---|---|
211 | System status or system help response |
214 | Help message |
220 | Service ready |
221 | Service closing transmission channel |
235 | Authentication successful |
250 | Requested mail action completed |
251 | User not local; will forward |
252 | Cannot verify the user; will attempt delivery |
354 | Start mail input; end with <CRLF>.<CRLF> |
421 | Service not available, closing transmission channel |
450 | Requested action not taken - mailbox unavailable |
451 | Requested action aborted: local error in processing |
452 | Requested action not taken - insufficient system storage |
500 | Syntax error, command unrecognized |
501 | Syntax error in parameters or arguments |
502 | Command not implemented |
503 | Bad sequence of commands |
504 | Command parameter not implemented |
550 | Requested action not taken - mailbox unavailable |
551 | User not local; please try <forward-path> |
552 | Requested mail action aborted - exceeded storage allocation |
553 | Requested action not taken - mailbox name not allowed |
554 | Transaction failed |
Key SMTP Code Categories
2xx - Positive Completion Replies
These codes indicate that the requested action was successfully received, understood, and accepted. For example, a 220 code signifies that the mail service is ready to accept commands.
3xx - Intermediate Positive Replies
These codes indicate that the command has been accepted but that some more information is required before the action can be completed. The 354 code, for instance, prompts the sender to start providing the mail content.
4xx - Transient Negative Replies
These codes indicate that the command was not accepted, but the error condition is temporary. The server may be temporarily unavailable or overloaded. A 421 code means the service is not available and the connection will be closed.
5xx - Permanent Negative Replies
These codes indicate that the command was not accepted and the error condition is permanent. The sender should not retry the command without modification. A 550 code typically means the mailbox is unavailable.