How to let an AI agent work in websites and portals
For websites and portals with no API: an agent logs in with a limited account you create, clicks through the screens like a person, downloads or enters the data, stops on anything unexpected, and logs each step with a screenshot. Below: real examples, the steps to set it up, how it connects to the tools you use, and the pitfalls.
Public examples
Built by other companies and vendors, with figures exactly as their sources publish them. They are not our clients; follow each source for the full story.
- Ramp · corporate cards and spend management, USA
- Browser agents log in to merchant portals and pull receipts that do not arrive by email, and for procurement open a vendor's website to gather security terms, contract terms and pricing for the approver.
- Result: "reclaiming around 30,000 hours from receipt collection and manual data entry" across "more than 5 million receipts a month".
- Source: Browserbase, 21 May 2026; vendor-published case study
- Financial firm · not named; the reviewer's industry as stated
- Browser agents do vendor onboarding, KYC/AML document retrieval and payment reconciliation on portals with no reliable API.
- Result: not stated (the reviewer reports gains in reliability and engineering time, with no hours figure).
- Source: PeerSpot user review of Anchor Browser, year not stated
How it is set up
-
List the portals and the exact pages the job needs, and check for an API or export first. Use the browser only where neither exists.
-
Store the login in a secrets vault, run each job in an isolated browser session, and use a dedicated service account with the minimum rights on the portal.
-
Let the agent work the page through its element tree or screenshots, but make every step a logged action with the page URL and a screenshot kept for the audit.
-
Extract the fields into a fixed schema and check them against the expected format and the source record. Pages that change or show an error stop the run, not guess.
-
Send any value that is missing, outside range or needed for money or legal status to a person. Write approved values to the internal system through its API.
-
Track run success rate, failed step and time per job. Pin the critical selectors and re-test them after each portal release.
Rather not build and maintain it yourself?
We build this agent around your own process, connect it to your tools, and keep it working as things change. You approve what matters; every action is logged.
Connecting your tools
- Playwright
- browser automation library for scripted and agent-driven sessions. Docs
- Selenium
- WebDriver standard for driving browsers when the team already has Selenium tests. Docs
- Browserbase
- hosted browser sessions with an API for agent runs. Docs
- Google Sheets
- Sheets API to store extracted rows for review. Docs
- QuickBooks Online
- REST API for bills and receipts once they are extracted. Docs
- Salesforce
- REST API to write vendor or account records. Docs
- Excel and CSV exports
- when a portal offers a download, prefer it to screen reading. No API, a file-based import.
Questions people search for
AI agent that can control a browser
Use a browser automation library such as Playwright (playwright.dev) or a hosted browser service, and let the model choose the next action from the page's accessibility tree or a screenshot. Playwright also has an MCP server that lets an agent drive the browser (github.com. Limit the agent to the domains the task needs.
AI agent that can log in to a website
Keep the credentials in a secrets vault or the browser's password store, never in the prompt. Use a dedicated service account with the least rights, and reuse the session cookie between runs when the site allows it. Stop and alert a person if the site asks for a new second factor.
How to automate your browser with AI agents
Check first for an API, export or CSV download, since those are more reliable than screen reading. If none exists, script the steps in Playwright, use the model only to read the page and decide on exceptions, and log every action with a screenshot.
AI agent that can interact with websites
The agent reads the page, fills forms, clicks and extracts values, with a step limit and a time limit per job. Verify each extracted value against the expected format before writing it anywhere. Re-test the critical steps after each site change, because layouts change often.
Pitfalls
- Portal layout changes that break selectors and the agent clicks the wrong button. Teams re-test the critical steps after every portal change and stop the run on unexpected pages.
- Terms of service that forbid automated access. Teams check each portal's terms and ask the owner for written permission or an export before automating.
- Credentials and session cookies exposed in logs or screenshots. Teams mask fields on screen and keep session data in the vault only.
- Costly loops on a slow page. Teams set a step limit and a time limit per job and alert on repeated retries.
Want this working in your company?
Tell us in a few lines how the work is done today. We reply to set up an online intro call.
Request sent
We will contact you to set up an intro call.