Add your API key in OpenClaw

Where and how you add your key depends on how you run OpenClaw: on ClawNode (we host it) or self-hosted (you run OpenClaw yourself).

Using ClawNode (we host your OpenClaw)

Add your API key on your instance page using Onboard (keys only), then connect WhatsApp, Telegram, or Discord via Quick connects.

When you subscribe, we provision your OpenClaw instance. You bring your own LLM key - get one from the steps above (Anthropic or OpenAI), then add it on your instance page.

  1. Once your instance is Ready, go to the dashboard and open your instance (click the instance name or Details under "Your AI").
  2. On the instance page, find the Onboard section.
  3. Add at least one API key (Anthropic and/or OpenAI) from the steps above, then click Push API keys. Your key(s) are sent to the instance; your AI will use them for model calls.
  4. Optional: To chat over WhatsApp, Telegram, or Discord, use the Quick connects section on the same page: Connect WhatsApp (scan QR), or Set up Telegram or Discord (add bot tokens).

You pay the provider (Anthropic/OpenAI) directly for token usage.

Self-hosted OpenClaw

You run OpenClaw on your own server or machine.

OpenClaw reads API keys from its config file or from environment variables. The config file is usually ~/.openclaw/openclaw.json.

Option A: Config file

Add keys under env in openclaw.json:

{
  "gateway": { ... },
  "env": {
    "ANTHROPIC_API_KEY": "sk-ant-api03-your-anthropic-key",
    "OPENAI_API_KEY": "sk-your-openai-key"
  },
  "agents": {
    "defaults": {
      "model": { "primary": "anthropic/claude-sonnet-4-5" }
    }
  }
}

Option B: Environment variables

Set ANTHROPIC_API_KEY and/or OPENAI_API_KEY in the environment where you start OpenClaw (e.g. in your systemd unit, .env, or shell). OpenClaw will use these when making API calls.

Using SSH? See Add your model via SSH for a step-by-step CLI guide.

Sign up

Welcome to ClawNode

Get your personal AI assistant in minutes.

or

By selecting Agree and continue, I agree to ClawNode's Terms of Service and Privacy Policy.

or

Already have an account? Log in