Computer agents risk stale clicks when pages are still loading

What Does "Now" Mean to Your Computer-Use Agent? Stale Screenshots, Page Loads, and Which Check to Run Before a Click

Artificial Intelligence

Summary

When computer programs decide where to click on a web page, they can sometimes click the wrong thing if the page changes while they are planning. The authors found that most mistakes happen not during planning but when the page is still loading. Waiting a short time after the page appears can reduce errors. They tested ways to check before clicking, showing that simple pixel checks work well and faster than complex AI models.

What this means in practice

  • For web automation engineers: Improve automated web interactions by implementing checks based on network inactivity and pixel comparison to reduce misclicks on dynamic pages.
  • For digital testing teams: Enhance web testing reliability by verifying target element positions before actions to catch page changes that happen after initial load.

Authors

Vasundra Srinivasan

Abstract

Computer-use agents plan on a screenshot for several seconds and then click at a position on the screen; if the page has changed in the meantime, the click lands on an unintended element. Prior work treats the planning interval as the source of this risk. Measuring planned clicks on 31 public web pages, we find that the risk lies in page loading: 0.4% of clicks planned on fully loaded pages became stale within 30 seconds, against 17% of clicks planned in the first second after a page opened. On these pages, waiting about one second for network activity to stop removes most of this risk, yet the wait rules of eight of ten widely used open-source agents leave more than 1% of clicks stale. Commercial pages keep loading for longer: in the HTTP Archive's public crawl, 15% of 65 desktop booking and buying home pages went 500 ms without network requests within 3 seconds of their HTML being parsed, against 63% of 3,028 .gov pages, and 52% shifted their layout within 6.5 seconds of a network-idle wait capped at 3 seconds, against 8% (61% against 26% among pages recorded in full). Where a check before the click is needed, as before irreversible actions and on pages that are still loading, a pixel comparison verifies the target's position as accurately as a frontier vision-language model at one eighth of the latency, and a 4B model matches the frontier model in verifying whether the previous action succeeded. We release a benchmark generator, a break-even formula for when a check pays, and three rules for agent developers: https://github.com/multimodal-ai-engineering/preflight-bench