What's the correct SMTP server for Gmail when using skpsmtpmessage?

Hey everyone, I’m having trouble with the skpsmtpmessage project. I want to send emails using Gmail, but I can’t figure out the right relay host.

I’ve tried these servers:

But my program keeps giving me an ‘Unable to connect server’ error. Can anyone help me out? What’s the correct SMTP server for Gmail these days?

I’ve already updated all the email addresses to Gmail ones in my code. Just need to sort out this server issue. Thanks in advance for any tips!

I’ve been using skpsmtpmessage with Gmail for a while now, and I can confirm that smtp.gmail.com is indeed the correct SMTP server. However, there are a few other things you need to consider:

  1. Make sure you’re using port 587 for TLS or 465 for SSL.
  2. Enable ‘Less secure app access’ in your Google account settings, or better yet, use an app-specific password.
  3. Double-check your username and password.

If you’re still getting connection errors, it might be worth checking your firewall settings or network restrictions. Sometimes corporate networks block these ports.

Also, Google has been tightening security recently. You might want to look into using their OAuth 2.0 for authentication instead of plain username/password. It’s a bit more work to set up, but it’s more secure and reliable in the long run.

Hope this helps you get things working!

yo, smtp.gmail.com is the right server, but u might need to tweak some stuff. make sure ur using port 587 or 465, and check ur google account settings. sometimes u gotta turn on ‘less secure app access’ or make an app password. also, double-check ur login info. good luck man!

The correct SMTP server for Gmail when using skpsmtpmessage is indeed smtp.gmail.com. However, your connection issues might stem from other factors. Ensure you’re using the right port - 587 for TLS or 465 for SSL. Also, check your Google account settings. You may need to enable ‘Less secure app access’ or create an app-specific password.

If you’re still encountering problems, consider network restrictions or firewall settings that might be blocking the connection. As a last resort, you could try using Google’s API for sending emails instead of SMTP. It’s a bit more complex to set up, but it can be more reliable in some cases.

Remember to double-check your authentication details and make sure you’re using an up-to-date version of skpsmtpmessage. Good luck troubleshooting!