vibedonaldsvibedonalds.com
Stagehand screenshot

Stagehand

Browserbase's open-source SDK for browser agents: natural-language act, extract and observe plus page APIs.

What is Stagehand, in two sentences

Stagehand is Browserbase's open-source SDK for browser agents in TypeScript, Python and Go: natural-language act, extract and observe calls sit next to Playwright-style page methods. It is under the MIT License; its Model Gateway and server-side caching need a Browserbase-hosted browser.

About Stagehand

A Stagehand script mixes two layers of control: the AI primitives act, extract and observe for natural-language steps that self-heal when a site changes, and Playwright-style page methods such as goto, click, type, locator and screenshot for deterministic steps, so you decide how much AI each step uses. Act performs an action, extract returns data validated against a schema you define, and observe discovers the actions available on a page.

It drives Chromium-based browsers such as Chrome, Edge, Arc and Brave over the Chrome DevTools Protocol, with no Playwright or Puppeteer dependency, and runs as an extension next to the browser to cut round-trip latency. The homepage lists WebMCP support, clipboard support, batched commands, deep locators for nested iframes and closed Shadow DOMs, a domain allowlist and blocklist, and built-in OTel tracing; metrics() reports token use and inference timing per method.

You can name a model from Google, Anthropic, OpenAI, Groq or Cerebras with your own API key, or pass a client-side callback for anything else, such as Amazon Bedrock, Cohere, Azure OpenAI or a self-hosted model. With no model set, Browserbase's Model Gateway picks one per call and bills inference through your Browserbase API key at the provider's price with no markup; it works only with Browserbase-hosted browsers.

Version 4 removed agent(): Stagehand is the hands, and you bring the agent as the brain, such as LangChain, CrewAI, Mastra or a custom loop, or have a coding assistant write a Stagehand script that you run. It installs as @browserbasehq/stagehand, needs Node.js 22.18, Python 3.11 or Go 1.26 or later, supports Bun, and needs Chrome installed for local runs.

Sources: stagehand.dev, docs.stagehand.dev/v4/first-steps/introduction, docs.stagehand.dev/v4/first-steps/installation, docs.stagehand.dev/v4/configuration/models, docs.stagehand.dev/v4/migrations/v3 and github.com/browserbase/stagehand, read 2026-10-27

Stagehand pros and cons

Pros

  • Licensed under the MIT License and maintained by Browserbase, with TypeScript, Python and Go SDKs whose methods and options match.
  • Deterministic page methods and natural-language calls can be mixed in one script, so only the steps that need a model spend inference.
  • Runs against a local Chrome as well as Browserbase-hosted browsers, and a client-side callback can wire in any model you can reach from code.
  • Through Model Gateway, Browserbase charges the provider's own token price with no markup and handles retries, backoff and rate limits.

Cons

  • Model Gateway and server-side caching need Browserbase-hosted browsers and do not work with local ones.
  • Moving from v3 takes rework: agent() is gone with no one-for-one replacement, and construction, page access and result shapes changed.
  • The docs name only Chromium-based browsers; Firefox and Safari are not mentioned.
  • There is no base URL option: a model configuration must name one of five providers, and Azure OpenAI deployments or other custom endpoints need the callback.

Tagged

  • Bring Your Own Key
  • Supports Claude
  • Supports GPT
  • Supports Gemini
  • CLI
  • Agentic Mode
  • Open Source

Stagehand alternatives

The closest alternatives to Stagehand.

  1. 01
    Browser Use

    Open-source browser agent under the MIT licence, plus a pay-as-you-go cloud of hosted agents and browsers.

    Freemium →
  2. 02
    Skyvern

    Open-source AI agents that log into portals, fill forms, download files and extract data in a real browser.

    Freemium →

Related reading

Reviews
No reviews yet — be the first to rate Stagehand.

Featured on Vibedonalds

Own Stagehand? Add this badge to your site to show you’re listed — and link back to your profile here.

Stagehand — Featured on Vibedonalds
<a href="https://vibedonalds.com/tools/stagehand" target="_blank" rel="noopener">
  <img src="https://vibedonalds.com/badge/featured-on-vibedonalds.svg" alt="Stagehand — Featured on Vibedonalds" width="240" height="60" loading="lazy" />
</a>

Frequently asked questions

Is Stagehand free?
Stagehand is free to use. There is no paid tier as of the last index update.
What are the alternatives to Stagehand?
The closest alternatives to Stagehand are Browser Use, Skyvern.
What are the downsides of Stagehand?
Model Gateway and server-side caching need Browserbase-hosted browsers and do not work with local ones. Moving from v3 takes rework: agent() is gone with no one-for-one replacement, and construction, page access and result shapes changed. The docs name only Chromium-based browsers; Firefox and Safari are not mentioned. There is no base URL option: a model configuration must name one of five providers, and Azure OpenAI deployments or other custom endpoints need the callback.
What is Stagehand?
Stagehand is Browserbase's SDK for browser agents. It pairs natural-language act, extract and observe calls with Playwright-style page methods in TypeScript, Python and Go, and drives Chromium-based browsers over the Chrome DevTools Protocol, either a local Chrome or a Browserbase-hosted browser.
Is Stagehand open source on GitHub?
Yes. The repository at github.com/browserbase/stagehand says the code is licensed under the MIT License. Local runs need Chrome plus a model provider key or your own LLM callback; Model Gateway and server-side caching need Browserbase-hosted browsers and bill through your Browserbase API key.
Does Stagehand v4 still have agent()?
No. The v3-to-v4 migration guide says agent() is gone and nothing in v4 replaces it one-for-one. Browserbase recommends code mode, where a coding assistant writes a Stagehand script that you run, or tool calling, where a model drives the browser through the full Stagehand API.
Which AI models does Stagehand support?
Google, Anthropic, OpenAI, Groq and Cerebras models are first-class, named with a provider prefix such as anthropic/claude-sonnet-5. Amazon Bedrock, Cohere, Azure OpenAI or a self-hosted model go through a client-side callback. On Browserbase-hosted browsers, Model Gateway can pick a model for each call.
Does Stagehand use Playwright?
No. Stagehand v4 drives the browser over the Chrome DevTools Protocol and has no Playwright or Puppeteer dependency, while keeping Playwright-style methods such as goto, click, locator and screenshot. Its docs include a guide for migrating from Playwright to v4.