You may send a SMS text message to any SMS-supporting cellular phone (e.g., iPhone) or device for free (and without ads), from the command line. To do this, you need TextBelt. TextBelt is a very simple, outgoing SMS API that uses carrier-specific gateways to send messages.
To send an SMS (text message) from OS X command line to a cellular phone or device:
1.Launch Terminal
2.Enter the following Terminal command:
curl “http://textbelt.com/text” -d number=1234567890 -d “message=this is where you put your message”
Like this:

If your message is delivered successfully, you will get:
{“success”:true}
If not, you will get an error message, like these:
{“success”:false,”message”:”Exceeded quota for this phone number.”}
(note TextBelt allows maximum 75 outgoing messages per day)
or
{“success”:false,”message”:”Invalid phone number.”}
Related: How to tell if you’re sending an iMessage or a text message (SMS)