Sending SMS Text Messages From Excel
Sending SMS Text Messages From Excel
In this post we are going to learn how to send SMS text messages from Excel… because why not?
Yep, Excel can do pretty much everything, and that now includes sending texts.
But here’s the deal.
This is going to cost a little bit of money unless you just want to send texts to yourself, in which case you can use a trial account. But it’s actually probably cheaper than most pay as you go phone plans for texting.
The whole setup is going to use Microsoft’s Flow Excel add-in and Twilio.
We’ll also need to have an Office 365 Business account in order to save Excel workbooks to OneDrive for Business.
Install The Microsoft Flow Excel Add
The first thing we’ll need to do is install the Microsoft Flow Excel add-in.
This is done from the Home tab of the ribbon and clicking on the Get Add-ins command. Click on the top part of the button as the lower part will only show recommended add-ins.
- Go to the Microsoft Store.
- Search for Microsoft Flow.
- Press the Add button for the Microsoft Flow for Excel add-in.
Warning, this add-in is in preview as of now, so it can be a little laggy and buggy. It was for me.
After adding the add-in, it will appear in the Data tab.
Get Your Microsoft Flow Account Set Up
The next thing we’re going to need is a Microsoft Flow account.
If we head over to https://flow.microsoft.com, we can sign up for an account. Check out my post on sending emails from Excel with Microsoft Flow for more details on this.
Get Your Twilio Account Set Up
The last piece of the puzzle is getting our Twilio account.
We can go to https://www.twilio.com/ and sign up for an account and fill in the usual details to complete the process.
Once we create an account, we can go to the console to set up our phone number and upgrade our account.
Whether we are just trying out the trial account or upgrading, we will also need a Twilio phone number to send texts from.
- Go to the # section in the console.
- Click on Getting Started and then choose Get Started.
- Then click on the big button that says Get your first Twilio phone number.
Now we have our phone number which can send and receive SMS text messages!
Upgrade Your Twilio Account
Now, this is an optional step… But if we don’t upgrade, then we will only be able to send texts to verified phone numbers.
Verify any phone numbers in the console.
- Go to the # section in the console.
- Go to Verified Caller IDs.
- Click on the Plus Sign icon.
We can fill in the details and Twilio will either call or text a code we can use to verify the phone number.
If we want to use the full capabilities and be able to text any number, then we’re going to have to pay at least $20 to upgrade the account. This $20 dollars is used for pay as you go credit towards messages sent. Currently the rate is $0.0075 to send or receive a message.
Get Your Twilio Account SID And Authorization Token
Now that everything is set up in Twilio, we will need to take note of the account SID and the authorization token (auth token).
- Go to the Home section of the console and click on the Dashboard heading.
- Take note of the ACCOUNT SID.
- Take note of the AUTH TOKEN.
These are the credentials we will need so that Microsoft Flow can connect to and use our Twilio account to send and receive texts.
Open The Flow Add-In From Excel And Sign In
Now we’re ready to head back into Excel! We need to make sure our workbook is saved in OneDrive for Business as we can only create flows for workbooks saved to either SharePoint or OneDrive for Business.
Go back to the Data tab and click on the Flow add-in to open up the Flow window pane. Then we can sign into our flow account.
Create A New Blank Flow
Now scroll down the Flow window and click on Create a flow from blank.
The only trigger event available in the flow add-in will be For a selected row, complete a custom action. Press the Continue button to proceed.
In the workbook we have a table named Texts which contains contact details including names and numbers.
In the trigger step, we need to add the location of our file and the table which has our contact details. This is the table which we will be using to send text messages from.
Now we can add a New Step after the trigger.
We can add our action to perform after the trigger event is detected. Search for Twilio and select the Send Text Message (SMS)
action.
We can add our Twilio account credentials. Pick any name as the Connection Name, then add the ACCOUNT SID and AUTH TOKEN.
We will now be able to set up our Twilio SMS text message action.
- Select our Twilio phone number to send text messages from.
- Select the To Phone Number. This is the phone number to send a text to. In our case, we will use the phone number from our contacts table and reference it by the parameter from the selected row step of the flow.
- Create the Text to send as a message. In our case, the message will be dynamic and will reference the name parameter from our contacts table in the selected row step of the flow.
- Give our flow a name.
- Press the Save button.
With this flow in place, we will be able to select rows in our contact table and send those contacts SMS texts. Fun stuff!
Another option, would be to create a message column in our table. Then we can create the message in Excel and reference it with a parameter in the Text field just like we did with the name field.
Using The Flow And Sending Texts
Now that we’ve got everything set up, we can start sending texts.
Select the rows in the table to which you want to send a text. Then head over to the flow window pane and press the play button on your newly created flow.
The first time we run it, Flow will tell us it will connect to Excel Online and Twilio and we can press the Continue button to confirm this is ok and run the flow.
It seems to take a while for created flows to propagate into the Excel desktop Flow add-in. But they are almost instantly available if we use Excel online instead.
Once the flow runs, the recipients will get their messages nearly instantly.
Conclusions
We were able to set up texting from Excel pretty easily using the flow add-in and Twilio.
The flow we created was very basic and only had a trigger and one action. With a little imagination and combining other triggers and actions, the possibilities are endless!
Just remember, no spamming people. But maybe a few prank texts to your friends is ok
Leave a Comment