RFC 3464: An Extensible Message Format for Delivery Status Notifications

Defines the machine-readable DSN format used in bounce messages and delivery receipts.
Alaa
By Alaa
SMTPedia documents email infrastructure end to end: SMTP standards from the RFC archive, delivera...
12 min read Updated Jul 22, 2026 202 views
RFC 3464
An Extensible Message Format for Delivery Status Notifications
Current standard
Domain
Message format
Published
January 2003
Obsoletes
RFC 1894
SMTP relevance
high
↗ Read on rfc-editor.org

What this RFC defines

RFC 3464 defines the DSN (Delivery Status Notification) format, the machine-readable structure used in bounce messages. When an email fails to deliver, the bouncing server generates a DSN that includes the original message headers, a human-readable explanation, and a machine-readable status block with standardised status codes.

Where you see it in practice

The structured bounce messages your ESP processes to identify hard bounces (user unknown) versus soft bounces (mailbox full) use the DSN format from RFC 3464. The three-part status code in bounce messages (5.1.1 for unknown user, 4.2.2 for mailbox full, 5.7.1 for policy rejection) is defined in RFC 3464’s status code field. When your ESP marks an address as a hard bounce after a 5.x.x DSN, it is parsing this format.

How it connects to other RFCs

RFC 3464 works alongside RFC 5321 (SMTP) and RFC 5322 (message format). RFC 6522 defines the multipart/report MIME type that wraps DSN messages. RFC 3798 (MDN, read receipts) uses a similar format. RFC 5965 (ARF, abuse reports) is a related feedback format used by mailbox providers for complaint reporting.

Current status

RFC 3464 is a current standard, published January 2003. The DSN format it defines is universally supported by MTAs and ESPs. The status codes it defines (enhanced mail system status codes) are the basis for the bounce classification logic in every major email verification and sending platform.

The DSN message format

RFC 3464 defines the Delivery Status Notification (DSN) format, which is what bounce messages use to convey structured information about delivery outcomes. A DSN is a multipart/report message with three parts: a human-readable explanation for the recipient, a machine-readable per-recipient status report (Content-Type: message/delivery-status), and the original message headers (or the entire original message). The machine-readable part contains fields like Action (failed, delayed, delivered, relayed), Status (5.1.1, 4.4.7, etc), Diagnostic-Code, and Final-Recipient.

Reading a bounce message

The Status field in a DSN follows RFC 3463 enhanced status codes: X.Y.Z, where X is the class (2 success, 4 transient, 5 permanent), Y is the subject (0 other, 1 addressing, 2 mailbox, 3 mail system, 4 network, 5 protocol, 6 media, 7 security), and Z is a detail. A status of 5.1.1 means permanent failure, addressing problem, bad destination mailbox (user unknown). Understanding this taxonomy is essential for automated bounce handling: you retry on 4.x.x, unsubscribe on 5.1.x, and investigate on 5.7.x (policy-related, often deliverability issues).

DSN request flags

SMTP senders can request DSN reporting behavior via the DSN extension (advertised as DSN in EHLO). RCPT TO commands can include NOTIFY=SUCCESS, NOTIFY=FAILURE, NOTIFY=DELAY parameters. Most transactional email uses NOTIFY=FAILURE to receive bounces without success confirmations. Bulk email services like SendGrid and Mailgun handle DSN parsing automatically and expose bounces through webhooks, so most senders never see the raw DSN format. If you handle mail directly (via Postfix, Exim, or a custom MTA), understanding RFC 3464 is essential for bounce handling.

Quick Reference

RFC 3464 (January 2003) defines the Delivery Status Notification (DSN) format, the machine-readable structure of bounce messages. A DSN is a multipart/report; report-type=delivery-status message per RFC 6522, with three parts: human-readable text, machine-readable delivery-status block, and original message (or its headers). Enhanced status codes (X.Y.Z per RFC 3463) surface bounce classification (5.1.1 user unknown, 4.2.2 mailbox full, 5.7.1 policy rejection). Sibling of MDN (RFC 3798, RFC 8098) and ARF (RFC 5965). Obsoletes RFC 1894.

RFC 3464 at a glance

AspectDetail
PurposeMachine-readable format for delivery status (bounces, delays, receipts)
Generated byMail Transfer Agent (MTA) when a delivery event needs reporting
MIME wrappermultipart/report; report-type=delivery-status (RFC 6522)
Status code formatX.Y.Z enhanced codes per RFC 3463 (class.subject.detail)
Action valuesfailed, delayed, delivered, relayed, expanded
Sender requestNOTIFY parameter on RCPT TO (per RFC 5321 DSN extension)
PublishedJanuary 2003 (obsoletes RFC 1894)
Typical useBounce classification, suppression list management

The DSN multipart/report structure

A DSN is transported as a standard email message with a specific MIME structure. The outer Content-Type carries the report-type parameter that identifies it as a DSN (as opposed to an MDN or ARF, which use the same multipart/report envelope).

PartContent-TypePurposeRequired?
1 (human-readable)text/plainFree-form explanation for the senderYes
2 (machine-readable)message/delivery-statusStructured per-recipient status blockYes
3 (original)message/rfc822 or text/rfc822-headersOriginal message or its headersRecommended

Complete delivery-status field reference

The second MIME part (Content-Type: message/delivery-status) is where the machine-readable status lives. It contains a per-message header block followed by one or more per-recipient header blocks separated by blank lines.

FieldScopePurposeRequired?
Reporting-MTAPer-messageThe MTA that generated this DSNRequired
Received-From-MTAPer-messageMTA that delivered the message being reported onOptional
Arrival-DatePer-messageWhen Reporting-MTA received the originalOptional
Original-Envelope-IdPer-messageENVID from RCPT TO (for correlation)Optional
Original-RecipientPer-recipientAddress as sent (from ORCPT parameter)Recommended
Final-RecipientPer-recipientAddress after aliases/forwarding resolvedRequired
ActionPer-recipientWhat happened: failed, delayed, delivered, relayed, expandedRequired
StatusPer-recipientEnhanced status code X.Y.Z per RFC 3463Required
Diagnostic-CodePer-recipientThe actual SMTP reply from the far MTARecommended
Remote-MTAPer-recipientMTA that produced the Diagnostic-CodeOptional
Last-Attempt-DatePer-recipientWhen Reporting-MTA last tried deliveryOptional
Will-Retry-UntilPer-recipientFor delayed action, when retries stopOptional (delayed only)

Action values

ActionMeaningSender should
failedPermanent delivery failureStop retrying; usually add to suppression list if 5.x.x address error
delayedTransient failure, will retryWait for eventual failed or delivered
deliveredSuccessful final deliveryOnly sent when NOTIFY=SUCCESS was requested
relayedPassed to non-DSN system; no further reportsTreat as terminal success
expandedAlias/list expanded; per-member reports may followWatch for per-member DSNs if requested

Enhanced status codes (RFC 3463)

The Status field carries the X.Y.Z enhanced code from RFC 3463. X is the class (2 success, 4 persistent transient, 5 permanent), Y is the subject, Z is the detail.

Y (subject)MeaningCommon Z values
0Other / Undefined4.0.0 transient generic, 5.0.0 permanent generic
1Addressing5.1.1 no such user, 5.1.2 bad domain, 5.1.3 bad address syntax, 5.1.6 destination mailbox has moved, 5.1.10 recipient overquota
2Mailbox4.2.2 mailbox full, 5.2.0 other mailbox status, 5.2.1 mailbox disabled, 5.2.3 message too large
3Mail system4.3.0 mail system full, 5.3.4 message too big for system
4Network / Routing4.4.1 no answer from host, 4.4.7 message expired
5Mail protocol5.5.0 protocol error, 5.5.2 syntax error, 5.5.4 invalid command arguments
6Message content / Media5.6.1 media not supported, 5.6.3 conversion required but not supported
7Security / Policy5.7.0 other security, 5.7.1 delivery not authorized (SPF/DMARC/blocklist), 5.7.25 no PTR record, 5.7.26 DMARC alignment failure

A complete DSN example

Real-world DSN for a 5.1.1 user-unknown bounce From: MAILER-DAEMON@mx.example.com To: alice@sender.com Subject: Undeliverable: Quarterly report Content-Type: multipart/report; report-type=delivery-status; boundary=”dsn-boundary-abc”–dsn-boundary-abc Content-Type: text/plain; charset=utf-8This is the mail system at host mx.example.com.I’m sorry to have to inform you that your message could not be delivered to one or more recipients.<bob@example.com>: host mx2.example.com said: 550 5.1.1 <bob@example.com>: Recipient address rejected: User unknown in virtual mailbox table (in reply to RCPT TO)–dsn-boundary-abc Content-Type: message/delivery-statusReporting-MTA: dns; mx.example.com X-Postfix-Queue-ID: A1B2C3D4E5 X-Postfix-Sender: rfc822; alice@sender.com Arrival-Date: Wed, 15 Jul 2026 09:32:15 +0000 (UTC)Final-Recipient: rfc822; bob@example.com Original-Recipient: rfc822;bob@example.com Action: failed Status: 5.1.1 Remote-MTA: dns; mx2.example.com Diagnostic-Code: smtp; 550 5.1.1 <bob@example.com>: Recipient address rejected: User unknown in virtual mailbox table Last-Attempt-Date: Wed, 15 Jul 2026 09:32:16 +0000 (UTC)–dsn-boundary-abc Content-Type: message/rfc822-headersFrom: Alice <alice@sender.com> To: Bob <bob@example.com> Message-ID: <abc123@sender.com> Subject: Quarterly report Date: Wed, 15 Jul 2026 09:15:22 +0000–dsn-boundary-abc–

Requesting DSN behavior with NOTIFY and ORCPT

SMTP senders control DSN generation via the RFC 5321 DSN extension (advertised as DSN in EHLO response). RCPT TO commands accept parameters:

Requesting DSN on failure only RCPT TO:<bob@example.com> NOTIFY=FAILURE ORCPT=rfc822;bob@example.comOptions for NOTIFY: NOTIFY=NEVER (no DSN ever) NOTIFY=SUCCESS (DSN on successful delivery) NOTIFY=FAILURE (DSN on permanent failure) NOTIFY=DELAY (DSN if delayed beyond threshold) NOTIFY=FAILURE,DELAY (combine, comma-separated)ORCPT preserves the original recipient across alias expansion, useful when the destination differs after forwarding.MAIL FROM can also carry: MAIL FROM:<alice@sender.com> RET=HDRS ENVID=abc-123RET controls what original content the DSN includes: RET=HDRS (headers only, smaller DSN) RET=FULL (entire original message)ENVID is a sender-chosen correlation ID that appears in the DSN’s Original-Envelope-Id field.

DSN vs MDN vs ARF: which is which

AspectDSN (RFC 3464)MDN (RFC 3798/8098)ARF (RFC 5965)
What it reportsDelivery outcomeUser interaction (read/deleted/etc)Abuse/spam complaint
Generated byMTAMUA (mail client)Receiving ISP (feedback loop)
Report-typedelivery-statusdisposition-notificationfeedback-report
TriggerDelivery event (auto)User opens messageUser hits “Mark as spam”
ReliabilityNear 100% on failuresUnder 5% consumerDepends on FBL registration
Typical useBounce processingRead tracking (rarely useful)Complaint suppression

Common DSN parsing pitfalls

Reading only the human-readable part. The text/plain first part is not standardized; every MTA writes different text. Do not parse it. Read the machine-readable Status, Action, and Diagnostic-Code fields from the message/delivery-status part instead. See the DSN parsing guide for correct parsing patterns.
Treating 4.x.x as permanent. RFC 3463 class 4 is persistent-transient: delivery failed but retries may succeed. Marking a 4.x.x address as a hard bounce and adding it to a suppression list is incorrect. Wait for the eventual failed (5.x.x) or a delivered outcome; the ESP should retry per its schedule.
Confusing DSN with the SMTP conversation. The 550 5.1.1 reply during RCPT TO is an SMTP response; the DSN is a separate email generated after the fact, addressed to the MAIL FROM, that carries the same information in structured form. Both surface through your bounce pipeline; do not double-count.
Ignoring the Diagnostic-Code text. The Status field says 5.7.1 (delivery not authorized) but does not distinguish SPF failure, DKIM failure, DMARC failure, blocklist rejection, or content filtering. The Diagnostic-Code contains the actual SMTP response text (like “550 5.7.1 Spamhaus SBL” or “550 5.7.26 DMARC alignment failure”). Parse it to determine the specific cause and route to the correct fix.
Not handling DSN loops. A DSN can itself fail to deliver, generating a DSN of a DSN. RFC 3464 requires DSN generators to use a null Return-Path (MAIL FROM:<>) to prevent loops. If you generate DSNs yourself, follow this rule. If you receive a DSN with a non-null Return-Path, be cautious about generating a bounce for it.
DSN ecosystem RFCs
  • RFC 6522: multipart/report container format
  • RFC 3463: Enhanced Mail System Status Codes (the X.Y.Z taxonomy)
  • RFC 3798 / RFC 8098: Message Disposition Notifications (MDN, sibling format)
  • RFC 5965: Feedback Reports (ARF, abuse complaint format)
  • RFC 5337: Internationalized DSN and MDN
  • RFC 6533: Internationalized DSN status codes
  • RFC 5321: SMTP DSN extension (NOTIFY, ORCPT, RET, ENVID parameters)
SMTPedia companion guides

Frequently asked questions

What is the difference between a DSN and a bounce message?

A bounce message is any email generated in response to a delivery failure. A DSN is the standardized, machine-readable format for bounces defined by RFC 3464. Most modern MTAs generate DSN-formatted bounces, but non-DSN bounces still exist (usually from older systems, non-standard MTAs, or custom bounce handlers). ESPs typically parse both DSN and non-DSN bounces via heuristics on the message body. The DSN parsing guide covers both cases.

How do I know whether a bounce is permanent or temporary?

Read the Status field of the machine-readable delivery-status part. The first digit indicates persistence: 5 is permanent (do not retry, address the underlying issue, typically add to suppression list for address errors), 4 is persistent transient (retry per your schedule until it becomes 5.x.x or delivered), 2 is success (only surfaced if NOTIFY=SUCCESS was requested). See Hard Bounce vs Soft Bounce for classification patterns.

Why do some bounces have both a 550 SMTP code and a 5.1.1 DSN code?

The 550 is the three-digit SMTP reply from the receiving server per RFC 5321; the 5.1.1 is the enhanced status code per RFC 3463 that adds semantic detail. Both codes are meant to be present in modern DSNs (RFC 5321 section 3.7.5 says servers advertising ENHANCEDSTATUSCODES should include both). The three-digit code tells you the class; the X.Y.Z code tells you the specific reason. Parse both, but prioritize the X.Y.Z code for classification because it is standardized across MTAs.

How does DSN relate to the DSN SMTP extension?

The DSN extension is defined across RFC 3461 (SMTP protocol side) and RFC 3464 (the message format itself). RFC 3461 defines the EHLO advertisement (DSN), the NOTIFY parameter on RCPT TO, and the RET and ENVID parameters on MAIL FROM. RFC 3464 defines the format of the resulting DSN message. The two together let a sender request specific reporting behavior and receive machine-readable results.

Why should DSN messages have an empty Return-Path?

To prevent bounce loops. If a DSN cannot be delivered (the sender’s mailbox is full or does not exist), the next MTA would generate a DSN of the DSN, which could bounce again, and so on. RFC 3464 (via RFC 5321 section 6.1) mandates that DSNs use a null envelope sender (MAIL FROM:<>), and receivers must not generate DSNs for messages that arrived with a null envelope sender. This breaks the loop at the second layer.

Are DSN messages ever generated at the MUA level like MDNs?

No. DSN is strictly an MTA-generated format for delivery status. Read-receipt-style feedback from mail clients uses the sibling MDN format per RFC 3798 / RFC 8098, which is different in generator (MUA not MTA), trigger (user action not delivery event), and payload (disposition types not action/status). They share only the outer multipart/report envelope from RFC 6522. See the side-by-side comparison table above.


About the Author

Alaa - SMTPedia author

Alaa · LinkedIn

Email infrastructure specialist with 8+ years of hands-on experience in SMTP, deliverability, and email verification. I’ve configured and troubleshot mail systems across Postfix, Exchange, and cloud relays, managed IP reputation and warmup campaigns, and built verification pipelines processing millions of addresses. My work spans DNS authentication (SPF, DKIM, DMARC, BIMI), bounce handling, blocklist monitoring, and compliance frameworks including CAN-SPAM and GDPR. I write every article on SMTPedia to give email professionals, developers, and marketers the accurate, RFC-grounded reference they need.


About SMTPedia

SMTPedia is an independent email industry reference covering SMTP, IMAP, POP3, email deliverability, marketing platforms, DNS authentication, and email verification. Every article is researched from official provider documentation, IETF RFCs, and industry best practices. Settings and configurations are verified quarterly.

We are cited as a source by ChatGPT, Microsoft Copilot, and thousands of email professionals worldwide. Learn more about our editorial process.