Behavioral bot detection: what browser signals can tell you
Understand behavioral bot detection, webdriver, and trusted events. Learn which browser observations help and where session evidence is needed.
Obaid Ahmed7 min read
Behavioral bot detection evaluates patterns across a session—navigation, input timing, interaction continuity, and task progression—to assess automation. Browser flags and event properties can contribute observations, but neither a false webdriver value nor a trusted click proves a human operator.
Use this guide to understand what those properties actually measure, design an evidence record, and interpret a session in Marshy. Its examples are engineering test cases, not a detector benchmark or provider fingerprint.
Which behavioral signals are worth investigating?
Start with a complete task: which pages were visited, what inputs and actions occurred, whether errors were recovered from, and when classification became available. Timing and repeated interactions can help you investigate that sequence, but plausible alternative explanations include ordinary keyboard use, a familiar customer workflow, and your own interface scripts.
Do not make one timing threshold or mouse pattern a universal rule. Collect independently labeled examples from the population you intend to classify, then measure how the proposed combination behaves on both human and automation tasks. The detector evaluation guide gives that test a structure.
For API semantics, open the browser event lab and inspect a harmless form's reported event metadata. The lab is an instrumentation demonstration without a detector; it lets you examine what the properties below report without presenting the observations as detection accuracy.
What navigator.webdriver actually tells you
The W3C WebDriver interface exposes a browser automation flag. Its session lifecycle sets that flag for WebDriver control; the property reflects the flag’s state. The specification describes cooperation between the browser and the document.
That is a useful positive observation when present. It does not identify the model, company, customer, or purpose behind an automated task. A QA runner and an assistant can both automate a permitted workflow.
The important inference boundary is the negative result: false means this flag is not set. Treating it as “no AI agent is present” adds a claim the interface does not provide. The MDN webdriver reference documents browser-specific conditions associated with the property. Record the browser and control method when testing it instead of assuming every automation surface behaves identically.
Keep these fields separate in your instrumentation:
| Observation | Reasonable record | Unsupported conclusion |
|---|---|---|
| webdriver is true | Browser reports its automation flag | This is ChatGPT, Claude, or another named provider |
| webdriver is false | Browser does not report that flag | The operator is human |
| Property unavailable | This observation is unavailable | The visitor passed a human check |
What a trusted event actually means
The word “trusted” sounds stronger than the API contract. In the WHATWG DOM standard, the property concerns event dispatch by the user agent versus dispatchEvent(), with a documented exception for click(). It is not an identity credential.
MDN’s isTrusted reference also describes browser-generated events, including events associated with programmatic focus. This matters because “trusted” and “manually initiated by a person” are different assertions.
A scripted event can be part of your own legitimate interface. A browser-generated event can be part of a workflow whose operator you have not identified. Record the event’s origin semantics without turning the property into a human, abuse, or authorization label.
The event also says nothing about intent. A customer can knowingly delegate an export to an assistant. A human can attempt an unauthorized export. Your account permission checks need to handle both.
Why combining the two flags does not fix the problem
A tempting rule is: “webdriver is false and the click is trusted, therefore the session is human.” Combining two observations cannot establish a conclusion neither observation measures.
Before implementing a rule, write down its expected behavior in concrete cases:
| Scenario to test | What the rule needs to distinguish |
|---|---|
| Human using your application’s scripted controls | Interface implementation versus operator identity |
| Known WebDriver test runner completing a form | Declared automation versus a named AI provider |
| Assistant using a computer-control interface | Input delivery method versus who chose the action |
| Human handing a task to an assistant midway | A changing operator versus a single session-wide label |
| Direct API client performing the same operation | Backend activity outside browser instrumentation |
These are test cases, not reported experimental results. Use known operators and owned environments to establish their actual observations. Do not fill the expected values from the detector you are trying to evaluate.
The same discipline applies to timing, repeated clicks, and a familiar user-agent string. Ask what each observation measures and what alternative explanations your test must cover before using it in a decision.
Design the evidence record before the rule
Start with the product decision. For analytics, you may want to understand which sessions complete an onboarding task. For a costly export, you may need to investigate quotas, permissions, and retries. Those decisions require different evidence and tolerate different delays.
An investigation record can separate four layers:
- Browser observations: reported automation flag, relevant event metadata, page coverage, and collection time.
- Classification: detector result, review or undecided state, result time, and available automation kind.
- Account context: authenticated account and how the session was associated with it.
- Backend outcome: operation identifier, authorization result, completion, and duplicate handling.
Preserve missing values. An absent verdict might indicate an incomplete session or instrumentation problem; it must not silently become a human classification. Similarly, no browser observation should be expected for an API request that never loaded your pages.
Collect only what the investigation needs. Event type and relative time may answer an instrumentation question without recording typed content. Document retention and account association before building a detailed event stream.
Use Marshy to investigate the session and task
Install your Marshy integration’s snippet and verify collection for the relevant project. The Next.js installation tutorial walks through placement and verification in an App Router application.
In Sessions, narrow the time range to the task you are investigating. Open the matching session and read the classification alongside the Journey timeline. Check when the verdict arrived relative to the important action. A later classification can help an investigation without proving that an earlier access decision had that evidence.
Review account association and correlate the session with your backend operation record. The Marshy session walkthrough explains the current interface in detail.
Write down what remains unknown. An automation kind is not automatically a provider name. A classified agent session is not automatically an abusive session. Where attribution evidence is unavailable, retain “provider unknown” rather than guessing from the task or browser string.
Evaluate detection with a meaningful test population
Repeating the same form in the same browser checks repeatability for that setup. It does not establish population coverage or measure classification errors across real users and agent environments.
For a detector evaluation, define the target population and sampling plan before collecting results. Include independently labeled human and automation cohorts, comparable tasks, relevant browsers and control methods, and mixed-control cases. Version the detector and instrumentation so later results remain interpretable.
Report counts by cohort, false classifications, review cases, missing verdicts, and time to verdict. Keep invalid tests and exclusions visible with their reasons. Any performance estimate needs its denominator and uncertainty; an impressive aggregate cannot substitute for an untested environment.
The evaluation guide and research protocol template provide a structure for that work. Define what evidence would justify your proposed policy before looking at favorable results.
Keep authorization tied to the operation
Observe a proposed agent policy before enforcing it. Compare classifications with completed tasks, costly operations, and legitimate customer friction. Decide what review, missing results, and detector outages should mean for each action.
Enforce authentication, permissions, quotas, and duplicate protection on the server. A trusted click does not grant export permission. A checkbox clicked by an assistant does not establish independent human approval. If an operation requires a particular person’s approval, design and verify that approval contract explicitly.
Marshy helps you investigate classified browser traffic in the context of a session. Begin with one valuable task, preserve the evidence and unknowns, and use the agent readiness worksheet to identify the controls your product still needs.
Technical references checked October 8, 2026. This is a sourced engineering guide; no benchmark results or provider-specific fingerprints are presented.