How to Send WhatsApp Message from Excel Sheet: A Step-by-Step Guide

Sending WhatsApp messages from an Excel sheet might sound like a techie task, but it’s actually quite simple. By using a bit of VBA (Visual Basic for Applications) code and the WhatsApp API, you can automate the process of sending messages directly from your spreadsheet. This guide will walk you through the steps needed to set it up and send messages efficiently.

How to Send WhatsApp Messages from an Excel Sheet

We’ll guide you through a few simple steps to send WhatsApp messages directly from an Excel sheet. With these steps, you’ll be able to automate the message-sending process, making it easy to reach out to multiple contacts quickly.

Step 1: Prepare Your Excel Sheet

First, organize your data in the Excel sheet. Include columns for phone numbers and messages.

This step is all about setting the stage. Make sure each column is clearly labeled. For example, Column A can be for phone numbers and Column B for messages. This layout ensures that your VBA code can easily reference the correct data.

Step 2: Install WhatsApp Web on Your Browser

Open WhatsApp Web on your browser by visiting

Using WhatsApp Web is crucial because it allows the browser to interact with your WhatsApp account. Scan the QR code with your phone to log in.

Step 3: Enable Developer Tools on Your Browser

Press F12 or right-click on the browser and select ‘Inspect’ to open Developer Tools.

Developer Tools will help you inspect web elements and execute scripts. This feature is essential for interacting with the web page directly.

Step 4: Write Your VBA Code

Open Excel, press ALT + F11 to open the VBA editor, and then insert a new module with this code:

Sub SendWhatsAppMessages()
    Dim IE As Object
    Set IE = CreateObject("InternetExplorer.Application")
    IE.Visible = True
    For i = 2 To Sheet1.Cells(Rows.Count, 1).End(xlUp).Row
        phone = Sheet1.Cells(i, 1).Value
        message = Sheet1.Cells(i, 2).Value
        IE.Navigate "" & phone & "&text=" & message
        Application.Wait Now + TimeValue("00:00:05")
        SendKeys "~"
        Application.Wait Now + TimeValue("00:00:05")
    Next i
End Sub

This code snippet allows VBA to interact with Internet Explorer, navigate to WhatsApp Web, and send messages. Modify the time delays if needed to ensure WhatsApp has enough time to load properly.

Step 5: Run the VBA Code

Press F5 to run the code in the VBA editor.

Running the code executes the instructions line by line. If everything is set up correctly, you’ll see the browser open and messages being sent one by one.

After completing these steps, your WhatsApp messages will be sent directly from your Excel sheet to the listed contacts.

Tips for Sending WhatsApp Messages from an Excel Sheet

  • Make sure all phone numbers are correctly formatted with the country code.
  • Always double-check your message content before running the script.
  • Test with a small group of contacts first to ensure the process works smoothly.
  • Adjust the time delays in the VBA code if messages are not sending correctly.
  • Save your Excel sheet frequently to avoid losing any data.

Frequently Asked Questions

Can I use browsers other than Internet Explorer?

Yes, but you may need to adjust the VBA code to support other browsers.

Is it possible to attach files in these messages?

Currently, the VBA code supports only text messages. File attachments would require more advanced scripting.

Do I need any special permissions to use WhatsApp API?

No, but you need to be logged into WhatsApp Web for the script to work.

Can I send messages to groups?

Yes, but you’ll need the group ID instead of a phone number.

What if my WhatsApp Web session expires?

You’ll need to re-scan the QR code to log in again.


  1. Organize data in the Excel sheet.
  2. Open WhatsApp Web.
  3. Enable Developer Tools.
  4. Write and insert VBA code.
  5. Run the VBA code.


Sending WhatsApp messages directly from an Excel sheet can save you a lot of time and effort, especially if you need to reach out to multiple contacts. While the process might seem a bit technical at first, once you get the hang of it, it’s as easy as pie. With a simple VBA script and some basic setup, you can automate your messaging tasks and streamline your communication.

Remember, automation is a powerful tool, but always use it responsibly. Double-check your messages for accuracy and ensure that you’re complying with privacy laws and WhatsApp’s terms of service. If you’re not familiar with VBA or coding, don’t worry—there are plenty of resources and communities online to help you get started.

So, why not give it a try? The next time you need to send out a bunch of WhatsApp messages, you’ll be glad you took the time to set this up. Happy messaging!

Get Our Free Newsletter

How-to guides and tech deals

You may opt out at any time.
Read our Privacy Policy