Robotic process automation (RPA) is software that repeats rule-based tasks a person would do on a computer, such as copying data between applications, filling in forms, or clicking through a legacy system, by operating the user interface the way a person does. The "robots" are scripts, not physical machines, and they follow exactly the steps they were given.
RPA spread because it automates work without changing the underlying systems. Instead of building an integration between an old billing system and a new CRM, a bot opens both, reads one screen, and types into the other. Tools let teams record or drag and drop these steps for rule-based desktop tasks.1 One of the early documented enterprise cases is a 2015 London School of Economics study of RPA at a UK mobile operator.3
The same design sets its limits. A bot knows where to click, not why. It needs structured input and stable screens. An AI agent works from a goal, reads unstructured text, and calls APIs, so it can handle the variation that stops a bot.
One refund request, handled by a bot and by an agent
A telecom's customer emails to dispute a charge. The back-office task is the same in both lanes: check the bill and issue a credit if the charge was wrong.
RPA bot
Follows a script- TriggerRuns only if a person has first tagged the email "billing dispute" and typed the account number into a queue.
- Openbilling_app.login()→ opens the legacy billing screen
- Readscreen.read("Charges", row=1..20)→ copies the first 20 rows
- RuleIf two rows share a date and amount, flag a duplicate. The duplicates are on page 2, so the bot finds nothing.
- StopMarks the case "no duplicate found" and returns it to the queue.
Script finished, problem not solved. A person reopens the case and checks page 2 by hand.
AI agent
Pursues the goal- UnderstandGoal: verify a disputed roaming charge. Extracts the account number and the month from free text.
- Toolbilling.charges(acct, month="2026-10")→ 34 charges via API, 2 identical roaming lines
- CheckPolicy: duplicate charges under €50 are credited automatically. This one is €18.
- Actbilling.credit(acct, 18.00, reason="duplicate")→ credit applied
- ReplyConfirms the credit and when it will appear on the next bill.
Resolved in one pass. Credits above the limit still go to a person.
Illustrative example. Account numbers, amounts, and the €50 threshold are placeholders a company would set itself. A well-built bot could page through results; the point is that every case must be scripted in advance.
What an RPA bot actually does
A bot is a recorded or designed sequence of actions: open an application, find a field, read or type a value, click a button, move to the next screen. To find each element it uses a selector, a description of the element's attributes and its position in the window.
:desktop > window[Name="Orders - Billing v4"][Process="billing"]
> pane[Name="Charges"]
> button[Name="Issue credit"]Illustrative desktop selector in the style Power Automate documents. If the vendor renames the window to "Billing v5" or the button to "Apply credit", this selector no longer matches.
Microsoft's own documentation says hard-coded selector values work in static applications but can be a barrier in dynamic ones, and recommends fallback selectors, which the tool tries in order when one fails.2 That is the maintenance work RPA teams spend their time on.
Where RPA breaks
RPA fails in predictable places. Knowing them tells you which processes to keep on RPA and which to move.
Interface changes
ControlA software update moves a field, renames a button, or adds a pop-up, and the bot stops or clicks the wrong thing. Use APIs where they exist, add fallback selectors, and test bots after every upstream release.
Unstructured input
ControlEmails, chat messages, and scanned documents do not arrive in fixed fields. Put an extraction or language model step before the bot, with confidence thresholds.
Exceptions
ControlBots handle only the paths someone scripted. Measure how many cases fall out to people; if the share is high, the process needs judgment, not more rules.
Bot sprawl
ControlHundreds of small bots, each owned by a different team, become hard to monitor. Keep a register with owners, credentials, and the systems each bot touches.
Credentials and audit
ControlBots log in with real accounts. Give each bot its own identity with the narrowest access, and keep logs of what it changed.
RPA, intelligent automation, and AI agents
The categories overlap in vendor marketing. Gartner calls the rebranding of existing products, including RPA and chatbots, as agents without real agentic capabilities "agent washing".4
| Term | How it decides the next step | Input it handles | Typical integration | Breaks when |
|---|---|---|---|---|
| RPA | A fixed script | Structured fields on stable screens | The user interface | Screens change or input varies |
| Intelligent automation | A script, with AI models for specific steps | Documents and text, via extraction models | UI and APIs | Cases fall outside the scripted paths |
| Agentic workflow | A predefined path, with models handling steps6 | Text, documents, API data | Mostly APIs | The task needs a path nobody designed |
| AI agent | The model, within permissions and policy | Free text, documents, API data | APIs and tools | Permissions, data, or policies are unclear |
Agents can also operate user interfaces. Model providers now offer computer use tools that let a model take screenshots and control a mouse and keyboard.5 This helps with systems that have no API, but it is slower and less predictable than an API call, so it suits gaps rather than core paths.
Where RPA still fits, and where agents take over
Many companies keep their RPA estate and add agents in front of it. The agent understands the request; the bot or an API performs the stable, repetitive part.
Keep on RPA: report consolidation
Exporting fixed reports from three systems into one spreadsheet each night is stable, structured, and rule-based.
export → merge → publishMove to an agent: supplier emails
Suppliers write in free text about invoices, delays, and price changes. An agent classifies, extracts, and updates the ERP or asks a buyer.
read → classify → update or escalateAgent in front, bot behind
An online retailer's agent understands a return request in chat, then triggers an existing bot that creates the return label in a legacy warehouse system.
understand → trigger bot → confirmClaims status updates
A bot copied claim statuses between systems on a schedule. An agent now answers customers directly from the claims API with the current status.
API read → answer → logPlan changes
Plan changes with many conditions used to need bots with long rule trees. An agent checks eligibility through APIs and applies the change within policy.
check eligibility → change plan → notifyPayment reconciliation
Matching bank statement lines to payments is a classic RPA job. An agent handles the exceptions bots used to send to people: partial payments and unclear references.
bot matches → agent resolves exceptionsCommon questions
Is RPA a form of AI?
Classic RPA is not. It follows scripts and does not learn or interpret. Vendors now bundle AI models for reading documents or classifying text, which is usually called intelligent automation.
Will AI agents replace RPA?
For processes with unstructured input and many exceptions, agents are replacing scripted bots. For stable, structured, high-volume tasks, RPA remains cheap and predictable. Many companies run both, with agents handling the judgment and bots or APIs doing the repetitive steps.
Why do RPA bots break so often?
Because they depend on the user interface. When an application update renames a field or moves a button, the bot's selectors no longer match and it stops or acts on the wrong element.
Should we migrate existing bots to agents?
Start with the bots that cost the most to maintain or send the most cases to people. Those usually involve free-text input or frequent exceptions, which is where an agent helps most.
References
- Microsoft. Introduction to desktop flows. Power Automate documentation, Microsoft Learn.
- Microsoft. Build a custom selector. Power Automate documentation, Microsoft Learn.
- Lacity, M., Willcocks, L. P., and Craig, A. Robotic process automation at Telefónica O2. The Outsourcing Unit Working Research Paper Series 15/02, London School of Economics, 2015.
- Gartner. Gartner Predicts Over 40% of Agentic AI Projects Will Be Canceled by End of 2027. Press release, 25 June 2025.
- Anthropic. Computer use tool. Claude documentation.
- Anthropic. Building effective agents. December 2024.