Custom model providers
Providers lets you use models from OpenRouter, DeepSeek, Ollama, and other providers in the Codex app. Each model runs on a custom-model account: a non-OpenAI model inside the official Codex app, with its own isolated Codex home, its own credential, and its own model list. It is not an OpenAI account and does not use one.
/responses or /chat/completions endpoint, and you need a credential for it. CodexUse stores that credential encrypted in CodexUse's private app database.How it fits together
Three objects, each doing one job:
- Provider: the vendor, with a name, a base URL, and a credential. One provider can serve many models.
- Model: one model on that provider, with the upstream model ID, its name in Codex, the API style it speaks, and its reasoning behavior.
- Custom-model account: an account with its own Codex window, bound to one provider and the tested models you chose for it.
A local gateway on 127.0.0.1 sits between the Codex app and your provider. It presents the Responses API to Codex, translates to whatever the provider speaks, and serves a catalog containing only that account’s models.
Add a provider
- Open Providers in the For agents group of the CodexUse sidebar, and click Add a provider (Add provider once you have one).
- Pick a provider from Hosted providers or Local servers, or choose Another provider for any other API that works like OpenAI’s.
- Enter the name, the base URL, and the API key, then click Add provider. Use the vendor’s name only; do not put the API style or a model name in it. Ollama and LM Studio need no API key.
- CodexUse opens the model form next. Choose a model from its list, click Save and test, then Run the test. CodexUse sends a test request and reports any provider error before the model appears in the Codex model picker.
Add models
- Click Add model on the provider. Pick the Model ID after Read model list, or type it exactly as the provider writes it.
- Under API compatibility, click Change to set the API style: Chat Completions or Responses. This is a property of the model, not the provider; one provider can host both.
- Set its Name in Codex. It defaults to the model ID, and you can rename it without changing routing.
- Click Save and test, then Run the test. Only a model that passes its test reaches the Codex model picker.
Reasoning effort
Effort values are resolved in a strict order, and CodexUse never invents them:
- Your own override, if you set one.
- Metadata the provider returns.
- An exact Models.dev match on both the API URL and the model ID.
- Otherwise: no effort parameter is sent and the provider decides.
Matching requires the URL and the ID, because the same model ID can behave differently on different providers. If a model advertises low, high, and max, the Codex picker shows exactly those three; Codex labels low as “Light”. Your selection survives a restart.
Create the account
- Open Accounts, click Add account, and choose Custom model.
- Choose a provider, select a model, then name and create the account. CodexUse tests the connection before finishing.
- Click Open. CodexUse provisions an isolated Codex home, writes the model catalog, and opens the Codex window for that account.
What stays isolated
- Each account gets its own Codex home, its own history, and its own app state.
- The provider credential stays encrypted in CodexUse's private app database and is never written into
config.toml. - The gateway accepts a per-account capability only, compared in constant time, so one account cannot reach another’s models.
- The catalog served to a custom-model account contains only that account’s models. No OpenAI models appear in it.
- Your normal ChatGPT app and its sign-in are untouched.
Changing models later
Editing the account’s model list re-provisions the account and needs a window restart to take effect. A valid effort selection is preserved across re-provisioning.
What this does not claim
- CodexUse is not affiliated with OpenAI, and this is not a way around OpenAI billing. A custom-model account does not call OpenAI at all. It calls the provider you configured, with your own credential, and you pay that provider directly.
- An account is either an OpenAI account or a custom-model account. It is never both. Your OpenAI accounts keep using ChatGPT exactly as before.
- Hosted ChatGPT features do not work on a custom-model account. Dictation, browser remote control, and anything that calls ChatGPT’s own backend need a ChatGPT account. Chat, tool calls, and reasoning controls depend on the configured model, its capabilities, and the provider protocol.
- Your provider must speak the OpenAI Responses or Chat Completions shape. Providers with a bespoke protocol are not supported.
- Apple Silicon macOS, Windows 11 x64, or Ubuntu 24.04 on x64 or arm64. Intel Mac desktop builds are not shipped. Custom-model accounts run on all three; giving each account its own Codex window needs macOS.
- You are responsible for the third-party provider’s terms and costs, and for reviewing your own OpenAI plan terms.