Manual:$wgSMTP

Details
For using a direct (authenticated) SMTP server connection, you need to fill an array. Set to false (the default value) to use the built-in PHP mail function.

For example:

$wgSMTP = array( 'host'     => "localhost",  'IDHost'   => "domain for MessageID",  'port'     => 25,  'auth'     => false,  'username' => "my_user_name",  'password' => "my_password" );

See Mail::factory for a full description of these settings. (Scroll down to the  parameter.) Warning: This setting requires PEAR's Mail package to be installed (run "pear install MAIL").