Codex alternatives: keep GPT, add every other model
Most people searching for a Codex alternative want more than OpenAI's models, not less of Codex. OHarness can use your ChatGPT plan through the Codex login and put Claude, Gemini, DeepSeek and local models beside it in the same session.
Facts about Codex checked against its own documentation on . Sources are listed below.
Why people look for a Codex alternative
- Wanting Claude, Gemini or open models for some tasks, without a second tool.
- Hitting ChatGPT plan limits mid-task and needing somewhere else to continue.
- An endpoint that only speaks Chat Completions — DeepSeek, a vLLM server, a company gateway — which Codex's custom providers do not accept: they must speak the Responses API.
- Wanting a browser or desktop UI and a terminal on the same sessions.
What to check
| Ask | Why it matters | OHarness |
|---|---|---|
| Can it still use GPT? | Leaving Codex should not mean leaving OpenAI's models. | Yes — with an OpenAI API key, or your ChatGPT plan through the openai-codex provider. |
| Which other vendors are native? | A translating gateway in the middle is one more thing to break. | Anthropic and Gemini natively; DeepSeek, Kimi, GLM, Qwen, OpenRouter and 30+ others catalogued. |
| Does any OpenAI-compatible endpoint work? | Most self-hosted and regional endpoints speak Chat Completions, not Responses. | Yes — Chat Completions and the Responses API are both supported. |
| What happens to the session when you switch model? | Switching is only useful if the context survives it. | Nothing is converted: history is vendor-neutral and rendered per request. |
| How is the agent contained? | Codex's OS sandbox is a real strength; know what you are trading. | Permission rules and writable roots, not an OS sandbox. Use a container when you need confinement. |
| Can it run unattended? | codex exec is how many teams use Codex in CI. | oharness-headless streams JSONL; prompts are denied rather than silently approved. |
What OHarness does not replace
- Codex Web's cloud tasks. OHarness runs on your machine or your runner, not in OpenAI's cloud.
- An OS-enforced sandbox with the network off by default. OHarness enforces rules on tool calls instead.
- An IDE extension. OHarness works beside your editor from the terminal, browser or desktop app.
The options
Named without being ranked, and linked so you can check each against its own authors.
- Claude Code — Anthropic's terminal agent, Claude models.
- Gemini CLI — Google's terminal agent, Gemini models, free tier.
- OpenCode — Open source terminal agent, many providers.
- Cline — IDE extension with a CLI, many providers.
- Aider — Terminal pair programmer built around git.
Side by side on every point above: OHarness vs Codex.
Common questions
What is the best alternative to OpenAI Codex?
It depends on why you are leaving. For Claude models, Claude Code; for a free tier on Gemini, Gemini CLI; to keep GPT and add other vendors in the same session, a model-agnostic harness such as OHarness or OpenCode.
Can I use my ChatGPT subscription outside Codex?
Yes, in OHarness. Its openai-codex provider reads the token that codex login stores and uses it for GPT models on your plan. OHarness never refreshes that token itself, so your own codex command stays signed in.
Is there a ChatGPT alternative for coding?
For agentic coding — reading a repository, editing files, running tests — the alternatives are coding agents rather than chat apps: Codex, Claude Code, Gemini CLI, OpenCode, Cline, Aider and OHarness. OHarness runs any of GPT, Claude, Gemini, DeepSeek or a local model behind one agent.
Does Codex CLI work with DeepSeek or a local model?
Codex CLI runs local models through --oss with Ollama or LM Studio. Custom hosted providers must speak OpenAI's Responses API, so Chat Completions-only endpoints such as many DeepSeek and vLLM deployments need a translating gateway. OHarness speaks Chat Completions directly.
Sources
- Codex README
- Codex config reference (model_providers, wire_api)
- Codex approvals and security
- Codex pricing
Install OHarness · Claude Code alternatives · All guides and comparisons