Skip to main content

Basic Usage

Global Options

Subcommands

serve

Launch the OpenHands GUI server using Docker.
Examples:

web

Launch the CLI as a web application accessible via browser.
Examples:

cloud

Create a new conversation in OpenHands Cloud.
Examples:

acp

Start the Agent Client Protocol server for IDE integrations.
Examples:

mcp

Manage Model Context Protocol server configurations.

mcp add

Add a new MCP server.
Examples:

mcp list

List all configured MCP servers.

mcp get

Get details for a specific MCP server.

mcp remove

Remove an MCP server configuration.

mcp enable

Enable an MCP server.

mcp disable

Disable an MCP server.

login

Authenticate with OpenHands Cloud.
Examples:

logout

Log out from OpenHands Cloud.
Examples:

Interactive Commands

Commands available inside the CLI (prefix with /):

Command Palette

Press Ctrl+P (or Ctrl+\) to open the command palette for quick access to:

Changing Your Model

Via Settings UI

  1. Press Ctrl+P to open the command palette
  2. Select Settings
  3. Choose your LLM provider and model
  4. Save changes (no restart required)

Via Configuration File

Edit ~/.openhands/agent_settings.json and change the model field:

Via Environment Variables

Temporarily override your model without changing saved configuration:
Changes made with --override-with-envs are not persisted.

Environment Variables

Exit Codes

Configuration Files

See Also