Sending Email Using Java

Sending Email Using Java

Here is the code to send email using Java. Here we are going to use gmail gateway to send emails.
Please follow these steps before you use this code:
1. Login your google account
2. In google search, search “Application-specific password”
3. Enter a label for your reference and select “generate password”
4. Copy that password and paste it in code at “//password here” line.

Tested in NetBeans 8.0



One thought to “Sending Email Using Java”

Leave a Reply

Your email address will not be published. Required fields are marked *