Why Raw Accessibility-Tree Counts Need Environment Controls

Two browser windows show the same page at different widths while an engineer compares their rendered text flow.

Platform Field Study | Browser Instrumentation

Why Raw Accessibility-Tree Counts Need Environment Controls

Two machines, one Chrome build, one byte-identical page—and accessibility node counts 440 apart.

Two browser windows show the same page at different widths while an engineer compares their rendered text flow.
The page can stay byte-identical while rendering conditions change the accessibility-tree nodes Chrome exposes.

The finding: a raw accessibility-node total describes the page, the viewport, and Chrome’s active accessibility state together. Without those conditions, it is not a portable benchmark result.

Key Takeaways

  • The same page can report two different sizes. Two hosts on Chrome 151.0.7922.140 read a byte-identical fixture as 1,684 and 1,244 accessibility nodes while agreeing exactly on DOM length, actionable elements, and the DOM-characters-to-scene-characters reduction ratio.
  • The measured viewport variance is layout-derived. Narrowing the viewport from 1280 px to 800 px added 190 nodes without changing one character of DOM. Every added node was an InlineTextBox; subtracting them leaves 1,244 at every width tested.
  • The intuitive ignored-node explanation is measurably wrong here. Only two nodes in this fixture carry the ignored flag, so ignored nodes cannot account for the 440-node cross-host gap.
  • Pin the viewport, then verify it took. Issuing Emulation.setDeviceMetricsOverride is not proof. Read innerWidth back, and only resize a tab the harness itself created.
  • Comparability is a per-measurement claim. Raw node totals, inline-box counts, screenshot payloads, and timings need their own environmental controls; one report-level boolean cannot make them portable.

Browser agents do not read pages the way scrapers do. Instead of parsing raw HTML, many agent stacks ask Chrome for its accessibility tree through Accessibility.getFullAXTree, which returns the entire tree for the root document [1]. That tree exposes roles, names, states, and relationships—the semantics assistive technologies and automation need to understand interface objects [2].

Its size is often quoted as a performance figure: N nodes reduced to M actionable elements. That raw number is not portable. Two machines running the identical browser build against a byte-identical page returned accessibility node counts 440 apart, while the page-content measurements in the same run agreed exactly [4][5]. This article documents the measurement, isolates one source of variance, and proposes a benchmark contract that makes such figures comparable—or honestly refuses to call them comparable.

A node count without its rendering conditions is not a property of the tool. It is one reading of one environment.

The observation

A synthetic fixture—685 total elements, built from 200 fixed-copy paragraphs and 120 form rows, each with one textbox and one button—was rendered and measured on two Windows hosts. Both ran Chrome 151.0.7922.140, V8 15.1.206.17, DevTools Protocol 1.3. The fixture is deterministic: no randomness, no clock, no network, fixed strings. The benchmark and cross-machine results are published with the connector [4][5][6].

Measurement Host A Host B
DOM characters 55,945 55,945
Accessibility nodes 1,684 1,244
Actionable elements 240 240
Scene characters 4,579 4,579
Screenshot bytes 119,683 109,932

The DOM was identical. The actionable subset was identical. The reduction ratio—DOM characters divided by scene characters, 55,945 ÷ 4,579—was identical to two decimal places on both hosts. This is a page-content ratio, not a ratio taken against the accessibility-node count: actionable elements divided by raw nodes differs between the hosts precisely because the denominator does. The accessibility-node count moved by 26%, and the screenshot payload by roughly 8%—the two figures in that table read off the rendering rather than off the page.

A benchmark that reports the node count as a property of the instrumentation would, on this evidence, conclude that one machine’s perception layer is a quarter larger than the other’s. Nothing of the kind is established.

Method

The natural first hypothesis is browser version, and it was already excluded: the build strings match to the patch level. The second is page content, excluded by identical DOM length and element count.

The third hypothesis—that part of the tree is layout-derived rather than semantic—is testable on a single machine. Chrome’s accessibility tree contains InlineTextBox nodes, which correspond to laid-out runs of text rather than to elements. If layout drives the count, changing the viewport must change it while leaving the DOM untouched.

The fixture was therefore measured at four viewport widths on one host, using Emulation.setDeviceMetricsOverride, which overrides screen and inner-window dimensions and related media-query values [3]. The harness reads innerWidth back and settles before each tree capture so a silent override failure or mid-relayout read cannot masquerade as a valid measurement.

Results

Viewport AX nodes InlineTextBox AX − InlineTextBox Ignored Actionable DOM chars
800 px 1,874 630 1,244 2 240 55,945
1280 px 1,684 440 1,244 2 240 55,945
1920 px 1,684 440 1,244 2 240 55,945
2560 px 1,684 440 1,244 2 240 55,945

The raw count is viewport-dependent. Narrowing the window to 800 px added 190 nodes to a page whose DOM did not change by a single character.

The measured viewport delta is entirely InlineTextBox. The delta in the total and the delta in the inline-box count are the same number at every tested width. Subtracting them yields 1,244—invariant across a 3.2× range of viewport widths.

Ignored nodes are not the cause in this fixture. Only two nodes in the entire tree carry the ignored flag, a population far too small to account for a 440-node gap. That matters because “generic and ignored nodes vary by platform” is an intuitive explanation, and it is measurably wrong here.

The full role histogram at 1280 px accounts for every node: StaticText 440, InlineTextBox 440, generic 240, paragraph 200, LabelText 120, textbox 120, button 120, none 2, RootWebArea 1, main 1. The 240 actionable elements are exactly the 120 textboxes plus the 120 buttons.

A later run on Host B returned TOTAL 1684 / INLINETEXTBOX 440 / SEMANTIC 1244 at an inner window of 929 × 925—the same semantic figure, reached independently on different hardware at a third viewport size [5].

What this does not establish

Host B’s original reading of 1,244 was a bare total; its role breakdown was never captured. The arithmetic is suggestive but not decisive: in this tree, three disjoint role sets each happen to total exactly 440—InlineTextBox, StaticText, and generic plus paragraph. Any one of them going missing produces 1,244. Attributing that first reading specifically to absent inline boxes is an inference, not a measurement.

Viewport width alone does not appear to explain it: the inline-box count floors at 440 and does not move between 1280 px and 2560 px, so reflow across the widths tested never approaches 1,244. That points toward a layer being absent rather than merely reflowed. It is not established. The distinction between what the evidence favours and what was measured is exactly the distinction a benchmark exists to preserve, and the honest answer is that the first reading’s composition is unknown.

The two hosts also did not agree on everything: screenshot payload sizes differed by roughly 8%. That is consistent with—but not proof of—a rendering difference, since PNG payload size is a function of image content and encoder behavior, and no pixel comparison was performed. The machines’ windows were never pinned to a common size, which is a second reason not to compare those payloads.

Implications for benchmark design

The defect is not in the protocol. getFullAXTree returns the tree it promises [1]. The defect is treating one number as though it described the tool when it describes the tool, the window, and Chrome’s active accessibility state together.

Pin the viewport, then verify it took. Issuing the override is not enough; read innerWidth back. Pin it only on a tab the harness created—resizing an operator-owned tab is a side effect a benchmark should not cause.

Separate layout-derived nodes from semantic ones. Report the semantic count as a candidate cross-machine figure and the raw count as diagnostic—candidate because it survived every condition tested here, not because it is proven invariant everywhere.

Scope the comparability claim to specific measurements. A single boolean asserting that a whole report is comparable is almost always false. Latency, screenshot size, and node totals do not travel with the same guarantees as element counts. Enumerate which fields survive a move between machines, and say plainly which do not.

Applied here, DOM length, actionable count, scene length, and the reduction ratio agreed exactly across both hosts. The semantic count also agreed—but on two hosts, one browser build, and one fixture, with the accessibility mode never pinned. That is evidence it is more stable, not a guarantee that it is invariant. Raw node total, inline-box count, screenshot payload, and every timing figure remain environment-specific.

Reproducing it

The connector, fixture, benchmark, and cross-machine result table are published in the MIT-licensed skynet-chrome-cdp repository [4][5][6]. The standalone benchmark is dependency-free so it can run on a machine where installing a package is not available.

The wider point generalizes past accessibility trees. Any figure derived from a rendered page—node totals, screenshot sizes, layout boxes, visible-text extents—is a reading of the environment as much as of the page. The remedy is not a better number. It is stating the conditions under which the number was taken and refusing to compare two readings taken under conditions that were never made equal.

Formal research paper

Independent research preprint — not peer reviewed. The seven-page PDF and editable eight-page DOCX package the field observations, controlled fixture, limitations, and reproducibility contract used by this article. They are research artifacts, not an IEEE publication or claim of peer review.

Exact source commit: d19cd02227979b70596dbc440e06f1e08a52e659

Sources and reproducibility

Evidence boundary: the figures above cover two Windows hosts, Chrome 151.0.7922.140, and one deterministic fixture. The original 1,244-node reading has no role histogram, so its missing layer is unknown. The later semantic-count agreement is evidence for a reporting candidate, not proof of universal cross-machine invariance.

This Platform field study was brought into the canonical source, metadata, citation, image, responsive-table, and live-verification pipeline on August 23, 2026.

Signed by Skynet. Editorial byline, not a cryptographic signature; the linked protocol documentation, benchmark source, and cross-machine results define the reproducible evidence.

Chat with us
Hi, I'm Exzil's assistant. Want a post recommendation?