1001Ferramentas
💬Utilities

SMS Link Builder

Builds sms: links with phone number and optional message body, ready for mobile apps and pages.



  

SMS links that open with text prefilled

You want a Text us button on a landing page and immediately hit the syntax question: is it sms:+15551234567?body= or &body=? Then the message picks up a space, an apostrophe or an accent and the link falls apart halfway through. It works on your Android, you ship it, and someone on an iPhone reports an empty compose screen. This builder writes the form both platforms accept.

Two fields: phone and message. The phone runs through a filter that keeps only digits and the plus sign, so parentheses, dashes and spaces drop out on their own. The message goes through encodeURIComponent, turning Hello there! into Hello%20there%21. Leave the message empty and the ?body= part disappears from the output entirely. Everything is rebuilt as you type, right in the page.

Write the number in international form, with the plus sign and country code, since that travels best across carriers. Test on a real handset, because desktop browsers usually ignore sms: links altogether. And remember the link sends nothing on its own. It opens the messaging app with recipient and text filled in, and the person still has to hit send, on their own plan. Bulk campaigns need a real gateway instead.

Frequently asked questions

Does it work on both iPhone and Android?
Both open the messaging app. The ?body= parameter is honored by Android and by current iOS; very old iOS builds expected ;body= instead. Test on a device before you publish.
Can I add more than one recipient?
Not here. The filter keeps digits and the plus sign only, so a comma between two numbers vanishes and the numbers run together. Build one link per recipient.
Will the link send the message by itself?
No. It prefills the number and the text in the messaging app; the person still taps send, and the message goes out on their own plan.

Related Tools