Setting the From: Address

A From: address is required and is set with the setFrom() method of the message.

From: addresses specify who actually wrote the email, and usually who sent it.

What most people probably don't realise is that you can have more than one From: address if more than one person wrote the email – for example if an email was put together by a committee.

To set the From: address(es):

Call the setFrom() method on the Message.

The From: address(es) are visible in the message headers and will be seen by the recipients.

Note: If you set multiple From: addresses then you absolutely must set a Sender: address to indicate who physically sent the message.
  
//Set a single From: address
$message->setFrom('your@address.tld');

//Set a From: address including a name
$message->setFrom(array('your@address.tld' => 'Your Name'));

//Set multiple From: addresses if multiple people wrote the email
$message->setFrom(array(
  'person1@example.org' => 'Sender One',
  'person2@example.org' => 'Sender Two'
));

NOTE: Documentation for version 3 is in the wiki.