SunsetDiff

Replacement for codex-mini-latest: what changes when you switch

The official replacement is gpt-5-codex-mini. codex-mini-latest shut down on 2026-02-12 per OpenAI's deprecation page (checked 2026-10-17). Published on the official docs: input price $1.5 per million tokens, context window 200,000 tokens, max output 100,000 tokens.

codex-mini-latest model page · OpenAI

Official replacement. Full diff page

codex-mini-latest to gpt-5-codex-mini

Some values not published Checked 2026-10-17.

Price per 1M tokens

Price comparison. Example monthly cost for 10M input tokens and 2M output tokens. Labeled example, not a bill.
FieldOldNewChange
Input $1.5 Not published Not published
Output $6 Not published Not published
Cached input $0.375 Not published Not published
Example monthly cost $27 Not published Example only

Context and max output

Token limits
LimitOldNewChange
Context window 200,000 Not published Not published
Max output 100,000 Not published Not published

Capabilities that differ

No differing capability values are published for both models.

API changes

No parameter change is listed on the official pages we checked. The sample below only swaps the model id.

Code

python before
from openai import OpenAI
client = OpenAI()
response = client.chat.completions.create(
    model="codex-mini-latest",
    messages=[{"role": "user", "content": "Hello"}],
)
python after
from openai import OpenAI
client = OpenAI()
response = client.chat.completions.create(
    model="gpt-5-codex-mini",
    messages=[{"role": "user", "content": "Hello"}],
)
typescript before
import OpenAI from "openai";
const client = new OpenAI();
const response = await client.chat.completions.create({
  model: "codex-mini-latest",
  messages: [{ role: "user", content: "Hello" }],
});
typescript after
import OpenAI from "openai";
const client = new OpenAI();
const response = await client.chat.completions.create({
  model: "gpt-5-codex-mini",
  messages: [{ role: "user", content: "Hello" }],
});
curl before
curl https://api.openai.com/v1/chat/completions \
  -H "Authorization: Bearer $OPENAI_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model":"codex-mini-latest","messages":[{"role":"user","content":"Hello"}]}'
curl after
curl https://api.openai.com/v1/chat/completions \
  -H "Authorization: Bearer $OPENAI_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model":"gpt-5-codex-mini","messages":[{"role":"user","content":"Hello"}]}'

Checklist

  1. Read the shutdown date for codex-mini-latest on the linked official page.
  2. Point your requests at gpt-5-codex-mini.
  3. Re-check price, context, and parameters on the provider pages linked here.
  4. Ship the change before the published shutdown date.

Related models

Questions

What is the replacement for codex-mini-latest?

The official replacement is gpt-5-codex-mini. codex-mini-latest shut down on 2026-02-12 per OpenAI's deprecation page (checked 2026-10-17). Published on the official docs: input price $1.5 per million tokens, context window 200,000 tokens, max output 100,000 tokens.

Is gpt-5-codex-mini cheaper than codex-mini-latest?

A full price comparison is not published. One or both prices are missing from the official pages we checked.

Does gpt-5-codex-mini have a bigger context window than codex-mini-latest?

Context window sizes are not both published on the official pages we checked.

Sources

Deprecation alerts

We store your email for deprecation alerts. We do not send email.

Deprecation alert signup
Providers (optional)