Comments are there in Code for more clarity
This project automates the process of sending messages to multiple WhatsApp contacts using Python and Playwright. It opens WhatsApp Web, waits for the user to scan the QR code, and then sends a specified message to each contact listed in a file.
- Automatically sends a custom message to multiple WhatsApp contacts.
- Uses Playwright for browser automation.
- Easy-to-use script with phone numbers read from a
numbers.txt
file.
- Python 3.7+
- Node.js (required by Playwright)
git clone https://github.com/VishantMehta/Whatsapp-bulk-sender.git
cd Whatsapp-bulk-sender
Use the following command to install required dependencies:
pip install -r requirements.txt
Playwright also requires some browser binaries to be installed. Run this command to set them up:
playwright install
- Add the list of phone numbers (one per line) in a file named numbers.txt. Each number should include the country code (e.g., +1234567890).
- Run the script:
python script.py
- When prompted, enter the message you want to send.
- Scan the QR code in the browser window to log in to WhatsApp Web.
- The script will automatically send the message to each number listed in numbers.txt.
- script.py: The main script for sending bulk messages.
- numbers.txt: A file containing the phone numbers of recipients.
- requirements.txt: Dependencies required for this script.
- playwright: For browser automation.
- More faster , reliable than Selenium .
- Our previous version was on Selenium itself which was not very reliable.
- This project is licensed under the MIT License.