Open WebUI provides a familiar, browser-based chat interface for locally-run language models — giving you a private, self-hosted alternative to ChatGPT's interface, connected to your own Ollama installation.
Prerequisites
- Ollama already installed and running (see How to Install Ollama and Run Local LLMs on a VPS)
- Docker installed
Step 1 — Run Open WebUI with Docker
docker run -d \
--name open-webui \
--restart unless-stopped \
-p 3000:8080 \
-e OLLAMA_BASE_URL=http://host.docker.internal:11434 \
-v open-webui-data:/app/backend/data \
--add-host=host.docker.internal:host-gateway \
ghcr.io/open-webui/open-webui:main
--add-host and host.docker.internal allow the container to reach Ollama running on the host machine.
Step 2 — Access the Interface
http://YOUR_SERVER_IP:3000
Step 3 — Create Your Admin Account
The first account created becomes the administrator automatically.
Step 4 — Disable Further Signups (Important)
In the admin settings, disable open registration after creating your intended accounts — otherwise anyone who discovers the URL could create an account and use your server's compute resources.
Step 5 — Start Chatting
Select your installed Ollama model from the dropdown and start a conversation — the interface closely resembles familiar AI chat products.
Step 6 — Add HTTPS
See How to Install Nginx Proxy Manager with Docker to route a domain to port 3000 with a proper SSL certificate, especially important since you'll likely be entering an admin password.
Uploading Documents for RAG-Style Q&A
Open WebUI includes a built-in document upload feature, letting you ask questions about your own documents — a lightweight, built-in alternative to building a custom RAG pipeline (see How to Deploy a RAG (Retrieval-Augmented Generation) Pipeline on a VPS for a more customizable approach).
Managing Multiple Users
Open WebUI supports multiple user accounts with role-based permissions — useful if you're sharing access with a small team while keeping administrative control centralized.
Backing Up Open WebUI Data
docker run --rm -v open-webui-data:/data -v $(pwd):/backup alpine tar czf /backup/open-webui-backup.tar.gz /data
Common Errors
"Failed to connect to Ollama" — verify the OLLAMA_BASE_URL and --add-host flag are correctly set, and that Ollama is actually running on the host (sudo systemctl status ollama).
Interface loads but no models appear — ensure at least one model has been pulled via ollama pull MODEL_NAME on the host first.
Best Practices
- Disable open registration immediately after setting up your own account
- Always run behind HTTPS given the presence of login credentials
- Back up the data volume regularly, especially if storing uploaded documents
Continue Reading
- How to Install Ollama and Run Local LLMs on a VPS
- How to Deploy a RAG (Retrieval-Augmented Generation) Pipeline on a VPS
- How to Install Nginx Proxy Manager with Docker
Browse more articles in AI & Machine Learning on a VPS.