Skip to content
Karl Dahlke edited this page Dec 7, 2023 · 7 revisions

SMS Messaging (AKA Texting) with Edbrowse

Written by Karl Dahlke.

My three kids are often not near their computers, but I like to stay in touch with them in real time, and texting is the perfect way to do that. We happen to be on sprint, which works really well. If my daughters number is 2485551111, then I text her by sending email to

2485551111@messaging.sprintpcs.com

Because of the way edbrowse works, every mail out has to have a subject line, but if there are no words after "subject:" then the generated email has no subject. This is appropriate when sending a text. The body of the message contains the text, but it is cut off at 120 characters, so be brief. (Not sure what causes the character limit.) Use sm- to suppress the .signature file. It would probably be cut off anyways.

When she replies it could come from the same address, or sometimes from this address if she has a smart phone:

2485551111@pm.sprint.com

These are good lines to have in your address book.

# text to my daughter Beth and get replies therefrom
bethtxt:2485551111@messaging.sprintpcs.com
bethpm:2485551111@pm.sprint.com

AT&T is just as easy: 2485551111@txt.att.net. Other companies that use the AT&T network, such as Consumer Cellular, work the same way. However, on some phones these text messages do not thread properly - they do not come from one source email address and are not grouped together in a thread. Sending to mms.att.net often solves this problem, although such texts count as data, rather than traditional texts. Boost Mobile clients can use 2485551111@sms.myboostmobile.com, and so on. I'm not in the business of keeping up with all the carriers, so this page is your friend. It gives you the wireless company and the email gateway that you need to send and receive texts.

[https://www.carrierlookup.com/]

Beware though, it has a captcha.

The following function sends and then discards a text, assuming you don't want to keep it any more.

  • is important here; if it doesn't send you might want to try again later. This assumes one or more recipients and one line of text. Subject: is inserted before sending, because edbrowse requires a subject line even if it is empty.

    function+text {

    Send a text and quit.

      $-1s/$/\nSubject:/
      sm-
      bw
      q
    

    }

Fine - but this doesn't work if the text has nonascii characters or emojis etc. I don't know why. This function is more general, and supports utf8 characters.

function+text {
#  Send a text and quit.
    $-1s;$;\nalt:/home/eklhad/kprs/ebsys/textalt.html\nSubject:;
    sm-
    bw
    q
}

The alternate html presentation is a file with the single line: "You shouldn't see this." The plain text is sent on to the texting system, and the utf8 characters are preserved. The html section is ignored. I have verified this for T Mobile and Sprint, not sure about other carriers.