Open WebUI can generate and edit images right inside a chat. Hook it up to ComfyUI or AUTOMATIC1111 on your own GPU, or to a hosted image API such as OpenAI or Gemini, and then simply ask your chat model for a picture.
With the right connection you can also upload a photo and say “change the background to a sunset”, or combine two images into one scene.
The setup moved recently. Image backends are now added as connections under Admin Panel > Settings > Images & Videos, each with its own access control, and the chat model calls a generate_image tool instead of you switching to an image model.
This guide walks through every backend, the ComfyUI workflow mapping that trips most people up, and the fixes for the common errors.
It follows Open WebUI’s official documentation as of late November 2026.
- Where: Admin Panel > Settings > Images & Videos. Turn on Image Generation (and Image Edit), then add a connection.
- Backends: OpenAI compatible, Gemini, ComfyUI, AUTOMATIC1111. A1111 cannot edit.
- Share it: click Access on the connection, or only admins can use it.
- In chat: keep your normal chat model selected, switch on Image in the “+” menu and ask.
- ComfyUI: start with
--listen, export the workflow with Export (API), upload it and map the prompt node ID. - Biggest mistake: picking the image model as the chat model. Do not.
How Image Generation Works in Open WebUI
An administrator adds one connection per image backend. Users then keep chatting with their normal model, and that model asks the image backend for pictures. There are two modes, set by the model’s Function Calling option:
- Native (default): the chat model calls a
generate_imagetool when you ask for an image, writing the image prompt itself. If Image Edit is on, it also gets anedit_imagetool. The model can reason about the prompt first, or make several images for one request. - Legacy: every message sent while the Image toggle is on goes straight to the image backend. A task model rewrites your message into an image prompt first, unless you switch Image Prompt Generation off.
A model that does not call tools reliably will never call generate_image in Native mode. If images never appear, try a stronger chat model before you blame the image backend. The same rule applies to Open WebUI web search.
Which Backend Should You Use?
| Connection type | Runs | Edit support | Default model | Best for |
|---|---|---|---|---|
| ComfyUI | Locally on your GPU | Yes, with an edit workflow | Whatever the workflow sets | Free, private, any model (FLUX, Qwen Image, SDXL) |
| AUTOMATIC1111 | Locally | No | The loaded checkpoint | Simple SD and SDXL setups |
| OpenAI compatible | Cloud or any OpenAI-style server | Yes | gpt-image-2 |
Best quality with no GPU; also LiteLLM, Azure |
| Gemini | Google cloud | Yes | imagen-3.0-generate-002 |
Imagen and Gemini image models |
If you already run ComfyUI, start there: it costs nothing per image and keeps everything on your machine. If you do not have a capable GPU, a hosted API is the quickest route. Our ComfyUI guide covers installing ComfyUI itself.
Add an Image Connection
These steps are the same for every backend:
- Open the settings. Go to Admin Panel > Settings > Images & Videos and switch on Image Generation, Image Edit, or both.
- Add a connection. Under Manage Image Connections, click +.
- Fill in the basics. Choose the Connection Type, give it a Name, enter the URL and the key if needed, then click the verify icon next to the URL.
- Set capabilities. Under Capabilities, keep Generate, Edit or both on. Only what the backend supports can be enabled.
- Grant access. Click Access, choose the users or groups who may use it (or make it public), then click Save.
The access step matters. A new connection is private to administrators until you share it, and users without access never see its models. Under Default Models you can also pick the Default Generation Model and Default Edit Model, and each chat model can carry its own default image model in its editor.
Set Up ComfyUI (Local)
ComfyUI is the most flexible option, but it needs one extra step: you give Open WebUI an exported workflow and tell it which node holds the prompt.
1. Make ComfyUI reachable
- Start ComfyUI with the
--listenflag so it binds to0.0.0.0. It then serves on port8188. - If Open WebUI runs in Docker on the same PC, use
http://host.docker.internal:8188/as the URL. - On Linux without Docker Desktop, add
--add-host=host.docker.internal:host-gatewayto your Open WebUIdocker runcommand. - If a firewall is active, allow port 8188, for example
sudo ufw allow 8188/tcp. - Open WebUI also opens a WebSocket to
/ws, so any reverse proxy in front of ComfyUI must pass WebSocket upgrades.
2. Export your workflow in API format
- Enable Dev Mode. In ComfyUI, click the logo, open Settings and turn on the option described as “Enable dev mode options (API save, etc.)”.
- Load a working workflow. Test it in ComfyUI first so you know it produces an image.
- Export (API). Click the logo, open File and choose Export (API). Save the JSON file.
3. Connect and map the nodes
- Add a ComfyUI connection with the URL above and verify it.
- Upload the workflow in the Generation Workflow section.
- Map the node IDs. Each row has a Key (the input name) and Node Ids (the node numbers from the JSON). Only the prompt is required.
- Verify again after mapping so the Model IDs suggestions refresh, set an Image Size under Advanced (otherwise ComfyUI gets 512×512), then grant Access and save.
| Parameter | Default key | Required |
|---|---|---|
| Prompt | text |
Yes |
| Model | ckpt_name |
No |
| Width / Height | width / height |
No |
| Steps | steps |
No |
| Seed | seed |
No |
To find a node ID, open the exported JSON in a text editor: the top-level keys are the node IDs, and each node’s inputs block shows the key names.
Some workflows use different names, for example noise_seed instead of seed, so change the key to match. FLUX workflows often need several node IDs for one entry; separate them with commas, like 6, 33. A mapped seed gets a new random value on every request.
Open WebUI returns images from Save Image, Save Image (Advanced), Preview Image and the animated WEBP and PNG save nodes, so make sure your workflow ends in one of them. If your ComfyUI models live in a shared folder, our extra model paths guide helps keep them organised.
Set Up AUTOMATIC1111 or Forge
- Launch with the API enabled:
./webui.sh --api --listen(on Windows, add--api --listento the command line arguments in your launch file). - Add an AUTOMATIC1111 connection with the URL
http://<address>:7860/, orhttp://host.docker.internal:7860/if Open WebUI runs in Docker on the same host. - Authentication: if the WebUI is password protected, choose Basic and enter
username:password. - Optional extras: under Advanced, add parameters such as
{"cfg_scale": 7, "sampler_name": "Euler a"}. - Grant Access and save.
Two caveats: AUTOMATIC1111 connections only generate images, they cannot edit; and if you list several checkpoints under Model IDs, picking one switches the loaded checkpoint for everyone using that server.
Set Up OpenAI or Gemini Images
- OpenAI compatible: add a connection with your provider’s base URL and API key. With no Model IDs, it offers
gpt-image-2, or every image model a LiteLLM server lists. Add IDs such asgpt-image-1.5to offer more. The same type works for Azure OpenAI, LiteLLM and other servers with an OpenAI-style images API, and it supports custom headers. - Gemini: add a Gemini connection with your API key. The default model is
imagen-3.0-generate-002; add other Imagen or Gemini image model IDs as needed.
Hosted images cost money per image, so restrict access to the users who need it. Check your provider’s current price list before opening it to a team.
Generate Images in a Chat
- Keep your normal chat model selected at the top of the chat.
- Switch on Image in the + menu of the message box. Use the arrow next to it to choose another image model if several are available.
- Ask for the picture in plain language, for example “Generate a watercolour of a lighthouse at dawn”.
- Send. The image appears in the reply.
To have Image on in every new chat with a model, tick Image Generation under Default Features in that model’s editor. If you liked the old “Generate Image” button under each message, the docs point to a community Generate Image Action you can import and enable under Admin Panel > Functions.
Image generation only shows up when four things are true: it is enabled globally with a connection you can access, your role has the Image Generation permission, the chat model has the Image Generation capability (and builtin tools on, outside Legacy mode), and the Image toggle is on for the chat.
Edit and Combine Images
Editing needs Image Edit switched on, plus a connection with the Edit capability: OpenAI compatible, Gemini, or ComfyUI with an edit workflow.
- Edit one image: upload it and describe the change, such as “Change the background to a sunset” or “Add a hat”.
- Combine images: upload two or more images and describe the scene, such as “Put the cat from the first photo on the park bench in the second, with matching light”.
For ComfyUI editing, upload an edit workflow in the Edit Workflow section and map its nodes. The defaults differ: image and prompt are required, plus optional unet_name, width and height.
For several input images, list one LoadImage node ID per image, separated by commas; extra images beyond the number of IDs are dropped. The docs include worked examples for Qwen Image Edit and FLUX.
Troubleshooting
The Image option is missing from the “+” menu
Image generation is off globally, the chat model’s Image Generation capability is off, or your role lacks the permission. Also check that the connection’s Access includes you.
Everything looks set up but nothing is generated
Check the model selector first. Picking the image model as the chat model is the most common setup mistake, because an image model cannot hold a conversation. Then confirm the chat model supports tool calling, or switch it to Legacy.
ComfyUI: “Value not in list: ckpt_name”
The model name Open WebUI sends does not exist for that loader node, for example a VAE name sent to a checkpoint loader. Fix the model name in the connection so it matches what the node expects.
ComfyUI: “Missing input”
Your workflow needs a value (like cfg) that Open WebUI is not mapping. Hardcode it in the workflow JSON or map the key to the right node ID.
Cannot connect to ComfyUI or AUTOMATIC1111
Make sure the backend was started with --listen (and --api for A1111), use host.docker.internal from Docker, add the host-gateway mapping on Linux, and open the port in your firewall.
Images come out at 512×512
Set Image Size under the connection’s Advanced settings, or map width and height nodes.
Out of memory in ComfyUI
Generating from Open WebUI uses the same VRAM as generating in ComfyUI directly. See our ComfyUI out of memory fixes.
FAQ
Can Open WebUI generate images for free?
Yes, with ComfyUI or AUTOMATIC1111 running on your own GPU. Hosted APIs charge per image.
Can I use Ollama to generate images in Open WebUI?
The chat model can run on Ollama, but the pictures come from an image connection such as ComfyUI. See our Open WebUI and Ollama setup guide for the chat side.
Does Open WebUI support FLUX and Qwen Image?
Yes, through ComfyUI workflows. The docs include example mappings for FLUX.1 and Qwen Image.
Can I let other users generate images?
Yes. Open the connection’s Access settings and add their users or groups, and make sure their role has the Image Generation permission.
Why does my model say it cannot create images?
Either the Image toggle is off for that chat, the model’s Image Generation capability is disabled, or the model does not call tools reliably.
Can Open WebUI make videos too?
The same settings page covers videos, which have their own setup in the Open WebUI docs.




