Image Generation
🎨 Image Generation Troubleshooting
General Issues
- Image Not Generating:
- Check the Images settings in the Admin Panel > Settings > Images. Ensure "Image Generation" is toggled ON.
- Verify your API Key and Base URL (for OpenAI, ComfyUI, Automatic1111) are correct.
- Ensure the selected model is available and loaded in your backend service (e.g., check the ComfyUI or Automatic1111 console for activity).
- Azure OpenAI: If you see
[ERROR: azure-openai error: Unknown parameter: 'response_format'.], ensure you are using API version2025-04-01-previewor later.
ComfyUI Issues
-
Incompatible Workflow / JSON Errors:
- API Format Required: Open WebUI requires workflows to be in the API Format.
- In ComfyUI:
- Click the "Settings" (gear icon).
- Enable "Enable Dev mode Options".
- Click "Save (API Format)" in the menu.
- Do not use the standard "Save" button or standard JSON export.
-
Image Editing / Image Variation Fails:
- If you are using Image Editing or Image+Image generation, your custom workflow must have nodes configured to accept an input image (usually a
LoadImagenode replaced/linked effectively). - Check the default "Image Editing" workflow in the Open WebUI settings for the required node structure to ensure compatibility.
- If you are using Image Editing or Image+Image generation, your custom workflow must have nodes configured to accept an input image (usually a
Automatic1111 Issues
-
Connection Refused / "Api Not Found":
- Ensure you are running Automatic1111 with the
--apiflag enabled in your command line arguments.
- Ensure you are running Automatic1111 with the
-
Docker Connectivity:
- If Open WebUI is running in Docker and Automatic1111 is on your host machine:
- Use
http://host.docker.internal:7860as the Base URL. - Ensure
host.docker.internalis resolvable (added via--add-host=host.docker.internal:host-gatewayin your Docker run command).
- Use
- If Open WebUI is running in Docker and Automatic1111 is on your host machine:
Environment Variables & Configuration
For advanced configuration, you can set the following environment variables.
General Image Generation
ENABLE_IMAGE_GENERATION: Set totrueto enable image generation.IMAGE_GENERATION_ENGINE: The engine to use (e.g.,openai,comfyui,automatic1111,gemini).IMAGE_GENERATION_MODEL: The model ID to use for generation.IMAGE_SIZE: Default image size (e.g.,512x512).
Engine Specifics
OpenAI / Compatible
IMAGES_OPENAI_API_BASE_URL: Base URL for OpenAI-compatible image generation API.IMAGES_OPENAI_API_KEY: API Key for the image generation service.
ComfyUI
COMFYUI_BASE_URL: Base URL for your ComfyUI instance.COMFYUI_API_KEY: API Key (if authentication is enabled).COMFYUI_WORKFLOW: Custom workflow JSON (must be API format).
Automatic1111
AUTOMATIC1111_BASE_URL: Base URL for your Automatic1111 instance.AUTOMATIC1111_API_AUTH: Authentication credentials (username:password).
Gemini
IMAGES_GEMINI_API_KEY: API Key for Gemini.- View Gemini Configuration Guide
tip
For a complete list of environment variables and detailed configuration options, please refer to the Environment Configuration Guide.