The error you get
What Gemini API answers a call to imagen-4.0-generate-001 once the model is gone, as recorded from real responses:
{"error":{"code":404,"message":"This model models/imagen-4.0-generate-001 is no longer available to new users. Please update your code to use a newer model for the latest features and improvements.","status":"NOT_FOUND"}}
{"error":{"code":404,"message":"models/imagen-4.0-generate-001 is not found for API version v1beta, or is not supported for generateContent. Call ModelService.ListModels to see the list of available models and their supported methods.","status":"NOT_FOUND"}}
What to use instead of imagen-4.0-generate-001
Move to the recommended replacement gemini-nano-banana-2.1. This migration requires more than an identifier update, as calls must use generate_content (generateContent) rather than generate_images, and the response delivers image data inside a content part instead of Imagen's generated-images response object.
Nano Banana is called with generate_content (generateContent), not generate_images, and returns the image as a content part holding the image data instead of Imagen's generated-images response object.
In Gemini API's words
Model: imagen-4.0-generate-001; Release date: June 24, 2025; Shutdown date: August 17, 2026; Recommended replacement: gemini-nano-banana-2.1
Facts
- API
- Gemini API
generativelanguage.googleapis.com - Model
imagen-4.0-generate-001- Kind
- Model retirement
- Takes effect
- August 17, 2026
- Calls after that day
- Fail
- Source
- Deprecations page
- Last updated
- Verified
- , against Gemini API's own pages
Questions
When does imagen-4.0-generate-001 shut down?
Calls to the model imagen-4.0-generate-001 on Gemini API stopped working on August 17, 2026.
What happens to calls after August 17, 2026?
They have failed since August 17, 2026.
What error does imagen-4.0-generate-001 return once it is shut down?
Gemini API answers HTTP 404: "This model models/imagen-4.0-generate-001 is no longer available to new users. Please update your code to use a newer model for the latest features and improvements.". Send another model to fix it.
imagen-4.0-generate-001 on other APIs 1
| Effective | Provider | Model | Status |
|---|---|---|---|
| Vertex AI | imagen-4.0-generate-001 | stopped working |
More from Gemini API 10
| Effective | Model | Status |
|---|---|---|
gemini-3-pro-image-preview | stopped working | |
veo-2.0-generate-001 | stopped working | |
veo-3.0-fast-generate-001 | stopped working | |
veo-3.0-generate-001 | stopped working | |
gemini-2.5-computer-use-preview-10-2025 | stopped working | |
embedding-2-preview | stopped working | |
imagen-4.0-fast-generate-001 | stopped working | |
imagen-4.0-ultra-generate-001 | stopped working | |
gemini-robotics-er-1.6-preview | stopped working | |
antigravity-preview-05-2026 | stopped working |