OpenAI (GPT) with OpenClaw
Configure GPT-4, GPT-3.5, and Codex — OAuth or API key
Configure GPT-4, GPT-3.5, and Codex — OAuth or API key
OpenAI's GPT models are supported in OpenClaw for chat, code generation, and general-purpose tasks. OpenClaw integrates with ChatGPT Plus via OAuth (subscription) or with API keys for pay-as-you-go and team usage. Models include GPT-4, GPT-3.5, and Codex (including gpt-5.3-codex for advanced code generation).
gpt-5.3-codex)Configure model in your Gateway config, e.g. openai/gpt-4. Use tiered routing: reserve GPT-4 for important work; use GPT-3.5 for heartbeats and background tasks. See Example Setups & Cost.
OAuth (subscription): If you have ChatGPT Plus, you can authenticate with your subscription—no API key. Uses your subscription limits. Set up during openclaw onboard or in the Setup Wizard.
API key: Create an API key at platform.openai.com. Use for pay-as-you-go or when you prefer key-based auth. Store in ~/.openclaw/credentials or via openclaw secrets.
{
"agent": {
"model": "openai/gpt-4"
}
}
Authentication is configured during onboarding or via credentials. See Configuration guide for full options.