Doing mail from Terminal is not as hard as you may think.

To send an email from your computer just open Terminal and type the following command:

Replace “Subject” with the subject of the mail messages that you are sending. You’ll then replace “” with the email address of the recipient of the message. Finally, to write your message, include the <<EOF, do not forget the enter, then type your message using as many newline characters as needed. When you are ready to stop writing and send your message, type “EOF” followed by the enter key.

This will cause OS X to relay the message to your ISP’s SMTP server, and send the message to the recipient that you specified.

If you get an Error like:

Then you have to do a little more work like this:

You didn’t get any mail still then now you will have to setup Google as your SMTP server?

Configure Postfix for Gmail SMTP
Edit file /etc/postfix/

Generate sasl_password if not already exists

and enter in the following:

Run the following commands

I was trying to see if my port 25 was open so I used this command

A cool way to to see what ports are open with grep

Thats It enjoy what is built-in to your Mac!