Open WebUI is a self-hosted chat interface with history, users, and document chat, but it runs no models itself. It talks to a model server such as Ollama, so installing it in Docker and pointing it at Ollama gives a ChatGPT-style front end for local models.
What you need
- Docker installed and running
- Ollama running on the same machine, or a model server address
- OpenSSL for generating the secret key
Step 1: Generate a secret and start the container
Generate a key once with openssl rand -hex 32 and keep it. Then run: docker run -d -p 3000:8080 –add-host=host.docker.internal:host-gateway -v open-webui:/app/backend/data -e WEBUI_SECRET_KEY=<your-secret-key> –name open-webui –restart always ghcr.io/open-webui/open-webui:main. The volume holds chats, users, and settings and survives updates.
Step 2: Create the admin account
Open http://localhost:3000 and create the first account, which becomes the administrator. The first start takes about a minute; check docker logs -f open-webui and wait for Application startup complete if nothing loads.
Step 3: Connect Ollama
If Ollama runs on the same machine, Open WebUI looks for it at http://host.docker.internal:11434 from Docker. On Linux the container cannot reach Ollama on 127.0.0.1, so set OLLAMA_HOST=0.0.0.0:11434 for the Ollama service and restart it. Then pick a model in the model selector and send a test message.
Worked example: Open WebUI plus Ollama on one Linux box
The table below is a synthetic example. The docker command, ports, and connection addresses come from the cited Open WebUI guides; the secret value is a placeholder for your own key.
| Step | Value | Expected result |
|---|---|---|
| Container | Port 3000 mapped to 8080 | Open WebUI loads |
| Admin | First account created | Admin rights granted |
| Ollama | http://host.docker.internal:11434 | Models listed |
Expected result (UNTESTED). Open WebUI opens on port 3000, the admin account is created, and the Ollama models appear in the model selector. This check was not run live; the commands come from the cited Open WebUI guides.
Limits
- Open WebUI runs no models; without a connected engine there is nothing to chat with.
- The :main image is about 1.62 GB; the :slim tag is about 197 MB and has no bundled models.
- Never run without the volume, or chats and settings vanish on recreate.
- A stock install makes a few outbound calls, such as a version check; set the documented flags to stop them.
