Back to the research
The Agentic WebAPIsweb agents

Do Web Agents Do Better With an API Than a Browser?

A 2024 benchmark study compares agents that click through pages with agents that call a site's machine interface.

Do web agents perform better when a site offers an API?

In one benchmark study, yes. Agents that could call APIs outperformed agents that only browsed. An agent that could do both did best, with a 38.9% success rate. That was more than 24.0 percentage points above browsing alone, according to Song et al. (2024). For a site owner, the finding suggests a machine-readable path may help agents finish tasks.

At a glance

  • Finding: On WebArena, API access beat browsing alone, and combining the two beat both.
  • Why it matters: Pages built for people are a hard interface for software.
  • Limit: This is one benchmark, reported in a paper from October 2024. We reviewed only its abstract.

What is the difference between a browsing agent and an API agent?

A browsing agent works like a person at a screen. It reads a page, picks a link or button, and repeats until the task is done.

An API (application programming interface) is a structured way for software to request data or trigger an action. An API agent skips the page and sends those requests directly. The paper compares both approaches, plus a hybrid agent that can use either.

What did the researchers find?

The authors tested on WebArena, a widely used benchmark of realistic web tasks. They report that API-based agents outperformed browsing agents. The hybrid agent beat both nearly uniformly across tasks.

The hybrid result is the practical point. APIs did not make browsing useless. Some tasks may have no API that covers them, and a page may be the only route. Letting the agent choose gave the best results.

What does this mean for your site?

The paper's own conclusion is conditional: when APIs are available, they are an attractive alternative to relying on browsing alone. It does not say every site needs one.

An illustrative example: a store lets customers check order status. A browsing agent must log in, find the right page and read a table. An API agent could request the order record directly. That leaves fewer steps where it can misread the page. This is our inference from the paper's setup, not a result the authors measured.

An API also raises a separate question: what is the agent allowed to do? Being able to call an endpoint is not the same as having permission. Scope, authentication and limits still need design. The paper's abstract does not address them.

What remains uncertain?

  • Benchmark scope. WebArena tasks may not match your customers' tasks.
  • Age. The paper dates from October 2024. It says nothing about how current agents or commercial products behave.
  • Evidence depth. We read only the abstract, so we can't judge how the APIs were built or where each agent type failed.
  • Business outcomes. The study measures task success. It does not measure traffic, citations or sales.

What should you test next?

  1. List the three to five tasks you most want an agent to complete, such as checking stock, tracking an order or booking a slot.
  2. For each task, note whether a documented API already covers it. Note also whether a person-facing page is the only route.
  3. Run a small test with whichever agent tools you use. Compare task success, number of steps and errors for the page route and the API route. Keep permission limits on both, and record where each route fails.
← Explore more research