AI and automation
What is stealth mode in browser automation?
Stealth mode is a collection of patches, usually a plugin, that makes an automated browser look less like one: it hides the webdriver flag, fills in properties headless browsers lack, and smooths over other known giveaways.
The short answer
Automation frameworks leave fingerprints. Chrome under WebDriver or the DevTools Protocol sets navigator.webdriver to true, headless builds historically announced themselves in the user agent and lacked plugins, and certain objects are missing or inconsistent. "Stealth mode" is the common name for scripts that patch these properties before page scripts run. The best known example is the stealth plugin for puppeteer-extra; similar patch sets exist for Playwright and Selenium. Stealth lowers the chance of being flagged by simple checks. It does not make a browser undetectable.
What stealth patches typically change
| Tell | What a patch does |
|---|---|
navigator.webdriver is true | reports false or undefined, as a normal browser does |
| "HeadlessChrome" in the user agent | rewrites it to the regular Chrome string |
empty navigator.plugins and mimeTypes | adds plausible entries |
missing window.chrome runtime objects | creates the expected structure |
odd navigator.languages | sets a normal list matching Accept-Language |
| permissions API inconsistencies | makes notification permission answers coherent |
| WebGL vendor and renderer strings | replaces software renderer names with common GPU names |
These patches run as an init script on every new document, before the site's own code, so detection scripts see the patched values.
Why stealth is not invisibility
- Patches can be detected. Overridden properties sometimes behave subtly differently from native ones, for instance in how their functions stringify or where they sit in the prototype chain. Advanced scripts check for exactly that.
- Not everything is in JavaScript. The TLS fingerprint, HTTP/2 settings and IP reputation are outside the page and untouched by stealth.
- Consistency matters more than any single value. A patched Windows user agent on a Linux server with Linux fonts and a software GPU is still a mismatch.
- Behavior gives you away. Instant typing and perfectly straight mouse paths are not hidden by property patches.
- Arms race. Protection vendors study popular stealth plugins, and plugins lag behind browser releases. Check when the one you use was last maintained.
Modern headless changes the picture
Recent Chrome versions ship a "new" headless mode that runs the same browser code as headful Chrome, which removed several classic tells. Some patches in older stealth plugins are now unnecessary or even counterproductive, because they introduce inconsistencies a current browser would not have. Test your setup on a fingerprint inspection page with and without stealth, and keep only patches that fix a real difference. The comparison of headless and headful browsers explains the modes.
Where stealth helps
On sites with basic bot checks, a few patches plus a realistic window size and locale can be the difference between a blank page and a working session. It also helps reduce how often risk-based challenges appear. On sites using enterprise bot management, stealth is at best one ingredient: you also need good IPs, consistent fingerprints and natural pacing. The article on why Playwright bots are detected lists the other ingredients.
When a challenge appears anyway
Stealth reduces challenges; it does not answer them. When a Turnstile widget, a reCAPTCHA or a Cloudflare check page appears anyway, solve it: send the widget parameters to GateSolver, then inject the token, or for the challenge page set the returned cf_clearance cookie with the matching user agent. Combining a cleaned-up browser with solving for the remainder is usually more stable than chasing a perfect fingerprint.
A word on purpose
Stealth techniques are widely used for QA against production bot protection, monitoring public pages, and research. Using them to defeat protections on logins, checkouts or account creation for abuse is a different matter and is not something GateSolver supports. For detection from the other side, see how websites detect automation tools.
Common questions
Does stealth mode make Puppeteer undetectable?
No. It hides common JavaScript tells, but TLS, IP reputation, behavior and patch detection can still reveal automation.
Do I still need stealth with new headless Chrome?
Less than before. New headless removed several tells; test and keep only patches that fix real differences.
What does the webdriver patch do?
It makes navigator.webdriver report what a normal browser reports, instead of true.
Can stealth plugins cause problems?
Yes. Outdated patches can create inconsistencies that a current browser would not have, which detection scripts notice.
Does stealth solve CAPTCHAs?
No. It can make them less frequent, but any challenge that appears still needs to be solved.
Keep reading
- Headless browser detectionThe traces a browser without a window tends to leave: automation flags, missing plugins and telltale user agent tokens.
- navigator.webdriverThe standard flag that reports automation control, what switches it on, and why overriding it alone fixes little.
- Puppeteer detected as a bot: what to checkA checklist for Puppeteer scripts that get flagged: the webdriver flag, headless markers, launch arguments and the request patterns sites notice.
- How do websites detect automation tools?Sites check automation flags, protocol side effects, headless gaps, fingerprint mismatches, network signals and behavior, and combine them into a score.