Building a Bulk Form Submitter with Playwright
Description and use
Automating contact form submissions on 120 sites using Playwright, cutting manual effort from hours to minutes.
Problem
Submitting a contact form on 120 construction company websites manually was infeasible.
Outcome
The script automates form submissions across 120 sites, reducing manual effort from hours to minutes.
Workflow
- Install Node.js dependencies: npm init -y, npm install playwright axios cheerio xlsx, npx playwright install chromium
- Read list of 120 website URLs
- For each URL: launch browser with Playwright
- Navigate to contact page
- Locate form fields (name, email, message) via selectors
- Fill fields with predefined data
- Submit the form
- Handle popups or cookie banners if present
- Log success or failure
- Close browser
Evidence
I had a list of 120 construction company websites. For each one, I needed to: Open the contact page, Fill in name, email, and message, Submit the form
First, install the dependencies: npm init -y npm install playwright axios cheerio xlsx npx playwright install chromium
- Record date: 2026-10-05T14:11:03.113Z