Deployment guide

How to host OpenUI on a VPS

Deploy on a VPS Cloud →

Artificial Intelligence7 min read

How to host OpenUI on a VPS

OpenUI is an open-source tool that generates web interface components from a simple description, then renders them live in the browser. Self-hosted on a VPS, it becomes a private UI prototyping workshop that your whole team can use. Here is how to deploy it with Docker, connect it to a model and secure it behind a reverse proxy.

Why self-host OpenUI on a VPS

OpenUI is aimed at front-end developers and designers who want to turn an idea ("a login form with a blue button and a forgotten-password option") into functional HTML/Tailwind/React code, rendered instantly. Rather than depending on an online service, hosting it on your VPS gives you a permanent endpoint, shareable via an internal link, where anyone can prototype without a local installation. Key point: OpenUI needs a model to generate the code — you point it either to an external LLM via an API key, or to a local Ollama running on the same VPS, which keeps the entire chain in-house. The real-time rendering of the components hugely accelerates mock-up iterations.

The concrete benefits of self-hosting

  • UI prototyping workshop shared via a simple internal URL.
  • Live rendering of the generated components (HTML, Tailwind, React, Svelte).
  • Choice of model backend: external API key or 100% local Ollama.
  • No generation limit imposed by a third-party service.
  • Clean code export, ready to copy into your project codebase.
  • Confidentiality of client briefs and mock-ups kept on your VPS.

Hardware and software prerequisites

OpenUI itself is lightweight: the application (Python backend + front) fits on a 2 vCPU / 2 to 4 GB RAM VPS if you use an external API key for the model. On the other hand, if you want to keep everything local with Ollama on the same machine, size it according to the model: then count on 8 to 16 GB of additional RAM for a quantized 7B model. Plan for a few GB of disk for the Docker images (and more if you store Ollama models). On the software side: Ubuntu 22.04, Docker and Docker Compose, a model API key (or Ollama installed), and a subdomain like ui.mydomain.com.

Step-by-step deployment

01

Grab the project

Via SSH, clone the repository: git clone https://github.com/wandb/openui then move into the backend folder. OpenUI provides a Dockerfile and ready-to-use build instructions.

02

Choose the model backend

For an external model, fill in your key in an environment variable (OPENAI_API_KEY or equivalent). To stay local, install Ollama (curl -fsSL https://ollama.com/install.sh | sh), pull a model with ollama pull llama3 and point OpenUI to it.

03

Build and run the container

Build the image then start: docker compose up -d. OpenUI exposes port 7878 by default. Follow the startup with docker compose logs -f until you see the server ready.

04

Check the rendering

Open http://IP_DU_VPS:7878, type a component description and confirm that the code is generated AND rendered live. If generation fails, check the connection to the model in the logs.

05

Secure behind a reverse proxy

OpenUI has no strong authentication by default: place Caddy or Nginx in front of port 7878 with Basic Auth, and enable automatic SSL for ui.mydomain.com. Restrict access to the raw port via the firewall (ufw deny 7878).

06

Share with the team

Communicate the URL https://ui.mydomain.com to your developers and designers. Everyone can prototype from their browser without installing anything, and copy the generated code directly into the project.

For a fully sovereign chain, have OpenUI and Ollama coexist in the same docker-compose.yml on an internal Docker network: OpenUI calls Ollama via http://ollama:11434 without ever exposing the LLM on the Internet. On the generation-quality side, a code-oriented model (CodeLlama, Qwen2.5-Coder) produces far better Tailwind/React components than a generalist model of the same size — test several and keep the one whose rendering is most faithful to your prompts.

Prototype your interfaces on a ServOrbit Cloud VPS

Deploy OpenUI (and Ollama if you wish) on a Cloud VPS with preconfigured Docker. A private, shareable UI-generation workshop, continuously available.

Need help?

Browse our help center and FAQ, or write to our team — support in French, English and Arabic.