skip to Main Content

I’m trying to use the mailer service to send emails through Symfony. As my website is hosted on hostinger as well as my domain I am following the following pattern in the .env file


###> symfony/mailer ###
MAILER_DSN=smtp://[email protected]:[email protected]:465
###< symfony/mailer ###

When executing the test command "php bin/console mailer:test [email protected]" I am getting the following response:

In SmtpTransport.php line 333: Expected response code "250/251/252" but got code "550", with message "550 5.7.27 [email protected]: Sender address rejected: Domain example e.org does not accept mail (nullMX)".

I don’t know what to do because everything seems to be configured correctly

2

Answers


  1. hosting sites normally have mail SMTP port blocked or reserved for their internal mail services.

    Be sure that port 25, 587 and/or 465 are open, depending on which are you using or your hosting provider blocked.

    Login or Signup to reply.
  2. DNS domain example.org specified via its MX DNS record that it DOES NOT accept incoming emails.
    It makes email server you use reject envelope sender with example.com domain because example.org will not accept (eventual) bounce messages/emails.

    see RFC-7505 : A "Null MX" No Service Resource Record for Domains That Accept No Mail

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search