Article ID: 125081, created on Apr 2, 2015, last review on Aug 20, 2016

  • Applies to:
  • Plesk 12.0 for Linux
  • Plesk 11.5 for Linux
  • Plesk 12.0 for Windows
  • Plesk 11.5 for Windows


Default Return-Path for PHP mail script is taken as server administrator mail address.

How to specify exact default Return-Path for PHP Mail Script?


According to PHP documentation:


        Which "From:" mail address should be used in mail sent from PHP under Windows. This directive also sets the "Return-Path:" header.

It can be defined server-wide. PHP mail() function takes Return-Path value from the parameter sendmail_from defined in server php.ini.

  • For Linux:

    grep sendmail_from `/etc/php.ini`
    sendmail_from =
  • For Windows:

        type "%plesk_dir%Additional\PleskPHP5\php.ini" | findstr sendmail_from
    ;sendmail_from =
    sendmail_from =

To define Return-Path parameter for a particular domain, specify it in custom PHP settings for the domain:

   **Home > Domains > > Websites & Domains > PHP Settings > Additional directives**

The parameter can be defined as in the example below:

sendmail_from = 

Authentication-results parameter can be set by including in php.ini (for Linux, the default "From" field can be overriden for the outgoing emails):

sendmail_path = "/usr/sbin/sendmail -t -i"

Search Words

default Return-Path


Return-Path for php mail

Postfix config

return path


ed7be2b984f9c27de1d2dc349dc19c6d 56797cefb1efc9130f7c48a7d1db0f0c a914db3fdc7a53ddcfd1b2db8f5a1b9c 85a92ca67f2200d36506862eaa6ed6b8 a766cea0c28e23e978fa78ef81918ab8 29d1e90fd304f01e6420fbe60f66f838 01bc4c8cf5b7f01f815a7ada004154a2 0a53c5a9ca65a74d37ef5c5eaeb55d7f 46a8e394d6fa13134808921036a34da8 bd7fc88cf1b01f097749ae6f87272128 2a5151f57629129e26ff206d171fbb5f e335d9adf7edffca6a8af8039031a4c7

Email subscription for changes to this article
Save as PDF