Developer2026-07-02

Codex Supports DeepSeek Through Third-Party Model Providers

Checked on July 2, 2026: OpenAI's Codex docs now document custom model providers through `model_provider`, `model_providers`, `base_url`, and `env_key`. That means DeepSeek can be framed as a third-party Codex route: use our DeepSeek access, point Codex at the configured DeepSeek provider, and keep the known Responses API, profile, Desktop picker, and V4 thinking-mode checks in place.

What changed after the June Claude Code item

Claude Code is no longer the messy part of the story. DeepSeek's own docs give teams a direct Anthropic-compatible route: point Claude Code at https://api.deepseek.com/anthropic, use deepseek-v4-pro[1m] for the main lane, keep deepseek-v4-flash for subagents, and set the effort level to max.

That is still worth a fresh update because the same DeepSeek page now carries three practical details that older community snippets often miss: Web Search can run through DeepSeek, Claude-style model names can map to V4 Pro or V4 Flash, and search-triggered summarization costs extra model tokens. This is a setup contract, not just a screenshot walkthrough.

Codex now has a third-party provider path

Codex now supports third-party access through custom model providers. OpenAI's own Codex configuration docs show the shape: define a provider with base_url and env_key, then point model_provider at it. The configuration reference also says provider settings belong in the user-level ~/.codex/config.toml, because project-local config cannot redirect provider or auth settings.

For this site, the cleaner wording is: use DeepSeek as the third-party Codex provider. If a reader already has our DeepSeek access, they do not need a separate Codex-specific DeepSeek product. They configure Codex with the DeepSeek base URL and key from their access details, then select the DeepSeek V4 model name that matches the task.

A minimal user-level shape looks like this:

model = "deepseek-v4-pro"
model_provider = "deepseek"

[model_providers.deepseek]
name = "DeepSeek"
base_url = "<your DeepSeek access base URL>"
env_key = "DEEPSEEK_API_KEY"
wire_api = "responses"

The exact base URL depends on the access route. A direct official key, a dashboard-delivered key, or a compatibility gateway may expose slightly different base URLs. The idea is the same: Codex talks to a custom provider, and the DeepSeek key or route supplies the model.

Checks still worth keeping

Third-party support does not remove every operational edge. Keep these checks in the article so readers know what to verify instead of assuming the model picker proves the route is correct.

  • DeepSeek thinking mode can fail in multi-turn Codex sessions if reasoning_content is not passed back after tool-use turns.
  • Codex Desktop has separate reports around custom-provider model catalogs and picker visibility, especially when users expect GUI switching instead of manual config.toml edits.
  • A June report says Codex CLI 0.14.0 ignored --profile and custom model_providers in one setup, falling back to OpenAI instead of the configured DeepSeek-shaped provider.
  • Another report says Codex auto-review can send codex-auto-review to a custom DeepSeek provider, which DeepSeek rejects because it only recognizes its own V4 model names.

Those are implementation checks, not a reason to avoid the route. The honest headline is now simpler: Claude Code has a DeepSeek-documented Anthropic path, and Codex has an OpenAI-documented third-party provider path. Use our DeepSeek access for the DeepSeek side, then verify that Codex is actually sending traffic to that provider.

Sources