Overview
The OpenHands CLI provides commands to interact with OpenHands Cloud directly from your terminal. You can:
- Authenticate with your OpenHands Cloud account
- Create new cloud conversations
- Use cloud resources without the web interface
Authentication
Login
Authenticate with OpenHands Cloud using OAuth 2.0 Device Flow:
This opens a browser window for authentication. After successful login, your credentials are stored locally.
Custom Server URL
For self-hosted or enterprise deployments:
You can also set the server URL via environment variable:
Logout
Log out from OpenHands Cloud:
Creating Cloud Conversations
Create a new conversation in OpenHands Cloud:
Options
| Option | Description |
|---|
-t, --task TEXT | Initial task to seed the conversation |
-f, --file PATH | Path to a file whose contents seed the conversation |
--server-url URL | OpenHands server URL (default: https://app.all-hands.dev) |
Examples
Workflow
A typical workflow with OpenHands Cloud:
-
Login once:
-
Create conversations as needed:
-
Continue in the web interface at app.all-hands.dev or your custom server
Environment Variables
| Variable | Description |
|---|
OPENHANDS_CLOUD_URL | Default server URL for cloud operations |
Cloud vs Local
| Feature | Cloud (openhands cloud) | Local (openhands) |
|---|
| Compute | Cloud-hosted | Your machine |
| Persistence | Cloud storage | Local files |
| Collaboration | Share via link | Local only |
| Setup | Just login | Configure LLM & runtime |
| Cost | Subscription/usage-based | Your LLM API costs |
Use OpenHands Cloud for collaboration, on-the-go access, or when you don’t want to manage infrastructure. Use the local CLI for privacy, offline work, or custom configurations.
See Also