# How to use OpenHands with Subconscious

> To use OpenHands with Subconscious, open its LLM settings, enable Advanced, and set Custom Model to `openai/subconscious/glm-5.3-marathon`, Base URL to `https://api.subconscious.dev/v1`, and API Key to your Subconscious key. The `openai/` prefix tells OpenHands to treat Subconscious as an OpenAI-compatible endpoint.

Canonical page: https://www.subconscious.dev/agents/terminal-and-ide/openhands
Category: [Terminal and IDE agents](https://www.subconscious.dev/agents/terminal-and-ide)
Last verified: 2026-09-30
OpenHands: https://openhands.dev
Source: https://github.com/OpenHands/OpenHands

## Before you start

- Python 3.12 and uv, or the OpenHands install script
- A Subconscious account and API key

## Set up OpenHands

### 1. Install OpenHands

Or use the install script: curl -fsSL https://install.openhands.dev/install.sh | sh

```bash
uv tool install openhands --python 3.12
```

### 2. Create a Subconscious API key

Sign in at https://platform.subconscious.dev and create an API key. You will paste it into the settings screen below.

### 3. Open the LLM settings

Run openhands. The first run asks for LLM settings; later, press Ctrl+P and open Settings. In the web GUI, use the LLM tab.

```bash
openhands
```

### 4. Point OpenHands at Subconscious

Enable Advanced, then fill in these fields. The openai/ prefix marks Subconscious as an OpenAI-compatible endpoint. Settings are saved to ~/.openhands/settings.json.

- Custom Model: `openai/subconscious/glm-5.3-marathon`
- Base URL: `https://api.subconscious.dev/v1`
- API key: `Your Subconscious API key`

## Connection details

- OpenAI-compatible base URL: https://api.subconscious.dev/v1
- Anthropic-compatible base URL: https://api.subconscious.dev
- API key: From subc login or the Subconscious dashboard
- Model: subconscious/glm-5.3-marathon
- Multimodal, high-throughput model: subconscious/deepseek-v4.1-flash-marathon

Full API reference: https://docs.subconscious.dev

## Frequently asked questions

### Can I configure OpenHands with environment variables instead?

Yes, for one run. Set LLM_MODEL=openai/subconscious/glm-5.3-marathon, LLM_BASE_URL=https://api.subconscious.dev/v1 and LLM_API_KEY to your key, then start openhands --override-with-envs. These values are not saved.

### Which Subconscious model should I use with OpenHands?

Start with subconscious/glm-5.3-marathon, an open frontier coding model built for long agent runs. subconscious/deepseek-v4.1-flash-marathon is a cheaper, high-throughput alternative that also takes image input. Use the full model ID, including the subconscious/ prefix.

### Is OpenHands on Subconscious OpenAI- or Anthropic-compatible?

This guide connects OpenHands through the OpenAI-compatible Subconscious API. Subconscious serves both formats: OpenAI Chat Completions at https://api.subconscious.dev/v1 and Anthropic Messages at https://api.subconscious.dev.

### How is OpenHands usage on Subconscious billed?

Per token by default, with no commitment. Heavy users can switch to a monthly token plan: a fixed price for a large daily token allowance shared across your team.
