Last Updated on 3 hours ago by Sachin G
Disclosure: Some links in this post are referral links. New Hostinger customers who sign up through my Hostinger link or use the code WEBSTART get an extra discount, and I may earn a commission at no extra cost to you. Billing, refunds and support are handled by Hostinger. Affiliate disclosure
Clients ask me the same question more and more often: “Can I run my own ChatGPT on my server, so my data never leaves it?” The answer is yes. The harder question is whether you need an expensive GPU to do it.
For most people, you do not: running Ollama on a VPS with a normal CPU is enough. I have set up private AI servers for clients on Hostinger, DigitalOcean, Hetzner and AWS, and a normal CPU VPS handles a small model for one person or a small team just fine. In this guide I use Hostinger’s one-click Ollama template, fix the two security gaps it ships with, add a private chat interface, and share the real speed I measured.
The short answer
| You are… | Pick | Why |
|---|---|---|
| A developer or freelancer testing local AI | VPS, 8–16 GB RAM | Cheap, fixed monthly cost, full control |
| A small business wanting a private chatbot for 1–5 people | VPS, 16 GB RAM | Data stays on your server; small models are good enough |
| Running n8n automations that call an LLM | VPS, 16 GB RAM | Short prompts; speed matters less |
| Serving many users at the same time | GPU server | CPU requests queue and slow down |
| Needing 70B-class models or image generation | GPU server | Too big or too slow on CPU |
| Running heavy AI jobs only now and then | Hourly GPU | You pay only for the hours you use |
CPU vs GPU, in plain words
A language model does billions of small calculations for every word it writes. A CPU has a few strong cores that work through them in chunks. A GPU has thousands of small cores that work in parallel, so it writes text many times faster.
That is the whole difference: same model, same answers, very different speed and cost.
- CPU VPS: fine for small models (1B–8B parameters). Replies come at a readable pace for one person, and slow down when several people ask at once.
- GPU server: runs bigger models for many users with near-instant replies, at a much higher hourly or monthly cost.
Three names you will see in this guide:
- Llama is the model, the AI “brain” released by Meta.
- Ollama is the software that downloads a model, runs it, and gives you an API on port 11434.
- Open WebUI is the ChatGPT-style web interface you put on top of Ollama.
Which VPS size for which model
RAM decides which model you can run. CPU cores decide how fast it replies. The model has to fit in RAM with room left for the OS and the web interface.
| Model (Ollama tag) | Download size | Minimum RAM | Comfortable VPS | Disk |
|---|---|---|---|---|
llama3.2:1b | 1.3 GB | 4 GB | 2 vCPU / 8 GB | 20 GB free is plenty |
llama3.2:3b | 2.0 GB | 8 GB | 2 vCPU / 8 GB | 20 GB free is plenty |
llama3.1:8b | ~4.7–4.9 GB | 8 GB | 4 vCPU / 16 GB | 30 GB free |
| 8B + an embedding model, or two models loaded | ~6–10 GB | 16 GB | 8 vCPU / 32 GB | 50 GB free |
llama3.3:70b | 43 GB | Not practical on CPU | GPU server | — |
llama4:scout (smallest Llama 4) | 67 GB | Not practical on CPU | GPU server | — |
Ollama’s own guide says you need at least 8 GB of RAM for 7B-class models, 16 GB for 13B and 32 GB for 33B. I treat that as the floor, not the target: the OS, Docker and Open WebUI also need memory, and a longer chat (bigger context window) uses more RAM on top of the model itself. That is why I recommend 16 GB for the 8B model.
CPU cores decide speed. Hostinger’s vCPUs are shared, so speed can vary a little at busy times; more cores help, but on CPU the speed is limited mostly by memory bandwidth, so do not expect miracles from 8 cores.
Disk is rarely the problem. Each model is stored once, so even KVM 2’s 100 GB holds several small models plus Docker images.
Why not the newest Llama? Llama 4’s smallest version is a 67 GB download, far beyond any CPU VPS. For a VPS, Llama 3.1 8B is still the practical choice.
Sizes from the Ollama model library, checked on December 2, 2026. When I pulled llama3.1:8b, the download showed 4.9 GB.
Which Hostinger plan fits you
Hostinger needs at least KVM 2 to install Ollama. Pick by what you plan to do, not by the biggest number.
| Plan | Specs | Best for | Models that run well | Price, 24-month term (USD) |
|---|---|---|---|---|
| KVM 1 | 1 vCPU, 4 GB RAM, 50 GB NVMe | Not supported for Ollama | — | $5.19/mo, renews $11.99/mo |
| KVM 2 | 2 vCPU, 8 GB RAM, 100 GB NVMe | Learning, personal assistant | llama3.2:1b, llama3.2:3b | $7.03/mo, renews $14.99/mo |
| KVM 4 | 4 vCPU, 16 GB RAM, 200 GB NVMe | Small-team chatbot, n8n + LLM | llama3.1:8b | $10.39/mo, renews $28.99/mo |
| KVM 8 | 8 vCPU, 32 GB RAM, 400 GB NVMe | Several models, document chat, a few users at once | llama3.1:8b plus an embedding model | $20.79/mo, renews $49.99/mo |

Referral link · I may earn a commission
Try this setup on a Hostinger LLM VPS
I use Hostinger for client projects and tested this exact setup on a KVM 4. This link opens their LLM VPS plans with Ollama pre-selected. New customers get an extra discount automatically, or can enter WEBSTART at checkout.
See Hostinger LLM VPS plans →
Billing, refunds and support are handled by Hostinger. Prices and discounts can change. Affiliate disclosure
Prices include the 20% referral discount and were checked on December 2, 2026. Sale prices change often and vary by region. All plans are paid upfront: the monthly figure is the total for the term divided by the number of months.
My advice: take KVM 4 if you want llama3.1:8b, or KVM 2 if you only want to learn. Hostinger lets you upgrade the plan later from the control panel, so there is no need to buy KVM 8 up front. And look at the renewal price, not only the first-term price; on KVM 4 it nearly triples after the sale term. I break the long-term cost down in my Hostinger VPS plan guide.
The cart also offers Daily auto-backup for $12/mo. For a test or personal server I skip it: free weekly backups are included, and I take a manual snapshot before big changes.
If you are new to Hostinger, this link opens their LLM VPS plans with Ollama pre-selected. The referral discount applies automatically in the cart, or you can enter the code WEBSTART at checkout. On my KVM 4 cart, both gave the same $62.35 discount.
I tested on Hostinger KVM 4 (4 vCPU, 16 GB RAM, 200 GB NVMe), using Hostinger’s one-click Ollama template.
What you will set up
- Ollama running Llama 3.1 8B from Hostinger’s one-click template.
- Two security fixes, because the template exposes Ollama to the internet by default.
- Open WebUI as a private chat screen, connected to your own Ollama, with sign-ups closed.
- A few CPU tweaks, and honest numbers on what to expect.
Step-by-step: one-click Ollama on Hostinger
- Choose your plan (KVM 2 or higher) and the billing period. If you start from my LLM VPS link, the cart already says “Ollama auto-deploys with your VPS”, so you can skip step 2.
- On the “Choose what to install” screen, open the Applications tab and search for
Ollama. Click it; the popup says it is installed using Docker. Click Select.

- Set a root password and add your SSH key if the setup screen offers it. Finish the purchase.
- Wait for the VPS to finish building, then open its overview in hPanel and note the server IP.
- Open what the template gives you. In hPanel’s VPS overview you will see Ollama listed under My applications as one running container. There is no chat interface; the template installs only the Ollama API. “Open app” opens an auto-generated hostname that simply says “Ollama is running”. “App terminal” opens a terminal in your browser, and “+ Application” lets you add another Docker app, such as a web UI.
- Pull and run a model over SSH (or from App terminal in hPanel):
docker ps
docker exec -it OLLAMA_CONTAINER_NAME ollama pull llama3.1:8b
docker exec -it OLLAMA_CONTAINER_NAME ollama run llama3.1:8b --verbose "Explain what a reverse proxy is in 3 sentences."
Replace OLLAMA_CONTAINER_NAME with the name shown by docker ps.
After a one-click install: check these 5 things
One-click is convenient. But after years of experience cleaning up servers, I never trust a setup until I know what is running and what is exposed. These checks take about ten minutes.
1. See what is running.
docker ps --format "table {{.Names}}\t{{.Image}}\t{{.Ports}}"
2. Check which ports are open to the internet.
sudo ss -tlnp
Then run this from your own computer, not the server:
curl http://YOUR_SERVER_IP:HOST_PORT
Use the host port that docker ps shows for Ollama, not 11434. On my server it showed 0.0.0.0:32768->11434/tcp, so the public port was 32768. Port 11434 only exists inside the container. Also open the hostname that “Open app” uses in hPanel.
No terminal on your own computer? Test the same port from your browser with my free Port Checker.
If it replies Ollama is running, your Ollama API is public. The API has no login, so anyone who finds it can use your server’s CPU and RAM.
3. Know that Docker bypasses UFW. Ports that Docker publishes skip UFW rules, so ufw deny 11434 on its own does not protect you. On the one-click template there are two ways in, so you need both fixes below: one closes the port, the other closes the hostname.
Before you change anything, take a snapshot or check that a recent backup exists in hPanel. Every Hostinger VPS plan includes free weekly backups, but a manual snapshot right before a change is the safer habit.
Fix 1: bind the port to localhost. Find the compose folder:
docker inspect OLLAMA_CONTAINER_NAME --format '{{ index .Config.Labels "com.docker.compose.project.working_dir" }}'
In that folder (on my server it was /docker/ollama-dwkm), edit docker-compose.yml. Under ports: the template has - "11434", which tells Docker to publish Ollama on a random public port (32768 on my server). Change it to - "127.0.0.1:11434:11434", so Ollama only listens on the server itself. Then apply it from the same folder:
docker compose up -d

Check it on the server, then from your own computer:
ss -tlnp | grep 11434
The output should show 127.0.0.1:11434 only. From your computer, http://YOUR_SERVER_IP:32768 (use your old port) should now time out. On my server it did.
You can run the same test again in the Port Checker: after the fix, the old port should show as closed.
Fix 2: disable the Traefik route. The template also adds Traefik labels to the same compose file, and Traefik serves Ollama on the public hostname over HTTPS. In the labels: section, change traefik.enable=true to traefik.enable=false, then run docker compose up -d again.
docker compose up -d
docker ps
Now open the hostname from hPanel’s “Open app” in a private browser window, or test it from your computer:
curl -I https://YOUR_OLLAMA_HOSTNAME
On my server it returned 404 after this change, instead of “Ollama is running”. Note that hPanel’s “Open app” button stops working after this, which is exactly what we want.

Extra layer: the hPanel firewall. Hostinger’s VPS firewall in hPanel is a good second layer. Allow only the ports you actually use, such as 22, 80 and 443.

4. Lock down the web UI, if there is one. Create your admin account first, then turn off public sign-ups (the Open WebUI section below shows where).
5. Harden SSH. The template does not change SSH settings. At minimum, create a sudo user, switch to SSH keys and add fail2ban:
adduser deploy
usermod -aG sudo deploy
From your own computer, copy your key with ssh-copy-id deploy@YOUR_SERVER_IP. Once key login works, turn off root and password logins and add fail2ban:
sudo tee /etc/ssh/sshd_config.d/99-hardening.conf > /dev/null <<'EOF'
PermitRootLogin no
PasswordAuthentication no
EOF
sudo sshd -t && sudo systemctl restart ssh
sudo apt install -y fail2ban
sudo systemctl enable --now fail2ban
Keep your current session open and test a new login in a second terminal before you close anything. I have seen more people lock themselves out at this step than anywhere else.
To build these settings for your own server, use my free SSHD Config Hardening and Fail2ban Config Generator tools.
What I found on my test server: right after the one-click install, the Ollama API was reachable from the internet in two ways: on a random public port (32768) and through the auto-generated hostname that “Open app” uses. No login, no password: anyone with either address could use the model. After Fix 1 and Fix 2, the port timed out and the hostname returned 404.
Add a chat interface with Open WebUI
The one-click Ollama template gives you an API, not a chat screen. Hostinger’s Docker catalog also has Open WebUI, so you can add one in a few minutes. Out of the box, though, it is connected to Hostinger’s cloud AI router, not to your own Ollama, and it opens another public port. Here is how I set it up properly.
1. Deploy it from the catalog. In hPanel, open your VPS overview, click + Application, search for Open WebUI and click Select, then Deploy.
On my server, the configuration box said “Couldn’t get the API keys”, and the app first showed as “Created, 0 containers”. After a moment, it switched to Running. That message is about Hostinger’s cloud router key, which we will not use anyway.

2. Create your admin account immediately. Click Open next to the app in Docker Manager. The first account created becomes the admin, and this page is on the internet.

Use a long, random password for this account. My Password Generator creates one in a click.
3. Close sign-ups. Go to Admin Panel → Settings → Authentication. Turn New Sign Ups off, set Default User Role to pending, and leave API Keys off. Click Save. For a client server, I also turn on the authenticator (2FA) option.

4. Notice what the model list shows. On my server the dropdown listed cloud models (Claude, Haiku and others), not llama3.1:8b. In Admin Panel → Settings → Connections, the OpenAI API pointed to https://router.hostinger.com/v1, and the Ollama API to http://host.docker.internal:11434. So by default, your chats leave the server, and your own Llama is not connected.


5. Connect it to your own Ollama, and keep both ports private. Ollama and Open WebUI run in separate Docker networks, and Ollama now listens on localhost only. The clean fix is to put Open WebUI on Ollama’s network. First check the names:
docker ps --format "table {{.Names}}\t{{.Networks}}"

On my server Ollama was on ollama-dwkm_default. Back up the Open WebUI compose file, then edit it:
cd /docker/open-webui-is9q
cp docker-compose.yml docker-compose.yml.bak-$(date +%F)
nano docker-compose.yml
I changed three things: bound port 8080 to localhost (the template had - "8080", which opens another random public port), set the Ollama URL, and joined Ollama’s network:
services:
open-webui:
image: ghcr.io/open-webui/open-webui:main
restart: unless-stopped
ports:
- "127.0.0.1:8080:8080"
labels:
- traefik.enable=true
- traefik.http.routers.${COMPOSE_PROJECT_NAME}.rule=Host(`${COMPOSE_PROJECT_NAME}.${TRAEFIK_HOST}`)
- traefik.http.routers.${COMPOSE_PROJECT_NAME}.entrypoints=websecure
- traefik.http.routers.${COMPOSE_PROJECT_NAME}.tls.certresolver=letsencrypt
- traefik.http.services.${COMPOSE_PROJECT_NAME}.loadbalancer.server.port=8080
environment:
OLLAMA_BASE_URL: http://ollama-dwkm-ollama-1:11434
ENABLE_OPENAI_API: 'false'
volumes:
- open-webui:/app/backend/data
networks:
- default
- ollama
networks:
ollama:
external: true
name: ollama-dwkm_default
volumes:
open-webui:
Replace open-webui-is9q and ollama-dwkm with the names on your server. Keep the Traefik labels: Traefik is what gives Open WebUI its HTTPS address. Apply and verify:
docker compose up -d
docker ps --format "table {{.Names}}\t{{.Ports}}\t{{.Networks}}"
docker exec open-webui-is9q-open-webui-1 curl -s http://ollama-dwkm-ollama-1:11434
Both containers should show 127.0.0.1 ports, Open WebUI should be on both networks, and the last command should print “Ollama is running”. Your chats, account and settings live in the open-webui volume, so nothing is lost.
6. Point the UI at your Ollama and switch off the cloud router. Open WebUI keeps its settings in its own database, so also check Admin Panel → Settings → Connections: set the Ollama API to http://ollama-dwkm-ollama-1:11434, and turn the OpenAI API toggle off. Now the dropdown shows only llama3.1:8b, and no chat leaves your server.

If you prefer the cloud models for some tasks, you can leave the OpenAI API on. Just know that those chats go through Hostinger’s router, not your server.
Before you share the address with anyone, check its HTTPS certificate with my free SSL Checker and its response headers with Security Headers. If you later move Open WebUI to your own domain behind Cloudflare, the Cloudflare WAF Rule Builder helps you lock down the login page.
7. Make it faster on a CPU. Two settings made a clear difference on my KVM 4:
- In Admin Panel → Settings → Interface, turn off title, follow-up, tags and autocomplete generation. Otherwise Open WebUI runs extra jobs on the same model after every answer, and on a CPU they queue behind your next question.
- Keep the model loaded in RAM. By default Ollama unloads it after 5 minutes idle, so the next question waits while ~5 GB loads again. In
/docker/ollama-dwkm/docker-compose.yml, add this under the Ollama service, then rundocker compose up -din that folder:
environment:
OLLAMA_KEEP_ALIVE: 30m
To confirm it worked, ask one question and then run:
docker exec ollama-dwkm-ollama-1 ollama ps
The UNTIL column should say about 30 minutes from now, instead of 5. With both changes, answers on my KVM 4 started noticeably faster.
Prefer a manual install?
This guide focuses on Hostinger’s one-click template, made fully secure and complete with a chat interface. If you would rather install Ollama by hand on plain Ubuntu, on Hostinger or any other provider, I cover that in a separate step-by-step guide. I am writing a separate step-by-step guide for the manual install, and I will link it here once it is live.
My test results
On KVM 4, llama3.1:8b wrote 8.35 tokens per second, comfortably above reading speed for one person, with no GPU.
I recorded the eval rate from ollama run --verbose. Server: Hostinger KVM 4 (4 vCPU, 16 GB RAM), Ollama template and Ubuntu 24.04. Tested on December 2, 2026.
| Test | Prompt reading (tokens/sec) | Writing the answer (tokens/sec) | Time | How it felt |
|---|---|---|---|---|
Terminal, llama3.1:8b, short answer (84 tokens) | 20.57 | 8.35 | ~11 s | Usable for one person; you watch it type |
Open WebUI, llama3.1:8b, long answer (661 tokens), model already loaded | 1,524 | 6.16 | 1 min 48 s | Fine for a draft, too slow for live chat |
Open WebUI sends about 2,000 tokens of instructions with even a short question, so the prompt is longer than in the terminal. Reading it is fast; writing the answer is the slow part. The writing speed also drops a little as answers get longer.

People read at roughly 4–5 words per second, so anything above about 5 tokens per second feels usable for chat.
Hosting sales pages, Hostinger’s included, talk about handling “a large number of requests”. On a CPU VPS, that depends heavily on the model size and how many people ask at the same moment. My numbers above are the honest answer for one plan; treat them as a guide for your own setup, not a promise.
My verdict: this setup is a private assistant, not a ChatGPT replacement. It shines when you give it your own text and data. For facts, or for many users at once, it is the wrong tool.
What to expect: where a VPS Llama helps, and where it doesn’t
During my test, I asked it to explain Open WebUI. It confidently said Open WebUI was part of “the Converse.ai platform”, which is false. When I asked how to set up Ollama, it described a config.json file and API keys “from the Ollama website”, which do not exist. A small local model does not know recent or niche tools, and it fills the gap with confident guesses.

| Use it for | Good fit? | Why |
|---|---|---|
| Summarising, rewriting or translating text you paste in | Yes | The answer is based on your text, not the model’s memory |
| Drafting emails, posts and ideas | Yes | Slower than ChatGPT, but the work gets done |
| Questions about your own documents (upload) | Yes | Your files stay on your server |
| Small steps inside n8n automations | Yes | Speed matters less in a background job |
| Facts, new tools, current news | No | It invents answers, as above |
| A live chatbot for many users | No | Requests queue on a CPU; this needs a GPU |
| ChatGPT-like speed | No | 10 seconds to 2 minutes per answer is normal here |
When a GPU makes sense
A CPU VPS stops being enough when speed, model size or user count becomes the bottleneck. I would move to a GPU when any of these is true:
- Many people use it at once. On CPU, requests queue. A customer-facing chatbot needs a GPU.
- You need bigger models. 70B-class models and strong reasoning models are too slow or do not fit on CPU.
- Replies must feel instant. Coding assistants, live support and voice apps need GPU speed.
- You generate images. Stable Diffusion and FLUX are not practical on CPU.
- You run heavy jobs only sometimes. An hourly GPU can cost less than a big VPS that sits idle.
There are two ways to get one. Hourly GPU platforms, such as Hostinger’s new GPU & LLM service (in beta as I write this, billed in credits per hour), RunPod, Vast.ai or DigitalOcean GPU Droplets, let you pick a model and pay for the hours used. A dedicated GPU server rented monthly only makes sense when the GPU is busy most of the day.
The catch: a GPU left running 24/7 costs far more than a VPS. Hourly billing is great for bursts and expensive for always-on.
Troubleshooting
| Problem | Likely cause | Fix |
|---|---|---|
| Open WebUI shows no local models | Not on Ollama’s Docker network, or wrong URL | Join Ollama’s network and set http://<ollama-container>:11434 in Connections |
| First answer takes long to start | Model was unloaded from RAM | Set OLLAMA_KEEP_ALIVE (see the CPU tips) |
| Answers feel slow overall | Extra title, tag and follow-up jobs on the same model | Turn them off in Admin Panel → Settings → Interface |
| Server freezes or Ollama gets killed | Model too big for RAM | Use a smaller model or upgrade the plan |
| Open WebUI hostname shows 404 or Bad Gateway | Traefik picked the wrong Docker network | Add the label traefik.docker.network=<open-webui-project>_default and run docker compose up -d |
| “Ollama is running” still opens from the internet | Traefik route still on | Set traefik.enable=false in Ollama’s compose file (Fix 2) |
To check from outside which ports your server exposes, use my free Port Checker. For other server problems, the Server Troubleshooter walks you through the usual causes.
FAQ
Is my data private on a VPS? Yes. Prompts and documents stay on your server; nothing goes to an outside AI company. Your provider still controls the hardware, so secure the server as shown above.
Can I run Ollama on shared hosting? No. You need root access and several GB of dedicated RAM, which means a VPS or a dedicated server.
Can I connect n8n to this Ollama? Yes. Run n8n on the same VPS, join it to Ollama’s Docker network the same way as Open WebUI, and point its Ollama node to http://ollama-dwkm-ollama-1:11434 (use your container name). Plan for 16 GB RAM or more.
For a ready starting point, my n8n Docker Compose generator builds the compose file for you.
Which Llama should I start with? llama3.2:3b on 8 GB RAM, llama3.1:8b on 16 GB RAM.
Does the WEBSTART code work for existing Hostinger customers? No. It only applies to new customers creating a new Hostinger account.
Free tools for this setup
| Tool | Use it to |
|---|---|
| Port Checker | Confirm Ollama’s old public port is closed after the fixes |
| SSL Checker | Check the HTTPS certificate on your Open WebUI address |
| Security Headers | See which security headers your Open WebUI page sends |
| SSHD Config Hardening | Generate safe SSH settings for the server |
| Fail2ban Config Generator | Build fail2ban rules against brute-force logins |
| Password Generator | Create a strong admin password for Open WebUI |
| DNS Lookup | Check your records if you move Open WebUI to your own domain |
| n8n Docker Compose | Start an n8n stack that can use your local Llama |
| Server Troubleshooter | Work through common VPS problems step by step |
If you want to build it yourself, start with a Hostinger LLM VPS. Ollama comes pre-selected and, as a new customer, the referral discount applies in the cart (or use the code WEBSTART).
Prices, plans, and model versions change often. Everything above was checked on December 2, 2026.









