'href link to send text message?

Is there a link similar to <a href="tel:..."> for text messages. The behavior would be similar but instead of calling the number it would prompt the user to send a text?



Solution 1:[1]

try using this:

 <a href="sms://+14035550185?body=I%27m%20interested%20in%20your%20product.%20Please%20contact%20me.">Send a SMS message</a>

You can use the body parameter to queue a message in the text.

Solution 2:[2]

The basic format of text messages link is

<a href="sms:...">

Solution 3:[3]

On my Mac, latest OS, simply opens Messenger and I have to type everything, phone, message, etc. Better than nothing but does not pre-load the number or message. It does deliver the message.

Is there some (html/php?) code to actually do this as with email, e.g., by looking up recipient in a directory? That would require only typing (or perhaps speaking on a phone) the message. Could do but hate to rediscover the wheel.

Solution 4:[4]

WhatsApp provides an option to send text.

<a href="whatsapp://send?text=The text to share!" data-action="share/whatsapp/share">Share via Whatsapp</a>

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1
Solution 2
Solution 3 Arctangent
Solution 4 marcobiedermann