I assume that isnt your .env? The error says smtp.gmail.com but your .env does not contain that?
Did you forget to clear cache ? php artisan config:clear
Hello Friends I want to ask about the GoDaddy server email configuration in laravel 8
My Configuration:
MAIL_MAILER=sendmail
MAIL_HOST=example.com
MAIL_PORT=465
[email protected]
MAIL_PASSWORD=[MY_PASSWORD]
MAIL_ENCRYPTION=tls
[email protected]
THE ERROR:
Connection could not be established with host smtp.gmail.com :stream_socket_client(): unable to connect to tcp://smtp.gmail.com:587 (Connection timed out)
config/mail.php
'mailers' => [
'smtp' => [
'transport' => 'smtp',
'host' => env('MAIL_HOST', 'smtp.mailgun.org'),
'port' => env('MAIL_PORT', 587),
'encryption' => env('MAIL_ENCRYPTION', 'tls'),
'username' => env('MAIL_USERNAME', 'USERNAME'),
'password' => env('MAIL_PASSWORD', 'PASSWORD),
'timeout' => null,
'auth_mode' => null,
],
'ses' => [
'transport' => 'ses',
],
'mailgun' => [
'transport' => 'mailgun',
],
'postmark' => [
'transport' => 'postmark',
],
'sendmail' => [
'transport' => 'sendmail',
'path' => '/usr/sbin/sendmail -bs',
],
'log' => [
'transport' => 'log',
'channel' => env('MAIL_LOG_CHANNEL'),
],
'array' => [
'transport' => 'array',
],
],
Please or to participate in this conversation.