2

I've been looking for documentation on the standard behaviour for mail servers who fail to deliver their mail.

I want the 'From' field to be different from the account that receives emails when there is a delivery failure.

E.g.

My program sends an email from 'donotreply@example.com', and on failure to deliver I want to be sent the delivery failure bounceback at 'failedemails@example.com'.

Is this accomplished by setting the reply-to? Or should I login with the 'failedemails' account and therefore it will receive the email back?

Thanks.

Ryan Weir
  • 6,377
  • 5
  • 40
  • 60

1 Answers1

1

There are several things you can try, but I think that bounces are typically going to be sent to the envelope sender. This means that sending the mail from donotreply@example.com using your failedemails account is probably your best bet.

You can also try these headers:

Reply-To: failedemails@example.com
Errors-To: failedemails@example.com
Return-Path: failedemails@example.com

A similar question was also asked here: Set email headers so bounced emails go to a specific address

Community
  • 1
  • 1
jncraton
  • 9,022
  • 3
  • 34
  • 49