Agentastic includes a built-in web browser so you can preview your application, inspect UI components, and debug JavaScript without switching to an external app. The browser runs on WebKit (the same engine as Safari) and exposes a CLI calledDocumentation Index
Fetch the complete documentation index at: https://docs.agentastic.dev/llms.txt
Use this file to discover all available pages before exploring further.
dev browser that AI agents can use to navigate pages, interact with elements, and verify their own changes — all from the terminal.
Opening a browser tab
Go to File > New Browser Tab. The tab opens tolocalhost:3000 by default (the http:// prefix is added automatically). You can navigate to any URL using the toolbar’s address bar.
Toolbar features
The browser toolbar provides standard navigation controls (back, forward, reload, address bar) plus four debugging tools:- Inspect element — inspect the DOM and CSS of any element on the page.
- Console — view JavaScript output, warnings, and errors.
- Screenshot — capture the current page to your clipboard.
- Open in Safari — open the current URL in your default browser.
React Grab
React Grab is a feature designed for React developers. It lets you click on any rendered component to extract its source location, so you can tell an AI agent exactly which file and line to edit.Hover over a component
Move your cursor over the page. React components are highlighted as you hover.
Console
Click the</> button in the toolbar to toggle the console panel. The console captures:
| Output type | Appearance |
|---|---|
console.log() | Standard output |
console.info() | Informational messages |
console.warn() | Warnings (yellow) |
console.error() | Errors (red) |
| Uncaught exceptions | Highlighted in red |
| Unhandled promise rejections | Highlighted in red |
Screenshot
Screenshots are useful for sharing bug reproductions with AI agents, documenting UI states, and creating visual references for design feedback.
Open in Safari
Click the Safari button to open the current URL in your default browser. Use this when you need full DevTools, browser extensions, or compatibility testing in a different rendering engine.Browser automation for agents
Agentastic exposes the built-in browser to AI agents via thedev browser CLI. An agent running in a terminal tab can navigate pages, inspect the DOM, fill forms, click elements, and read console output — programmatically and without human intervention.
How it works
When Agentastic opens a terminal, it injects two environment variables automatically:| Variable | Purpose |
|---|---|
AGENTASTIC_SOCKET_PATH | Unix socket path for IPC communication |
AGENTASTIC_BROWSER_ID | ID of the browser tab in the current editor pane |
dev browser CLI communicates with the app over this socket using JSON-RPC. Agents like Claude Code can call dev browser commands directly within their terminal sessions.
Quick start
Open a browser tab, then run commands from the terminal:Element references (@eN)
When you rundev browser snapshot, the DOM tree is returned with @eN references assigned to each interactive element:
Element references are stable within a snapshot session but reset when you take a new snapshot.
Command categories
| Category | Commands |
|---|---|
| Navigate | navigate, back, forward, reload |
| Inspect | snapshot, screenshot, get title, get text, highlight |
| Interact | click, fill, type, press, keydown, keyup, check, select, hover |
| Wait | wait selector, wait text, wait url, wait load |
| Query | is visible, is enabled, get attr, get count, get styles |
| Find | find role, find text, find label, find alt, find title, find first/last/nth |
| Console | console list, console errors, console clear, errors list |
| Dialogs | dialog accept, dialog dismiss |
| Cookies | cookies get, cookies set, cookies clear |
| Storage | storage get, storage set, storage clear |
| State | state save, state load |
| Frames | frame select, frame main |
| Tabs | list, open, close, focus_tab, tab new/list/switch/close |
| Injection | addinitscript, addscript, addstyle |
Example: agent testing a login flow
An AI agent can verify a login page end-to-end without any manual steps:Security
The socket only accepts connections from your user account, verified via peer UID. No other user on the system can access the browser automation API.Limitations
The built-in browser:- Uses WebKit (Safari’s engine), not Chrome or Firefox.
- Does not support browser extensions.
- Provides simplified DevTools — the console panel only; no full element inspector.
- May render pages differently from Chrome or Firefox.