OpenClaw

OpenClaw Tools & Browser Automation👨‍💻

Tools give OpenClaw agents the ability to take actions beyond generating text. Out of the box, agents can browse the web, execute code, run shell commands, interact with APIs, and manage files. You can also define custom tools using SKILL.md files and share them via ClawHub. Tools follow a strict allow/deny model -- each agent can only use the tools explicitly granted to it, enforcing the principle of least privilege.

Key Takeaways

  • 1Built-in tools include browser automation (web browsing, screenshot, click, fill forms), code execution, shell commands (bash), file operations (read, write, search), and apply_patch for structured code edits.
  • 2Tools are scoped per agent via `tools.allow` and `tools.deny` lists. An agent only has access to tools in its allow list and can be explicitly blocked from tools via the deny list. This is critical for security in multi-agent setups.
  • 3SKILL.md files define reusable tool bundles with instructions. A skill is a self-contained capability (like 'deploy to AWS' or 'run database migrations') that includes tool definitions, usage instructions, and safety guidelines.
  • 4ClawHub is the registry for sharing and discovering skills. You can install community-created skills with `openclaw skills install` and publish your own with `openclaw skills publish`.
  • 5Browser automation enables agents to browse the web, take screenshots, fill forms, and extract data from web pages. This is powered by a headless Chrome instance managed by the Gateway.
  • 6The elevated mode system provides a way for agents to request temporary access to restricted tools. This requires explicit user approval and is logged for audit purposes.

Master openclaw tools & browser automation

Take the Introduction to OpenClaw course with hands-on lessons and challenges.

Examples

Per-agent tool access control

json

The code-reviewer can only read files, search, and run linters -- it cannot write files, execute arbitrary commands, or deploy. The deployer can run shell commands and deploy but cannot modify source files. This follows least privilege: each agent has exactly the tools it needs and nothing more.

Using browser automation in an agent

json

The researcher agent has access to browser automation tools. It can navigate to URLs, take screenshots, click elements, fill forms, and extract structured data from pages. The browser runs headlessly with a 30-second timeout to prevent runaway sessions.

Creating a SKILL.md for a reusable capability

markdown

A SKILL.md bundles tool usage instructions with safety guidelines into a reusable capability. This skill teaches the agent how to run database migrations safely. When installed, the instructions are added to the agent's system prompt alongside its SOUL.md and other bootstrap files.

Installing and managing skills from ClawHub

bash

ClawHub is the community registry for OpenClaw skills. You can search for skills by keyword, install them to add capabilities to your agents, and publish your own. Skills are versioned and can be updated independently of the Gateway.

Elevated mode for temporary tool access

bash

Elevated mode is a controlled way for agents to request access to tools they do not normally have. It requires explicit user approval, is time-limited (maxDuration in seconds), and all elevated actions are logged. This provides flexibility while maintaining an audit trail.

Common Mistakes

Mistake:

Giving all agents access to all tools by leaving the tools.allow list empty or using a wildcard

Fix:

Explicitly list the tools each agent needs. A code review agent should never have bash or deploy access. A support agent should not have file_write. Follow least privilege rigorously.

Mistake:

Not configuring the browser timeout, causing browser automation tasks to hang indefinitely when a page fails to load

Fix:

Always set a timeout for browser operations (30 seconds is a good default). Also configure the viewport size so screenshots and element positions are consistent.

Mistake:

Creating overly broad skills that try to cover too many scenarios instead of focused, single-purpose capabilities

Fix:

Each SKILL.md should cover one capability (e.g., 'database migration', 'deploy to AWS', 'run tests'). Composing multiple focused skills is better than one monolithic skill document.

Mistake:

Disabling the elevation approval requirement for convenience, allowing agents to escalate their own privileges without user consent

Fix:

Always require approval for elevated access (requireApproval: true). An agent that can grant itself additional tools is a security risk, especially for tools like bash and deploy.

Best Practices

  • Start each agent with the minimum set of tools and add more only when you identify a specific need. It is easier to add a tool than to revoke one after an incident.
  • Use the deny list as a safety net even when the allow list is restrictive. Explicitly denying dangerous tools like 'bash' or 'deploy' for agents that should never use them provides defense in depth.
  • Write SKILL.md files with clear safety rules. The agent will follow the instructions literally -- if you forget to say 'always back up before destructive operations', it will not do it on its own.
  • Test browser automation with headless: false first (visible browser) to debug selectors and navigation flows before switching to headless mode for production.
  • Monitor elevated access logs regularly. Frequent elevation requests may indicate that an agent's base tool set is too restrictive and should be expanded.
  • Version-control your SKILL.md files. Skill instructions directly affect agent behavior and should be reviewed with the same rigor as code changes.

Summary

Tools extend OpenClaw agents beyond text generation into actions: browsing, code execution, shell commands, and custom capabilities. Access is controlled per agent via allow/deny lists following least privilege. SKILL.md files bundle tool instructions into reusable capabilities shared via ClawHub. Browser automation requires a headless Chrome instance with timeout configuration. Elevated mode provides controlled, auditable temporary access to restricted tools. Always start with minimal tool access and expand based on demonstrated need.

Practice OpenClaw with hands-on challenges

Learn openclaw tools & browser automation hands-on in your IDE

Interactive lessons and challenges on Stanza, practice in VS Code, Cursor, or the web.

Related Concepts

Related Cheatsheets

Master OpenClaw with Stanza

Interactive lessons and challenges, right in your code editor.

Check the free courses. No credit card.