Fill Forms Automatically
Fill web forms automatically by mapping your data to fields dynamically without selectors

TypeScript
Source codenpx create-browser-app --template form-filling
Python
Source codeuvx create-browser-app --template form-filling
Automate form filling without brittle selectors
Fill web forms reliably without hard-coding selectors. This template analyzes form fields, matches your data to the right inputs, and fills them dynamically, making automations more durable across different layouts. Perfect for lead capture, QA testing, bulk registrations, and survey submissions.
Steps
- Create a Browserbase session and navigate to the form URL.
- Stagehand scans the page to detect all input fields and build a field schema.
- Provide your data object (e.g., name, email, company), and Stagehand maps values to the right fields.
- The script fills inputs, handles validation, and submits the form.