On the XS plan, outgoing port 25 is closed; you can still send mail, just not directly from the VPS on that port.
Steps
Port 25 is closed on the Smart VPS XS plan. The other Smart VPS plans don't list that restriction on our website. To check your plan, log in to https://noc.versaweb.com, click Services, then Smart VPS Servers. The plan code appears under the product name, for example vps.amd.xs is XS.
- Choose a mail relay, which is a service that sends mail for you. Any provider that offers authenticated SMTP on port 587 or 465 works. Your email host or a transactional mail service are the usual picks.
- Collect the relay's SMTP host name, port (587 or 465), username, and password.
- Point your software at the relay. In your app's mail settings, set the SMTP host, port, and credentials, and choose TLS or STARTTLS as the provider documents.
- If you run Postfix on the VPS, set
relayhost = [smtp.provider.example]:587in/etc/postfix/main.cfand add the login in asasl_passwdfile. Also add these lines tomain.cf:smtp_sasl_auth_enable = yes,smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd,smtp_sasl_security_options = noanonymousandsmtp_tls_security_level = encrypt. Then runpostmap /etc/postfix/sasl_passwdandsystemctl reload postfix. - Send a test message to an address you control. Check the headers if it lands in spam.
- Publish SPF and DKIM records for your domain as your relay provider instructs. They matter more than the port.
Receiving mail on port 25 is a separate question. If you need inbound mail on your VPS, ask us (see below).
If it didn't work
- To test whether outbound port 25 is open from your VPS, run
timeout 5 bash -c '</dev/tcp/gmail-smtp-in.l.google.com/25' && echo open || echo closed. - Test the relay connection from the VPS:
openssl s_client -starttls smtp -connect smtp.provider.example:587. - Check your provider's log for authentication errors.
- To ask about port 25 on your plan, or about inbound mail, open a ticket under Technical Support with your IP address and plan name.