Blog

OpenHands vs Claude Code: Open Platform or Supervised Agent?

AI CodingTool Comparisons

OpenHands vs Claude Code is not two versions of the same tool. OpenHands is an open, model-agnostic platform you can self-host. Claude Code is Anthropic's own coding agent, built around Claude and run under Anthropic's terms.

  • Pick OpenHands if you want MIT-licensed code, any model (including local ones), and agents running on your own machines, VMs or Kubernetes.
  • Pick Claude Code if you want one polished agent with fine-grained permission modes, an OS-level sandbox for shell commands, and a Claude plan that covers the bill.
  • You don't have to choose only one. OpenHands' Agent Canvas can run Claude Code as one of its agents.

One more thing up front, because many comparison pages get it wrong: the OpenHands CLI is no longer actively maintained. If you searched "OpenHands CLI vs Claude Code", the OpenHands side of that match is now Agent Canvas.

Quick Comparison

OpenHandsClaude Code
SourceOpen source; main repo and SDK are MITNot open source; "All rights reserved"
Main interfaceAgent Canvas (browser UI, desktop app in preview)Terminal, VS Code, JetBrains, desktop app, web
ModelsAny LLM LiteLLM supports, plus local serversClaude models only
Where agents runYour machine, Docker, a VM, Kubernetes, or OpenHands CloudYour machine, or Anthropic-managed cloud VMs
Default isolationNone on a plain npm install; Docker or VM is opt-inBash sandbox off by default; cloud sessions run in a VM
ApprovalsConfirmation policies in the SDKPermission modes plus allow, ask and deny rules
ExtensionsSkills, hooks, plugins, MCPSkills, hooks, subagents, plugins, MCP
Headless and CIAutomations, Cloud API, SDK, GitHub Actions workflowclaude -p, Agent SDK, GitHub Action
Who bills youYour model provider; paid plans for teamsYour Claude plan, the Console API, or a cloud provider

What OpenHands Is in November 2026

If your picture of OpenHands comes from 2025, it's out of date. OpenHands introduced Agent Canvas as its main interface in June 2026, and the OpenHands introduction now lists four products:

ProductWhat it isWhere agents run
Agent CanvasThe open-source workspaceYour laptop, a VM, Docker, or another backend
OpenHands CloudThe hosted versionHosted sandboxes
OpenHands EnterpriseSelf-hosted for organizations, with SSO and rolesYour own infrastructure
Software Agent SDKA Python library for building agentsYour code, or an Agent Server you deploy

Agent Canvas installs with npm, npx or Docker, and a desktop app is in preview for macOS, Windows and Linux. The old terminal tool is gone from the recommended path: the OpenHands-CLI repo says it is no longer actively maintained and points to Agent Canvas.

The newest piece is commercial. On November 17, 2026, OpenHands introduced OpenHands Teams, a self-service way to deploy OpenHands Enterprise on your own infrastructure. Our OpenHands alternatives guide covers the rest of the history and who should move because of it. This post sticks to the head-to-head.

OpenHands vs Claude Code: Open Platform or First-Party Agent

The OpenHands repo, which holds Agent Canvas, is MIT licensed, and so is the Software Agent SDK. You can fork the interface, embed the SDK in your own product, and run the whole stack without asking anyone. One caution from OpenHands' own docs: each repository carries its own licence, so check the one you use rather than assuming one licence covers everything. Enterprise and Teams are commercial plans.

Claude Code has a public GitHub repository too, but its LICENSE file says "All rights reserved" and points to Anthropic's Commercial Terms. You can read the docs and file issues. You can't fork the agent. If open source is a hard requirement, our post on Claude Code alternatives lists the open options.

The bigger difference is what each project is trying to be:

  • OpenHands is a platform. The Agent Canvas README describes a self-hosted control center that runs OpenHands, Claude Code, Codex, Gemini CLI, Pi, OpenCode or any agent that speaks the Agent Client Protocol (ACP). It manages conversations, backends and automations around those agents.
  • Claude Code is the agent. It reads your codebase, edits files and runs commands in a session you supervise, across the terminal, IDE extensions, a desktop app and the web.

Model Choice and Bring Your Own Key

This is where the two split hardest.

OpenHands' LLM docs say it can connect to any LLM that LiteLLM supports, including local servers such as Ollama, LM Studio, vLLM and SGLang, OpenRouter, and a LiteLLM proxy. The same page warns that OpenHands needs a powerful model to work well and that open-weight models "still vary widely in tool-use reliability." There's also an OpenHands LLM provider you can use with a key from OpenHands Cloud; its docs say pricing follows official API provider rates.

Claude Code runs Claude models. You can reach them through Anthropic, or through Amazon Bedrock, Google Cloud's Agent Platform or Microsoft Foundry. Anthropic's gateway documentation is explicit that it "doesn't support routing Claude Code to non-Claude models through any gateway."

Running Claude Code Inside OpenHands

The ACP agents page explains how Agent Canvas launches Claude Code's own CLI as a subprocess and relays each turn to it. Claude Code then manages its own model, tools and execution. OpenHands says it reuses an existing Claude Code Pro/Max login on the same machine, or takes an ANTHROPIC_API_KEY.

Anthropic's legal and compliance page sets the conditions for running Claude Code inside other agent infrastructure: the Claude Code binary must not be modified, and each user must sign in with their own API key, Claude plan or cloud provider credential. It says an end user may sign in to the unmodified binary with their own subscription, while third parties may not route requests through Free, Pro, Max or Ultra credentials on behalf of their users. If you plan to use a team-shared OpenHands backend, check your setup against those conditions, or use API keys.

The built-in OpenHands agent is a different case. To run it on Claude models you need an Anthropic API key or a cloud provider key, billed per token.

Sandboxing and Permissions

Neither tool isolates your machine by default. Compare defaults to defaults, and opt-ins to opt-ins.

OpenHands. The plain npm install runs the agent server directly on your machine. The Agent Canvas setup page warns that agents and ACP processes can run shell commands and read or write files with your user account's permissions, and that Canvas "does not isolate them." Isolation is a deployment choice:

  • Run the whole stack in Docker, so the agent sees only mounted folders
  • Keep Canvas on the host and run each conversation in its own hardened container
  • Put the backend on a VM or Kubernetes cluster you control
  • Use OpenHands Cloud's managed sandboxes

For approvals, the Software Agent SDK's confirmation policies let you require approval for every action, for none, or only for actions a security analyzer marks as risky.

Claude Code. Approval is the main control. Its permission modes run from Manual (asks before most edits, shell commands and network calls) through accept-edits, plan and auto (a classifier model reviews actions) to dontAsk for locked-down CI and bypassPermissions for isolated containers only. The docs say auto mode is the built-in starting mode for interactive terminal and VS Code sessions on v2.1.283 or later. Deny rules block in every mode.

Isolation is opt-in. The Bash sandbox is off by default, runs on macOS, Linux and WSL2, and covers shell commands only; file tools, MCP servers and hooks run outside it. Cloud sessions are the exception: they run in an isolated, Anthropic-managed VM by default and keep going after you close your laptop.

The short version: OpenHands puts the boundary in your infrastructure. Claude Code puts it in the agent, with a sandbox on top if you turn it on.

Skills, Hooks and Subagents

The extension models have moved toward each other, which makes trying both cheaper.

OpenHandsClaude Code
Repo instructionsAGENTS.md; also reads CLAUDE.mdCLAUDE.md; can read AGENTS.md
SkillsAgent Skills SKILL.md, plus keyword triggers and path rulesSKILL.md skills, invoked by Claude or with /skill-name
Hooks.openhands/hooks.json, format compatible with Claude Code hooksShell, prompt and agent hooks at lifecycle events
SubagentsFile-based agents in Markdown, called by delegation (SDK)Subagents with their own context window, tools and permissions
PackagingPlugins bundling skills, hooks, MCP servers and agentsPlugins

The OpenHands hooks page says its format is compatible with Claude Code hooks, so you can reuse the same scripts across both tools. Claude Code's subagents each run in their own context window, and their requests count toward the same usage limits as your main conversation.

Headless Runs and CI

Both run without a person watching. They just start from different places.

Claude Code runs non-interactively with claude -p, per its headless docs, and the Agent SDK exposes the same loop in Python and TypeScript. In recent versions, -p runs with no mode set start in Manual and deny anything that needs approval, so give CI an exact allowlist or pass --permission-mode auto. The Claude Code GitHub Action responds to @claude mentions and can turn issues into pull requests.

OpenHands treats unattended work as a core feature. Automations in Agent Canvas, Cloud and Enterprise run on a schedule or on webhook events, such as a pull request opening or a new Linear issue. OpenHands Cloud has a REST API for starting conversations. The docs also include a PR review workflow for GitHub Actions built on the SDK.

If you want an agent on a cron, triggered from Slack, running on your own server, OpenHands is closer to ready out of the box. If you want a one-shot command in an existing pipeline, claude -p is the shorter path.

Cost Model

Neither tool has one simple price, so compare how the bill works.

OpenHands. The software is free to self-host under MIT. You pay your model provider directly, or pay for hardware if you run a local model. The docs describe OpenHands Cloud as the free hosted version, with a limit on how many conversations you can run. For teams, the OpenHands pricing page lists a paid self-hosted Teams plan with a set number of users included, and custom Enterprise pricing.

Claude Code. Most surfaces need a Claude subscription or an Anthropic Console account. Claude's pricing page lists Claude Code from the Pro plan up. Console use is billed per token. Cloud sessions count toward your plan's usage limits, and Anthropic says there's no separate charge for the cloud VM.

The practical difference: with OpenHands, model spend is yours to cap and route, including to cheaper or local models. With Claude Code on a plan, the bill is predictable and the limits are Anthropic's.

Which Should You Choose?

Your situationStart with
You need MIT-licensed code you can fork or auditOpenHands
You want local or open-weight modelsOpenHands
You want agents running on your own servers, on a scheduleOpenHands
You already pay for a Claude planClaude Code
You want granular permission modes and an OS sandbox for shell commandsClaude Code
You want one agent across terminal, IDE, desktop and webClaude Code
You want Claude Code, but inside a self-hosted control centerOpenHands Agent Canvas running Claude Code

If what you really want is an open terminal agent that feels like Claude Code, OpenHands isn't the closest match any more. Look at OpenCode vs Claude Code for that. For the agent inside your editor, see Cline vs Claude Code.

Where Taku Fits

OpenHands and Claude Code both help you build and change software. A lot of people don't want to run an agent stack at all. They just want to use an AI tool someone else already built.

If you'd rather run a tool someone already built than set one up yourself, that's where Taku comes in. Taku Apps and Sites, built by the best AI minds. Find one, run it, and keep it in your Mac Dock. Taku is in Beta, and the Mac app is available now.

Key Points

  • OpenHands is an open, MIT-licensed platform; Claude Code is Anthropic's proprietary agent.
  • The OpenHands CLI is no longer actively maintained. Agent Canvas is the main interface now.
  • OpenHands runs almost any model, including local ones. Claude Code runs Claude models only.
  • Neither isolates your machine by default. OpenHands isolates through Docker, VMs or Cloud; Claude Code through its opt-in Bash sandbox and cloud VMs.
  • Agent Canvas can run Claude Code through ACP, so the choice can be "both."
  • For CI, OpenHands leans on automations and its SDK; Claude Code on claude -p and its GitHub Action.

FAQ

Is OpenHands an open source Claude Code alternative?

Yes, in the sense that it's open source and does the same core job. The main OpenHands repo and the Software Agent SDK are MIT licensed, and you can run them with any supported model. It's shaped more like a platform than a single terminal agent, though.

Is the OpenHands CLI still maintained?

No. OpenHands' docs and the OpenHands-CLI repo both say it is no longer actively maintained, and the legacy openhands serve GUI is deprecated. OpenHands recommends Agent Canvas for local use.

Is Claude Code open source?

No. Its GitHub repository is public, but the LICENSE file says "All rights reserved" and points to Anthropic's Commercial Terms.

Can OpenHands use Claude models?

Yes. The built-in OpenHands agent can use Claude models through an Anthropic API key or a supported cloud provider. You can also run Claude Code itself as an ACP agent in Agent Canvas.

Can Claude Code use GPT, Gemini or local models?

Not as a supported setup. Anthropic says it doesn't support routing Claude Code to non-Claude models through any gateway.

Claude Code vs OpenHands: which is better?

Neither wins in general. Claude Code is the stronger pick for one supervised agent on a Claude plan. OpenHands is the stronger pick for self-hosting, model choice and scheduled automations. Run the same task in both on your own repository before you decide.

Which is safer to run on my laptop?

Neither, by default. A plain OpenHands install runs with your user's permissions, and Claude Code's Bash sandbox starts off. Run OpenHands in Docker or on a VM, or turn on Claude Code's sandbox and keep a strict permission mode.