AI Agents and Coding Assistants
AI That Clicks and Types: How Computer-Use Agents Work
How AI agents read a screen and control a mouse and keyboard, why they are slower and shakier than direct connections, and how to run one with care.
Key takeaways
- A computer-use agent repeats a loop of looking at the screen, choosing an action, performing it and looking again.
- It can work with programs that offer no programming interface, which is its main advantage.
- Pop-ups, layout changes, slow loading and look-alike buttons are common sources of mistakes.
- Whatever the agent can see and click, it can affect, so run it in a separate environment with limited accounts.
- When a direct, structured connection exists, it is usually faster, cheaper and more dependable.
A computer-use agent operates software the way you do. It looks at the screen, usually through screenshots or a description of what is on the page, decides what to do, and sends mouse clicks and keystrokes. Then it looks again to see what changed.
The appeal is reach. Many programs offer no convenient way for other software to control them, but almost all can be used through their screens. The cost is that this route is slower, easier to confuse and harder to confine than a direct connection.
What the agent perceives
You see a screen as buttons, menus and text. The agent receives data that it has to interpret.
The most general method is the screenshot. A model that handles images, a kind of multimodal model, reads the picture and estimates where things are. This works on nearly any program, but small text, crowded toolbars and similar icons can be misread.
Another method uses the structure behind the screen. Web pages have an underlying tree of elements, and operating systems expose accessibility information so that screen readers can work. These list buttons and fields with labels. The information is more exact when it is there, and it can be missing or wrong where a program was built without care.
Some agents combine both. Either way, the agent only knows what the latest look shows. Content that requires scrolling, hovering or opening a menu stays invisible until the agent goes looking.
The loop, one action at a time
Say you ask an agent to enter a new contact into an old desktop program. This is a hypothetical run.
- It takes a screenshot and finds the "Contacts" button.
- It clicks, then takes another screenshot to confirm the window opened.
- It clicks the "Name" field and types.
- It notices a required field it has no value for, and should stop and ask.
- After you supply it, it fills the field and clicks "Save".
- It looks for evidence that the record was saved, such as the name appearing in the list.
Each cycle involves sending an image or description to the model and waiting for a decision. A task you would finish in a minute can take considerably longer. This is the same observe, decide, act and check loop that other agents use, with the screen as the only window on results.
Turning a picture into a click
The step from "I see a button" to "click here" is less trivial than it sounds. With screenshots, the model has to work out a position in pixels. If the image was shrunk before the model saw it, or the display uses scaling, the estimate can land slightly off. A miss of a few millimeters matters when icons sit side by side.
Typing has its own traps. The agent has to know which box is active, whether existing text needs clearing and what format the program expects. A date field may want day first or month first. An autocomplete list may replace what was typed with a different entry the moment the agent presses Enter.
Scrolling adds uncertainty about completeness. A list of two hundred records appears a screenful at a time. The agent must scroll, avoid counting the same row twice and recognize the true end. Asking it to report how many items it processed, and comparing that with the program's own count, is a simple test for skipped or repeated rows.
Waiting is the last skill. People notice a spinning indicator without thinking. An agent has to look again and judge whether the screen has settled before acting.
Why it goes wrong
Graphical interfaces were designed for people, who cope easily with small surprises.
- Unexpected pop-ups such as update notices, surveys or consent banners cover the target.
- Timing trips it up: it clicks before a page has finished loading.
- Layout changes after a redesign or on a different screen size move things.
- Look-alike controls lead it to "Delete" where it meant "Details", or "Reply all" where it meant "Reply".
- Hidden state such as a selected filter changes what a list shows.
- Focus errors send typing into the wrong window or field.
Because each action builds on the last, one misclick can lead several steps astray before anything looks odd. And a screen that appears normal may not mean the change was saved. Reliability has been improving and varies widely by task, so test your own.
Compared with a direct connection
Where software offers an application programming interface, or a connector such as one built with the Model Context Protocol, an agent can ask for exactly what it needs.
| Question | Direct connection | Clicking the screen |
|---|---|---|
| Speed | Usually fast | Many slow cycles |
| Precision | Named fields and clear errors | Depends on reading the screen |
| Survives redesigns | Usually | Often not |
| Limiting permissions | Can be narrow | Often the whole logged-in session |
| Works with old programs | Only if an interface exists | Usually yes |
The permissions row deserves attention. A connector might be allowed only to read invoices. An agent clicking inside your accounting program as you can do anything you can do there.
The safety problem
An agent with a mouse and keyboard and your logged-in sessions has a very wide reach: email, files, saved payment methods, settings. Sensible practice narrows it.
- Run it in a separate environment, such as a virtual machine, which is a simulated computer isolated from your real one, or at least a separate user account.
- Sign in only to the accounts the task needs.
- Keep password managers, banking and personal files out of reach.
- Require approval before sending, buying, deleting or changing settings.
- Do passwords and verification codes yourself.
- Watch the first runs, and know how to stop it at once.
Screens also carry other people's words. An email, a comment or a web advertisement can contain text aimed at the agent, an attack called prompt injection. Vendors build defenses, none of them complete.
Respect rules and consent as well. Many websites and services restrict automated use in their terms, and bot checks such as CAPTCHAs exist to keep automation out. Do not use an agent to get around them.
Privacy of what is on screen
Screenshots capture whatever is visible: a notification from a friend, a spreadsheet of salaries in the next window, a medical letter. If images are sent to a remote service for processing, that content travels too.
Close unrelated windows, turn off notification previews and use a clean environment. Check how long the provider keeps screenshots and logs, who can view them and whether they are used to improve models. Settings and policies differ and change, so read the current ones.
If the screen shows data about other people, make sure you are allowed to process it this way. In workplaces, that is a question for whoever handles privacy or security.
Jobs that suit it
Good first uses share three features: low stakes, results you can verify and no better interface available.
Reasonable examples include checking that a website's signup flow works using a test account, copying records from an old program into a spreadsheet that you then compare with the source, or gathering settings from a series of screens into a checklist.
Poor early choices include anything involving money movement, irreversible deletion, legal agreements or messages to large groups. So are long unattended sessions on a machine holding sensitive material.
For tasks that never vary, a conventional automation script may serve better, as discussed in robotic process automation and AI agents compared.
Computer use and accessibility
The same ability can help people who find screens hard to operate. Someone with limited hand movement might ask an agent to carry out a sequence of clicks that would take them a long time. A person facing a poorly designed form might have it read the fields aloud and fill them as instructed.
These uses carry the same hazards, and the person relying on the agent may have less opportunity to spot a wrong click. Spoken or written confirmation before anything is submitted matters here, in a form the user can actually check.
Agents are also no substitute for accessible design. Software with properly labeled controls works better for screen readers and, as it happens, for agents too. An organization that fixes its labels helps both, while one that expects an agent to cope with a confusing interface leaves the underlying barrier in place. For more on what current tools offer, see AI tools for blind and low-vision users.
How to give instructions
Describe the starting point, the goal and the evidence of success. Name the program and the account. State what must not be touched. Tell it to stop if it meets a login, a payment screen, a warning or anything unexpected.
Break long jobs into pieces with a check between them, for instance ten records first, reviewed against the originals, before the remaining hundreds. Afterward, verify in the system itself and not only in the agent's summary. A summary saying "all records entered" is a claim; the record count and a spot check are evidence.