Host = $config['mail_server']; $mail->Port = $config['mail_port']; $mail->Username = $config['mail_user']; $mail->Password = $config['mail_password']; $mail->From = $config['mail_address']; $mail->FromName = 'Mailer'; $mail->addAddress('test@joethei.de', 'Joe User'); $mail->Subject = 'Here is the subject'; $mail->Body = 'This is the HTML message body in bold!'; try { !$mail->send(); } catch (\PHPMailer\PHPMailer\Exception $e) { echo $e; }