🔧 Programmierung 🕛 vor 6 Monaten 7 Min Lesezeit
0

How Accessibility Tree Formatting Affects Token Cost in Browser MCPs

↗ Quelle (dev.to)
🗣️ Stimme:
📑 Inhaltsübersicht

Token cost in browser automation MCPs has become a real topic — articles like compresses DOM state to a fraction of the original, and some tools add vision-based fallbacks for layout understanding.



I've been working on and WebClaw as MCP servers in the same Claude Code session, then ran the same steps on each:




  1. Navigate to the target URL

  2. Call the snapshot tool (browser_snapshot / page_snapshot)

  3. Measure the full response text length in characters

  4. Estimate tokens as characters / 4 (approximation — actual tokenization varies by model)



Both tools return the complete accessibility tree with no truncation. WebClaw's default is unlimited output (no token budget), so this is a pure format efficiency comparison.



I picked three pages with different content patterns:





  • Wikipedia — long article with many reference links and navigation templates


  • GitHub — repository page with file listing, README, and sidebar


  • Hacker News — list-style page with 30 items



Important caveat on fairness: Playwright MCP runs a headless Chromium (not logged in). WebClaw runs in the user's Chrome (logged in to GitHub in my case). This means WebClaw sees more UI on GitHub — authenticated menus, notifications, repo actions — which actually increases its output. The comparison is biased against WebClaw on that page.






Results: Format Efficiency



Both tools returning full, untruncated accessibility trees:




















Site Playwright MCP WebClaw Difference
19,409 tokens (77,637 chars) 4,304 tokens (17,215 chars) 78% smaller
, : extract the zip, go to chrome://extensions/, enable Developer mode, and load the dist/ folder.






Wrapping Up



The takeaway isn't "use WebClaw instead of Playwright MCP" — it's that accessibility tree format choices matter more than you'd expect. Assigning refs to every element vs. only interactive ones, including [cursor=pointer] hints vs. omitting them, following the W3C accessible name spec vs. using title attributes — these small decisions compound into a 51-79% difference on real pages.



The browser MCP space is evolving quickly. File-based snapshots, DOM compression tools, and hybrid approaches are all worth watching. If you're hitting token limits with your current setup, the data here might help you understand why — and what to try next.



If you want to reproduce these measurements or try WebClaw, the

npm: npx -y webclaw-mcp






WebClaw is MIT-licensed open source.

Vollständiger Original-Artikel
Den kompletten Beitrag mit allen Details direkt auf dev.to lesen.
↗ Original-Artikel auf dev.to lesen
Wie bewertest du diesen Beitrag?
1 Klick Feedback
Teilen mit Netzwerk & Team:

Community-Analysen & Experten-Meinungen 0

Verfasse deine eigene Analyse, teile Workarounds oder diskutiere diesen Vorfall im Blog.
Noch keine Community-Analyse verfasst. Markiere einen Textabschnitt oder klicke oben auf Eigene Analyse verfassen“!
Community Pulse: Relevanz-Einschätzung
1 Klick Experten-Votum
🔴 Akute Relevanz 0%
🟡 In Evaluierung 0%
🟢 Keine Auswirkung 0%
Spannende Innovation 0%
Verwandte Story-Cluster & Quellen (Vektor-KI)
Port 8095 Engine
11 Quellen
CVE-2026-16794 | GitLab up to 19.1.7/19.2.5/19.3.1 Compliance Framework Management improper authorization (WID-SEC-2026-3315)
1 Quelle
Windows 11: Auto-Update-Installation, aber keine Einträge in Verlauf? - BornCity
1 Quelle
CVE-2026-76438 | Cisco BroadWorks Web-based Management Interface improper authorization (EUVD-2026-81161)
Ähnliche Beiträge
🔍 Verwandte News

Auch interessante Nachrichten How Accessibility Tree Formatting Affects Token Cost in Browser MCPs

Thematisch verwandte Begriffe: Accessibility, Tree, Formatting, Affects · 6 Treffer

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Zum Aktualisieren ziehen
ZERO-DAY Kritische Sicherheitsmeldung
Advisory →
TTS Reader • tsecurity.de Voice
tsecurity.de Icon
tsecurity.de App
Offline-Lesen, Eilmeldungen & 0ms Ladezeit

Installiere tsecurity.de direkt auf deinen Home-Bildschirm für das ultimative Vollbild-Magazinerlebnis ohne Browser-Leisten.

Nächster Beitrag
Community Radar & Live Chat
Sentinel Bot online • Live-Stream
Dein Cluster: Security Explorer
Match:
lädt…
Verbindung zum Community-Stream wird aufgebaut...
Aktivitäten deiner Analysten
lädt…
Neues Thema oder Eilmeldung einreichen

Reiche interessante Links, Zero-Days oder Debatten ein. Die Community entscheidet per Upvote über die Veröffentlichung.

Heiß diskutierte Einreichungen
🔖 Gespeicherte Artikel
📂 Keine gespeicherten Artikel vorhanden.
News ⏱️ 3 Min vor 10 Min
Artikeldaten werden geladen...

↗ Original-Quelle