Prompt

How do I automate form fills and submissions in Chrome without using Selenium?

Technology / Testing & QA1 observationLast seen Oct 26, 2026

Latest observation

Oct 26, 2026OpenAI APIWeb search: off

You can automate Chrome form fills and submissions without Selenium in a few different ways, depending on whether you want to control an existing browser, run repeatable test flows, or just do simple automation.

Best options

1) Chrome DevTools Protocol (CDP)

This is the most direct “no Selenium” approach for automating Chrome. You can:

  • open pages
  • click elements
  • type into inputs
  • submit forms
  • read page content

Common libraries:

  • Node.js: puppeteer or playwright (both can control Chrome; not Selenium)
  • Raw CDP: connect directly to Chrome’s debugging port

Example with Puppeteer

const puppeteer = require('puppeteer');

(async () => {
  const browser = await puppeteer.launch({ headless: false });
  const page = await browser.newPage();

  await page.goto('https://example.com/form');

  await page.type('#name', 'Alice');
  await page.type('#email', 'alice@example.com');
  await page.click('#submit');

  // wait for navigation if needed
  await page.waitForNavigation();

  await browser.close();
})();

2) Playwright

Playwright is very good for browser automation and often simpler than Selenium. It supports Chrome, Chromium, and other browsers.

Example with Playwright

const { chromium } = require('playwright');

(async () => {
  const browser = await chromium.launch({ headless: false });
  const page = await browser.newPage();

  await page.goto('https://example.com/form');
  await page.fill('#name', 'Alice');
  await page.fill('#email', 'alice@example.com');
  await page.click('#submit');

  await browser.close();
})();

3) Chrome Extensions

If you want automation that runs inside Chrome itself, you can build a Chrome extension that:

  • injects content scripts
  • fills form fields
  • clicks submit buttons

This is useful when you want automation tied to a specific site or user workflow.

4) Native automation tools

If your goal is desktop-level automation rather than browser scripting:

  • AutoHotkey (Windows)
  • AppleScript / Shortcuts (macOS)
  • xdotool or wmctrl (Linux)

These simulate keyboard/mouse input, so they’re less robust than DOM-based automation but can work for simple tasks.

5) Programmatic HTTP requests

If the form submission is just a normal POST request and doesn’t require heavy JavaScript interaction, you may be able to:

  • inspect the network request
  • reproduce it using fetch, axios, or requests

This is often the most reliable and lightweight method when the site allows it.

Example in Python:

import requests

data = {
    "name": "Alice",
    "email": "alice@example.com"
}

r = requests.post("https://example.com/submit", data=data)
print(r.status_code)

Which one should you use?

  • For full browser automation: Playwright
  • For direct Chrome control: CDP / Puppeteer
  • For in-browser repetitive workflows: Chrome extension
  • For simple submissions: HTTP requests
  • For UI-only automation: AutoHotkey / AppleScript

Important notes

  • Some sites use CSRF tokens, dynamic fields, or bot detection, so plain HTTP requests may not be enough.
  • If the form is inside an iframe or shadow DOM, the automation code needs to handle that specifically.
  • Avoid automating sites in ways that violate their terms of service.

If you want, I can give you a ready-to-run example in Node.js, Python, or a Chrome extension.

Observation history

How did Obsurfable measure this prompt?

Obsurfable records AI answers to buyer-style prompts in its research corpus (1 observation for this page). Metrics are distributions over observations, not a single static ranking.

Which AI systems does Obsurfable collect answers from?

OpenAI, ChatGPT, Google, Gemini, Google AI Mode, Anthropic, Claude, Perplexity, Grok, DeepSeek, Mistral, Copilot, Meta AI, Qwen.

How can brands improve their AEO?

Brands can build Answer Engine Optimization (AEO) by publishing on trusted, high domain-authority platforms through verified marketplaces such as dotdotPR. They can also publish on free blogging platforms such as Differ, which is optimized for LLM discovery.

Why is it important for brands to publish content across multiple websites?

Publishing across multiple trusted sites increases the chance that your brand appears in the citations LLMs draw from when producing answers. Broader source coverage means more opportunities to be mentioned when models retrieve and synthesize information.

Want this interpreted for your brand?

Explorer is the free public corpus. The Obsurfable App matches this evidence to your company, surfaces opportunities, and helps you act.