[{"data":1,"prerenderedAt":188},["ShallowReactive",2],{"seo-verification":3,"blog-how-to-host-privategpt-on-a-vps-ma-en":6,"promo-bar-likely":187},{"google":4,"bing":5},"EycwPY2XMyTkVzas3n1ygeNJFGAH513qrMjfDljzsMQ","",{"key":7,"data":8},"blog-how-to-host-privategpt-on-a-vps-ma-en",{"id":9,"slug":10,"slugs":11,"title":15,"excerpt":16,"readTime":17,"views":18,"isPinned":19,"noindex":19,"publishedAt":20,"updatedAt":21,"category":22,"categories":27,"featuredImage":29,"bgImage":30,"posterImage":31,"relatedSolution":32,"intro":35,"sections":36,"ctaTitle":129,"ctaBody":130,"ctaButton":131,"ctaUrl":132,"relatedPosts":133},16,"how-to-host-privategpt-on-a-vps",{"fr":12,"en":10,"ar":13,"es":14},"heberger-privategpt-vps","كيفية-استضافة-privategpt-على-خادم-vps","como-alojar-privategpt-en-un-vps","How to Host PrivateGPT on a VPS","Deploy PrivateGPT on a VPS to query your confidential documents with a 100% offline RAG AI, with no data leak.",9,1,false,"2026-06-04T00:00:00+00:00","2026-11-08T01:13:12+00:00",{"id":18,"name":23,"slug":24,"color":25,"icon":26},"Artificial Intelligence","intelligence-artificielle","bg-purple-500\u002F10 text-purple-400","ia",[28],{"id":18,"name":23,"slug":24,"color":25,"icon":26},null,"\u002Fblog\u002Fcovers\u002Fbg.svg","\u002Fblog\u002Fcovers\u002Fheberger-privategpt-vps-poster.svg",{"categorySlug":33,"appSlug":34},"artificial-intelligence","private-gpt","PrivateGPT lets you ask questions of your own documents (PDF, Word, emails) via an AI, without any data leaving your infrastructure. It is a RAG solution designed for absolute confidentiality. Hosting it on a VPS gives you a private documentary assistant accessible remotely.",[37,41,51,54,86,89,98,120,123,126],{"type":38,"title":39,"body":40},"h2","Why self-host PrivateGPT on a VPS","PrivateGPT is built around RAG (Retrieval-Augmented Generation): it ingests your documents, splits them into chunks, computes embeddings stored in a vector database (Qdrant by default, in local disk mode), then answers questions from that corpus while citing the passages it used. Since version 1.0, released in June 2026, PrivateGPT no longer runs models itself: it connects to an OpenAI-compatible inference server (Ollama, llama.cpp or vLLM) that you install alongside it on the same VPS. The LLM, the embeddings and the index therefore stay on your machine, and no request goes out to an AI provider.\n\nOn a dedicated VPS, you get a company document assistant isolated from individual workstations, with a centralized knowledge base the whole team can query, without ever exposing contracts, HR files or legal documents to a cloud service. There is a legal angle too: pasting a document containing personal data into a hosted AI API makes that provider a processor under the GDPR, and the processing must be governed by a contract (\u003Ca href=\"https:\u002F\u002Feur-lex.europa.eu\u002Flegal-content\u002FEN\u002FTXT\u002F?uri=CELEX:32016R0679\">Article 28(3)\u003C\u002Fa>). Processing that stays on your own server does not add that link to the chain.",{"type":42,"title":43,"items":44},"ul","Concrete benefits of self-hosting",[45,46,47,48,49,50],"Full confidentiality: documents, embeddings and the Qdrant index never leave the VPS","Sourced answers: every reply relies on passages retrieved from your files, not on the model's general memory","No API costs when the model runs locally through Ollama or llama.cpp","Ingestion of PDF, DOCX, PPTX, EPUB, CSV, Markdown, `.mbox` mail archives and even images or audio, organized into collections","A Messages-style API (modeled on the Anthropic API specification) to plug PrivateGPT into your internal tools","Easier compliance for sensitive data (GDPR, professional secrecy): no additional AI processor",{"type":38,"title":52,"body":53},"PrivateGPT and Ollama: two complementary roles","The two tools are often confused, yet they sit at two different layers of the stack. \u003Ca href=\"\u002Fen\u002Fblog\u002Fhow-to-host-ollama-on-a-vps\">Ollama\u003C\u002Fa> is a **model server**: it downloads LLMs and embedding models, loads them into memory and exposes an API on port `11434`. It knows nothing about your files: it answers from whatever context it is sent.\n\nPrivateGPT (repository \u003Ca href=\"https:\u002F\u002Fgithub.com\u002Fzylon-ai\u002Fprivate-gpt\">zylon-ai\u002Fprivate-gpt\u003C\u002Fa>, Apache-2.0 license) is the **RAG application layer**: it indexes your documents, retrieves the relevant passages for each question and injects them into the context sent to Ollama. In 1.0 it therefore never works alone: without a reachable inference server, it starts with no models at all.",{"type":55,"title":56,"headers":57,"rows":61},"comparison","PrivateGPT vs Ollama: who does what",[58,59,60],"Criterion","PrivateGPT 1.0","Ollama",[62,66,70,74,78,82],[63,64,65],"Role","RAG application: ingestion, search, cited answers","Inference server: loads and runs the models",[67,68,69],"Runs the model","No: delegates to an OpenAI-compatible server","Yes, on CPU or GPU",[71,72,73],"Reads your files","Yes: PDF, DOCX, CSV, `.mbox`… by collection","No: context supplied by hand",[75,76,77],"Vector database","Qdrant (local disk by default)","None",[79,80,81],"Interface","Workbench at `\u002Fui`, no access control","REST API, no server-side web interface",[83,84,85],"Default port","`8080`","`11434`, bound to `127.0.0.1`",{"type":38,"title":87,"body":88},"Hardware and software requirements","Memory is sized for the model Ollama serves, not for PrivateGPT itself. The models suggested by default in the documentation target a GPU machine (`qwen3.5:35b`, about 24 GB to download): on a CPU VPS, pick a lighter variant from the same family, `qwen3.5:4b` (3.3 to 4 GB) or `qwen3.5:9b` (6.6 to 7.6 GB), plus `mxbai-embed-large` (about 670 MB) for embeddings. Plan 8 GB of RAM for the 4b variant and 16 GB for the 9b, to leave room for the system, Qdrant and documents being ingested, and at least 4 vCPUs: on CPU, core count sets generation speed.\n\nAllow 30 GB of disk, ideally NVMe, for models, the Qdrant index and ingested documents: ingesting a large PDF reads and writes a lot. On the software side: Docker (or Python 3.11 and `uv` if you install the package outside a container), Ollama, and a domain pointing to the VPS to expose the interface behind a reverse proxy.",{"type":42,"title":90,"items":91},"Pre-installation checklist",[92,93,94,95,96,97],"A VPS with **at least 8 GB of RAM** (16 GB for a 9-billion-parameter model) and 4 vCPUs","Up-to-date Debian 12 or Ubuntu 24.04, SSH access with `sudo`","Docker installed (`docker version` responds) or, failing that, `uv` with Python 3.11","30 GB of free disk, NVMe preferred, for models and `local_data\u002F`","A subdomain (for example `docs.your-domain.com`) pointing to the VPS IP","An active firewall: only SSH, 80 and 443 open, ports `8080` and `11434` stay closed",{"type":99,"title":100,"steps":101},"steps","Deploying PrivateGPT in local mode",[102,105,108,111,114,117],{"title":103,"body":104},"Install Ollama and pull the models","Install Ollama with the official script, then download a CPU-friendly LLM and the recommended embedding model:\n\n```bash\ncurl -fsSL https:\u002F\u002Follama.com\u002Finstall.sh | sh\nollama pull qwen3.5:4b\nollama pull mxbai-embed-large\n```\n\nBy default Ollama only listens on `127.0.0.1:11434`: keep it that way, only PrivateGPT needs to reach it. This is the only step that needs Internet access; once the models are in place, inference runs offline.",{"title":106,"body":107},"Run PrivateGPT with Docker","The official `zylonai\u002Fprivate-gpt` image ships the `core` package. On Linux the container must share the host network to reach Ollama on `localhost`, and a volume must keep the data, otherwise ingested documents vanish on restart:\n\n```bash\nmkdir -p \u002Fopt\u002Fprivategpt\u002Flocal_data\ndocker run -d --name privategpt --restart unless-stopped \\\n  --network host \\\n  -e OPENAI_API_BASE=http:\u002F\u002Flocalhost:11434\u002Fv1 \\\n  -v \u002Fopt\u002Fprivategpt\u002Flocal_data:\u002Fhome\u002Fworker\u002Fapp\u002Flocal_data \\\n  zylonai\u002Fprivate-gpt:latest\n```\n\nAt startup, PrivateGPT calls `GET \u002Fv1\u002Fmodels` on Ollama and registers the models it finds automatically: no configuration file is required. The `OPENAI_EMBEDDING_API_BASE` variable is only needed if your embeddings are served elsewhere.",{"title":109,"body":110},"Ingest your documents by collection","Send your files to the ingestion API, grouping them into collections, for example one collection per client file or per department:\n\n```bash\ncurl -X POST http:\u002F\u002Flocalhost:8080\u002Fv1\u002Fartifacts\u002Fingest \\\n  -F \"file=@\u002Fsrv\u002Fdocuments\u002Fcontrat-cession.pdf\" \\\n  -F \"collection=legal\"\ncurl \"http:\u002F\u002Flocalhost:8080\u002Fv1\u002Fartifacts\u002Flist?collection=legal\"\n```\n\nPrivateGPT splits, vectorizes and indexes each file in Qdrant. Formats without a dedicated reader are read as plain text.",{"title":112,"body":113},"Query the corpus with citations","Test first in the Workbench (`http:\u002F\u002Flocalhost:8080\u002Fui`), then plug your tools into the Messages API. Document search goes through the built-in `semantic_search_v1` tool, restricted to one collection:\n\n```bash\ncurl http:\u002F\u002Flocalhost:8080\u002Fv1\u002Fmessages \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  -d '{\"model\": \"qwen3.5:4b\",\n       \"messages\": [{\"role\": \"user\", \"content\": \"What are the conditions precedent in the contract?\"}],\n       \"tools\": [{\"name\": \"search_docs\", \"type\": \"semantic_search_v1\",\n                  \"context\": [{\"type\": \"ingested_artifact\", \"context_filter\": {\"collection\": \"legal\"}}]}]}'\n```",{"title":115,"body":116},"Set up the reverse proxy, SSL and authentication","The Workbench has no access control: the documentation reserves it for local use. Expose it only behind Nginx or Caddy, with a Let's Encrypt certificate and basic authentication:\n\n```bash\nserver {\n    listen 443 ssl;\n    server_name docs.your-domain.com;\n    ssl_certificate     \u002Fetc\u002Fletsencrypt\u002Flive\u002Fdocs.your-domain.com\u002Ffullchain.pem;\n    ssl_certificate_key \u002Fetc\u002Fletsencrypt\u002Flive\u002Fdocs.your-domain.com\u002Fprivkey.pem;\n    auth_basic           \"Restricted access\";\n    auth_basic_user_file \u002Fetc\u002Fnginx\u002F.htpasswd;\n    location \u002F { proxy_pass http:\u002F\u002F127.0.0.1:8080; }\n}\n```\n\nIf only two or three people use it, an SSH tunnel (`ssh -L 8080:127.0.0.1:8080 user@your-vps`) avoids any public exposure at all.",{"title":118,"body":119},"Lock down access","PrivateGPT listens on `0.0.0.0` by default, so host networking publishes port `8080` on every interface. Close it at the firewall so that only the reverse proxy is reachable:\n\n```bash\nufw default deny incoming\nufw allow OpenSSH\nufw allow 80,443\u002Ftcp\nufw enable\n```\n\nYour users then go through `https:\u002F\u002Fdocs.your-domain.com` and query the corpus in natural language.",{"type":121,"body":122},"tip","Ollama cannot report its models' context window, so PrivateGPT only estimates tokens roughly: on long documents, answers may come back truncated. Declare `context_window` explicitly in a model profile (a `settings-\u003Cname>.yaml` file, activated with `PGPT_PROFILES`), with a value well below the model's real limit. Also settle on your embedding model from the start: changing it later triggers an \"Embedding dimensions mismatch\" error and forces you to re-index the whole corpus (`embed_dim` is 1024 for `mxbai-embed-large`).",{"type":38,"title":124,"body":125},"Back up and verify that no data leaves","**What to back up.** PrivateGPT's full state lives in `\u002Fopt\u002Fprivategpt\u002Flocal_data` (Qdrant index under `local_data\u002Fqdrant`, ingested files), plus your source documents and any `settings-*.yaml` profiles. Ollama models can be downloaded again, so there is no point backing them up. Stop the container while copying (`docker stop privategpt`), or copy a snapshot of the volume: an index copied during an ingestion may be inconsistent. For several instances or a large team, the documentation recommends a separate Qdrant server rather than local disk mode.\n\n**Check outbound traffic.** Confidentiality is a property of the architecture, and it can be verified. While running a series of questions, list established connections: only PrivateGPT's connections to `127.0.0.1:11434`, the reverse proxy's and your SSH session should appear.\n\n```bash\nss -tnp state established\n```\n\nAny unexpected outbound connection deserves an explanation before you trust the tool with sensitive documents.",{"type":38,"title":127,"body":128},"Troubleshooting: the most common errors","**PrivateGPT starts with no models.** Ollama was not running when the container started, or `OPENAI_API_BASE` is wrong: the URL must end with `\u002Fv1`. Check with `curl http:\u002F\u002Flocalhost:11434\u002Fv1\u002Fmodels`, then restart the container (`docker restart privategpt`).\n\n**\"Connection refused\" from the container.** In a bridge-network container, `localhost` means the container itself. On Linux keep `--network host`; on macOS or Windows, target `host.docker.internal`.\n\n**\"Embedding dimensions mismatch\" during ingestion.** The index was built with a different embedding model. Switch back to the original model, or wipe the vector store (`make wipe` in the repository) and re-ingest the documents.\n\n**Truncated answers on long documents.** The context window is misestimated: declare `context_window` in a model profile (see the tip above).\n\n**Ollama killed mid-answer.** The kernel ran out of memory (OOM): `dmesg | grep -i oom` confirms it. Switch to a smaller variant of the model or add RAM.\n\n**\"Address already in use\" at startup.** Port `8080` is already taken: in Docker, set the `PORT` variable (for example `-e PORT=8090`), outside a container use the `--port` option of `private-gpt serve`, then adjust the Nginx `proxy_pass`.","Build your private documentary assistant","The ServOrbit Cloud VPS provides the RAM and SSD storage needed to run PrivateGPT and its Qdrant vector database locally, with preconfigured Docker for a fast RAG deployment.","Deploy on a Cloud VPS","\u002Fapplications\u002Fartificial-intelligence\u002Fprivate-gpt",[134,152,169],{"id":135,"slug":136,"slugs":137,"title":141,"excerpt":142,"readTime":17,"views":143,"isPinned":19,"noindex":19,"publishedAt":144,"updatedAt":145,"category":146,"categories":147,"featuredImage":29,"bgImage":30,"posterImage":149,"relatedSolution":150},11,"how-to-host-ollama-on-a-vps",{"fr":138,"en":136,"ar":139,"es":140},"heberger-ollama-vps","كيفية-استضافة-ollama-على-خادم-vps","como-alojar-ollama-en-un-vps","Hosting Ollama on a VPS: advanced operational guide","Advanced Ollama VPS setup: model management, nginx reverse proxy, API security, Q4_K_M\u002FQ8 quantization, CVE-2026-45672 Open WebUI and secure coupling.",3,"2026-06-09T00:00:00+00:00","2026-11-04T16:30:24+00:00",{"id":18,"name":23,"slug":24,"color":25,"icon":26},[148],{"id":18,"name":23,"slug":24,"color":25,"icon":26},"\u002Fblog\u002Fcovers\u002Fheberger-ollama-vps-poster.svg",{"categorySlug":33,"appSlug":151},"ollama",{"id":153,"slug":154,"slugs":155,"title":159,"excerpt":160,"readTime":161,"views":162,"isPinned":19,"noindex":19,"publishedAt":163,"updatedAt":164,"category":165,"categories":166,"featuredImage":29,"bgImage":30,"posterImage":168,"relatedSolution":29},316,"open-webui-ollama-on-vps-multi-user-interface-for-local-llms",{"fr":156,"en":154,"ar":157,"es":158},"open-webui-ollama-vps","واجهة-ويب-open-webui-مع-ollama-على-vps-للفرق","open-webui-ollama-en-vps-interfaz-web-multiusuario-para-llm","Open-WebUI + Ollama on VPS: multi-user interface for local LLMs","Give your entire team a multi-user web interface for your Ollama models: RAG, model management, SSO via OpenID Connect — no cloud dependency.",18,7,"2026-08-30T00:00:00+00:00","2026-11-08T01:13:13+00:00",{"id":18,"name":23,"slug":24,"color":25,"icon":26},[167],{"id":18,"name":23,"slug":24,"color":25,"icon":26},"\u002Fblog\u002Fcovers\u002Fopen-webui-ollama-vps-poster.svg",{"id":170,"slug":171,"slugs":172,"title":176,"excerpt":177,"readTime":178,"views":18,"isPinned":19,"noindex":19,"publishedAt":179,"updatedAt":180,"category":181,"categories":182,"featuredImage":29,"bgImage":30,"posterImage":184,"relatedSolution":185},2,"deploying-dify-on-a-vps-ai-workflows-under-control",{"fr":173,"en":171,"ar":174,"es":175},"deployer-dify-vps","نشر-dify-على-vps-سير-عمل-الذكاء-الاصطناعي-تحت-السيطرة","desplegar-dify-en-un-vps","Deploy Dify on a VPS: Complete Guide from Installation to Plugins","Install Dify on a ServOrbit VPS: requirements, Docker Compose, offline plugins, known Docker limits, backup before upgrading, and troubleshooting.",15,"2026-02-11T00:00:00+00:00","2026-10-29T03:10:23+00:00",{"id":18,"name":23,"slug":24,"color":25,"icon":26},[183],{"id":18,"name":23,"slug":24,"color":25,"icon":26},"\u002Fblog\u002Fcovers\u002Fdeployer-dify-vps-poster.svg",{"categorySlug":24,"appSlug":186},"dify",true,1794270428019]