Open WebUI: Add a Chat GUI to Ollama
- Deploy Open WebUI with a single Docker command
- Use Open WebUI for persistent chat history, model switching, and document RAG
- Understand when to use Open WebUI versus LM Studio for local AI interaction
The Gap Ollama Leaves
Ollama is excellent infrastructure but its built-in chat is a bare terminal session. You type, it responds, there is no conversation history between sessions, no way to switch models without a new command, and no interface to share with non-technical colleagues. For personal developer use this is fine. For anyone else — or for teams — it is friction.
Open WebUI fills this gap. It is an open-source, self-hosted web interface for Ollama that runs entirely in your browser. You get a full chat UI, persistent conversation history, model switching from a dropdown, RAG with your own documents, and a clean interface that looks like a polished consumer product — all running locally, all connecting to the Ollama backend you already have.
Deploying Open WebUI
Open WebUI deploys via Docker in a single command. If you have Docker installed, run:
docker run -d -p 3000:8080 --add-host=host.docker.internal:host-gateway -v open-webui:/app/backend/data --name open-webui --restart always ghcr.io/open-webui/open-webui:main
This command does three things: starts Open WebUI on http://localhost:3000, mounts persistent storage so your conversations survive container restarts, and grants it network access to reach Ollama running on your host machine.
Open your browser at http://localhost:3000. The first visit prompts you to create an admin account (local only — no external signup). After that you land in the chat interface connected to your Ollama backend.
If you do not have Docker, Open WebUI also installs via pip: pip install open-webui, then open-webui serve.
Key Features
Model selection: A dropdown in the chat header lists every model you have pulled in Ollama. Switch models mid-session without touching the terminal.
Conversation history: Every chat is saved and accessible from the left sidebar. Sessions persist across browser closes and machine restarts — unlike Ollama’s terminal chat which starts fresh each time.
RAG with documents: Upload PDFs, text files, and documents to a personal knowledge base. Any chat can query that knowledge base, grounding responses in your files without sending them to a cloud server.
Markdown and code rendering: Responses with markdown, code blocks, and tables render properly in the browser — far more readable than raw terminal output.
OpenAI API compatibility: Open WebUI also connects to any OpenAI-compatible backend, not just Ollama. You can add LM Studio’s server (localhost:1234), or route some queries to a cloud API while keeping others local.
Open WebUI vs LM Studio: When to Use Which
These tools overlap but serve different primary purposes. LM Studio is the better tool for discovering and evaluating models — its Hugging Face browser, VRAM monitor, and parameter controls make it the right environment for testing. Open WebUI is the better tool for daily chat use — persistent history, document RAG, and a browser interface that works on any device on your local network (phone, tablet, another laptop).
Many people run Ollama as the model server, Open WebUI for everyday conversation, and LM Studio for exploring new models. All three coexist without conflict.
- Open WebUI deploys in one Docker command and gives Ollama a full chat UI with persistent history, model switching, and document RAG
- Open WebUI runs in a browser and is accessible from any device on your local network — useful for non-technical users who need access to local AI
- The three-layer stack — Ollama (server) + Open WebUI (daily chat) + LM Studio (model discovery) — is how many power users organise their local AI setup