---
site: steel.dev
collection: blog
canonical_url: https://steel.dev/blog/give-claude-code-a-real-browser
markdown_url: https://steel.dev/blog/give-claude-code-a-real-browser.md
content_signal: ai-input=yes, ai-train=yes, search=yes
related:
  - https://steel.dev/blog/introducing-steel-skills.md
  - https://steel.dev/blog/steel-browser-is-live-in-stripe-projects.md
  - https://steel.dev/blog/agent-traces.md
title: Give Claude Code a real browser
description: Steel CLI lets Claude Code automate real web apps like Gmail via a browser skill, turning messy sessions into reusable, self-healing scripts and skills.
date: 2026-04-02
authors:
  - Nikola Balic
category: Guides
minutes: 3
tldr: With Steel CLI, the steel-browser skill and an imported Chrome profile, Claude Code checked Gmail for unread mail, read a message and sent a reply while already logged in. It then wrote a repeatable bash script from the run and turned that into a Claude Code skill that patches the script when a selector changes.
topics:
  - Browser automation for coding agents
  - Agent skills
  - Browser profile import
  - Live session viewing
  - Self-healing scripts
entities:
  - Claude Code
  - Steel CLI
  - Steel
  - Gmail
  - Chrome
  - steel-browser
answers_questions:
  - How do I give Claude Code a real browser?
  - How do I import my Chrome profile into Steel?
  - How can Claude Code read and reply to Gmail?
  - How do I turn a browser session into a reusable Claude Code skill?
---

# Give Claude Code a real browser

Claude Code can reason, write code, and run shell commands. It cannot open a browser. It can't log into Gmail, read your inbox, or send a reply. If the task requires a real web page, the agent is stuck.

We wired Steel CLI into Claude Code and pointed it at Gmail. The agent checked for unread mail, read a message, drafted a reply, and sent it. Then we asked it to write a bash script so the whole thing is repeatable. Then we turned that script into a skill.

The whole session took a few minutes. Most of that was the agent fighting Gmail's UI.

[Video on YouTube](https://www.youtube.com/watch?v=dsGtUqJYXUI)

## Setup

Install Steel CLI:

```sh
curl -LsSf https://setup.steel.dev | sh
```

Install the browser skill so Claude Code knows how to operate Steel:

```sh
npx skills add https://github.com/steel-dev/cli --skill steel-browser
```

Import your local Chrome profile:

```sh
steel profile import --name your_profile_name
```

That last command copies cookies and login state from your Chrome into Steel. Sessions started with this profile inherit your existing auth, so Gmail, Slack, whatever else you're signed into just works. No credentials in plaintext, no OAuth dance.

## What happened

We gave Claude Code one instruction:

> Check my Gmail for unread email and propose a reply.

The skill loaded. Steel started a session with the imported profile. The agent navigated to Gmail, already logged in.

It found one unread message from Colin, opened it, read the content, and composed a reply. We watched the whole thing in Steel's live session viewer, which shows you exactly what the browser is rendering in real time.

It was not smooth. The agent clicked around, missed buttons, had to recover. Gmail is a mess of overlapping modals and async-loaded elements.

You can watch, intervene, and the agent recovers. That loop (agent tries, fumbles, human nudges, agent adjusts) is what separates a workflow from a demo.

## Session to script to skill

One email reply is a demo. What matters is what you do with the experience afterward.

We asked Claude Code:

> Based on lessons learned, write a repeatable bash script for this task that we can rerun.

It wrote a script: start a Steel session with the named profile, go to Gmail, find unread messages, read them, compose replies. The manual fumbling got distilled into concrete steps.

Then:

> Create a Claude Code skill from this script.

Now the workflow is packaged. Next time, the agent loads the skill, runs the script, and if a selector changed or a button moved, it reads the error and patches the script itself. The first run was messy. The script is cleaner. The skill is reusable. And because the agent wrote the script, it knows how to fix it.

Manual run, then bash script, then agent skill. Each step strips out fragility.

## What we learned

Profile import is the thing that makes this practical. Without it, every session starts logged out and the agent has to deal with OAuth, 2FA, credential entry. That's a whole category of problems you don't need.

Live session viewing is how you debug this. You're watching a real browser in Steel's dashboard. When the agent misclicks or gets lost, you see it happen and can step in. Without that visibility, browser automation is just guessing at what went wrong after the fact.

Web is hard. Buttons shift, elements load late, the DOM is deeply nested. The agent recovered from most of it, but expect some back-and-forth on the first few runs. This is not a solved problem, and we're not going to pretend it is.

The self-healing part is the best part. Once the agent has a script, it can diff what broke against what worked and patch it. Over a few runs the loop tightens. The agent starts handling Gmail without intervention. Not perfectly. Not every time. But enough that we actually use it.

## Try it

```sh
curl -LsSf https://setup.steel.dev | sh
npx skills add https://github.com/steel-dev/cli --skill steel-browser
steel profile import --name your_profile_name
```

Start with something small. Check email, pull a report from a dashboard, monitor a page for changes. Then ask the agent to write the script. Then make the skill.

- [Steel CLI docs](https://docs.steel.dev/overview/steel-cli)
- [Get a free API key](https://app.steel.dev/sign-up)
- [Join the Discord](https://discord.gg/steel-dev)
