# dall-e-2

Calls to the model dall-e-2 on OpenAI stopped working on May 12, 2026.

On May 12, 2026, the dall-e-2 model was retired. Requests targeting model dall-e-2 fail since that date. The change took effect following the scheduled shutdown date for the system.

## The error OpenAI returns once dall-e-2 is gone

HTTP 404

```json
{"error":{"message":"The model `dall-e-2` has been deprecated, learn more here: https://platform.openai.com/docs/deprecations","type":"invalid_request_error","param":null,"code":"model_not_found"}}
```

## What to use instead

Move to gpt-image-2, as the other suggested alternatives are either retired or retiring soon, with gpt-image-1 having stopped working on October 23, 2026, and gpt-image-1-mini stopping on December 1, 2026. This transition requires more than updating the model ID: gpt-image-2 always returns base64 in data[].b64_json because response_format is unsupported, meaning you must decode and store the bytes yourself. Additionally, there is no equivalent replacement for the DALL·E 2 variations call at /v1/images/variations.

gpt-image-2 always returns base64 (data[].b64_json), never a URL: response_format is unsupported, so store or serve the decoded bytes yourself. There is no equivalent of the DALL·E 2 variations call (/v1/images/variations).

- API: OpenAI (api.openai.com)
- Model: dall-e-2
- Kind: Model retirement
- Takes effect: May 12, 2026
- Calls after that day: fail
- Calls it hits: `model dall-e-2`
- Source: [Deprecations page](https://developers.openai.com/api/docs/deprecations)
- Verified: November 6, 2026, against OpenAI's own pages
- Page: https://www.okapi.bot/models/openai/dall-e-2/

## OpenAI's words

> Shutdown date: 2026-05-12; Model / system: dall-e-2; Recommended replacement: gpt-image-2 , gpt-image-1 , or gpt-image-1-mini

Okapi finds the calls this change hits in your repo and opens the pull request with the fix: https://github.com/apps/okapi-agent
