Skip to content
All fingerprint checksAutomation surface

document.hidden agrees with document.visibilityState

Check id document-visibility-coherence

What an ordinary browser yields

document.hidden is true exactly when document.visibilityState is "hidden" — always, by definition.

What a detector infers

document.hidden and document.visibilityState are two views of one piece of state, and the specification defines the first in terms of the second: hidden is true exactly when visibilityState is the string "hidden". There is no state of a real browser in which they disagree, because one is computed from the other. This is worth checking because faking foregroundedness is a common and rational thing for automation to do — browsers aggressively throttle timers and rAF in background tabs, which slows a headless run to a crawl, so tooling patches the page into claiming it is visible. And when it does, it tends to patch the property a page is most likely to read while missing its twin. A detector needs no baseline to notice: it reads both and asks whether they can both be true.

How to resolve it

Never patch one of these without the other; the spec derives hidden from visibilityState, so a disagreement is not an unusual browser but an impossible one. If the goal is to escape background throttling, keep the page genuinely foregrounded — or accept the throttling — rather than claiming a visibility the browser is not in.

How is a headless browser detected?

Read in the wild by

Kasada

Reads both halves of the visibility state, which are defined in terms of each other.

document_hidden, document_visibility_state

Kasada ips.js teardown — the full 427-probe list

Every attribution traces to a published artifact. See the sources and their limits.

Nearby checks in Automation surface

See all 27 checks in Automation surface
Who builds this test

Clearcote is a browser built for fingerprint coherence

It is a Chromium fork, maintained by the same people who wrote this reference. It ships as a compiled browser rather than as a stealth script injected into someone else's — which is a description of how it is built, and is not an argument about how it behaves on this check.

This audit takes no position on how Clearcote scores on Automation surface checks, on this one, or anywhere else. It has no baseline corpus of other people's fingerprints to rank you against and no vendor scoreboard — nearly every check is self-referential, asking one browser the same question through two independent APIs and reporting whether both answers can be true at once. It runs identically on any browser, including ours. Run it on yours and read the result yourself.

See the other checks in Automation surface — the family document-visibility-coherence belongs to.