Remember to check the spam folder. Using sendmail like that can easily result in the email ending up there
Also make sure you actually have sendmail in that path. Run it in a terminal
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
I need to use php mail() function to send mail to users. here env
MAIL_MAILER=sendmail
MAIL_SENDMAIL='/usr/sbin/sendmail -t -i'
MAIL_HOST=
MAIL_PORT=
MAIL_USERNAME=null
MAIL_PASSWORD=null
MAIL_ENCRYPTION=null
MAIL_FROM_ADDRESS=null
MAIL_FROM_NAME="${APP_NAME}"
here config mail
'default' => env('MAIL_MAILER', 'sendmail'),
'sendmail' => [
'transport' => 'sendmail',
'path' => env('MAIL_SENDMAIL_PATH', '/usr/sbin/sendmail -t -i'),
],
but no mail send into user gmail inbox. what are missing here can you help me
@kyawswar change your env
MAIL_SENDMAIL='C:\xampp\sendmail\sendmail.exe -t -i'
Please or to participate in this conversation.