I\'ve been trying for a whlie on this, and have so far been failing miserably. My most recent attempt was lifted from this stack code here: Sending email through Gmail SMT
I implemented an email client sometime back that could talk to gmail on both 587 and 465...
Port 25 is the normal unencrypted pop port; not available on gmail.
The other two ports have encryption; 587 uses TLS, 465 uses SSL.
To use 587 you should set SmtpClient.EnableSsl = true.
465 wont work with SmtpClient, it will work with the deprecated class SmtpMail instead.