I build wordpress website with aws lightsail hosting.
I bought my domain in GoDaddy and created custom email with the domain (info@myDomain.com) – myDomain is just for the explanation.
I’m trying to configure contact form and send emails to this email.
so what I did is installed WP Mail SMTP and configure the settings.
into settings what I set is
I saved the settings and send email test – I’m getting the error
There was a problem while sending the test email.
Versions:
WordPress: 5.8.2
WordPress MS: No
PHP: 7.4.25
WP Mail SMTP: 3.2.1
Params:
Mailer: smtp
Constants: No
ErrorInfo: SMTP connect() failed. https://github.com/PHPMailer/PHPMailer/wiki/Troubleshooting
Host: relay-hosting.secureserver.net
Port: 25
SMTPSecure: string(0) ""
SMTPAutoTLS: bool(false)
SMTPAuth: bool(false)
Server:
OpenSSL: OpenSSL 1.1.1d 10 Sep 2019
Debug:
Email Source: WP Mail SMTP
Mailer: Other SMTP
SMTP connect() failed. https://github.com/PHPMailer/PHPMailer/wiki/Troubleshooting
SMTP Debug:
2022-01-05 09:27:56 Connection: opening to relay-hosting.secureserver.net:25, timeout=300, options=array()
2022-01-05 09:28:27 Connection failed. Error #2: stream_socket_client(): unable to connect to relay-hosting.secureserver.net:25 (Connection timed out) [/opt/bitnami/wordpress/wp-includes/PHPMailer/SMTP.php line 388]
2022-01-05 09:28:27 SMTP ERROR: Failed to connect to server: Connection timed out (110)
SMTP connect() failed. https://github.com/PHPMailer/PHPMailer/wiki/Troubleshooting
I tried more different smtp hosts:
- smtpout.secureserver.net with port 465/587
- https://email.secureserver.net
- myDomain-com.mail.protection.outlook.com
nothing helped – I get the same error.
in GoDaddy I found this for my domain
I talked with GoDaddy customer service for over then 3 hours- they didn’t know how to help me.
I read some tutorials such as:
https://il.godaddy.com/en/help/send-form-mail-using-an-smtp-relay-server-953
I still looking for any answer.
how to configure the right SMTP with those services GoDaddy – wordpress – Aws Lightsail?
2
Answers
From Remove port 25 restriction from your Lightsail instance:
You will need to request for the restriction to be removed.
Alternatively, connect to an SMTP server via a different port (which is common when using TLS).
As Lightsail blocks outbound traffic on port 25. tried port number 2525.