[{"data":1,"prerenderedAt":143},["ShallowReactive",2],{"seo-verification":3,"blog-how-to-host-langflow-on-a-vps-en":6},{"google":4,"bing":5},"EycwPY2XMyTkVzas3n1ygeNJFGAH513qrMjfDljzsMQ","",{"id":7,"slug":8,"slugs":9,"title":12,"excerpt":13,"readTime":7,"views":14,"isPinned":15,"publishedAt":16,"category":17,"categories":23,"featuredImage":25,"bgImage":26,"posterImage":27,"relatedSolution":28,"intro":31,"sections":32,"ctaTitle":92,"ctaBody":93,"ctaButton":94,"ctaUrl":95,"relatedPosts":96},10,"how-to-host-langflow-on-a-vps",{"fr":10,"en":8,"ar":11},"heberger-langflow-vps","كيفية-استضافة-langflow-على-خادم-vps","How to host LangFlow on a VPS: complete Docker and HTTPS guide","Deploy LangFlow on your VPS with Docker, PostgreSQL and an nginx reverse proxy over HTTPS. Prerequisites, step-by-step install, security and troubleshooting.",0,false,"2026-06-10T00:00:00+00:00",{"id":18,"name":19,"slug":20,"color":21,"icon":22},1,"Artificial Intelligence","intelligence-artificielle","bg-purple-500\u002F10 text-purple-400","ia",[24],{"id":18,"name":19,"slug":20,"color":21,"icon":22},null,"\u002Fblog\u002Fcovers\u002Fbg.svg","\u002Fblog\u002Fcovers\u002Fheberger-langflow-vps-poster.svg",{"categorySlug":29,"appSlug":30},"artificial-intelligence","langflow","LangFlow is a visual AI pipeline editor — RAG, chatbots, LangChain agents — that runs in your browser and exposes each flow as a Python API. Hosted on your VPS, it becomes a private, shareable workshop: your flows, API keys and execution history stay under your control, never passing through an external SaaS. This guide covers the full installation with Docker Compose, PostgreSQL, nginx reverse proxy and HTTPS.",[33,37,48,51,79,82,86,89],{"type":34,"title":35,"body":36},"h2","Why host LangFlow on a VPS","LangFlow addresses a specific use case: designing AI pipelines by dragging and dropping components — LLM models, retrievers, prompts, memory, agents — then testing them without writing a single line of code. It is the visual alternative to code-only LangChain, suited to teams that want to iterate quickly before committing logic to Python.\n\nOn a VPS, you get a stable and persistent instance accessible to the whole team, unlike a local setup that disappears on reboot. Your flows often encode sensitive business logic — prompt chains, API keys, connectors to your databases. This data should not pass through a SaaS whose data retention policy you do not control.\n\nLangFlow relies on FastAPI on the server side and exposes each flow as a REST endpoint: your applications can call your AI pipelines directly, with no intermediary code. It is this combination — visual interface for design, API for integration — that makes it a serious prototyping tool for use cases such as document RAG, support chatbots, multi-step agents, or classification pipelines.",{"type":38,"title":39,"items":40},"ul","What you gain with a self-hosted instance",[41,42,43,44,45,46,47],"**Visual pipeline interface** — drag LLM, retriever, memory, and prompt components onto a canvas, connect them, and test without code.","**Multiple LLM connectors** — OpenAI, Anthropic, Ollama (local), Hugging Face, and any OpenAI-compatible provider.","**Built-in RAG** — load PDF or text documents, with chunking, embedding and vector search in the same flow.","**Automatic API per flow** — each pipeline becomes a REST endpoint callable from any application.","**Encrypted global variables** — your API keys are stored server-side, never exposed in the client code.","**Custom Python components** — extend LangFlow with your own business logic without forking the project.","**Flow version control** — export as JSON and version in Git, independently of the database state.",{"type":34,"title":49,"body":50},"Prerequisites before you start","LangFlow is more memory-intensive than a typical web application: its execution engine loads models and embeddings into RAM. Plan for at least **2 vCPU and 4 GB of RAM** for comfortable use. If you connect a local Ollama model for inference on the same VPS, move to 8 GB minimum.\n\nOn the software side, you need Docker (version 24 or later) and Docker Compose v2, installed and running. Port `7860` must be accessible locally (LangFlow listens on this port by default). You do not expose this port directly to the internet: the nginx reverse proxy handles that.\n\nPrepare a subdomain pointing to your VPS IP — for example `langflow.your-domain.com` — with DNS records already propagated before running certbot. Finally, a PostgreSQL database is strongly recommended for production: the default SQLite corrupts under concurrent load and does not support simultaneous access by multiple users.",{"type":52,"title":53,"steps":54},"steps","Install LangFlow with Docker Compose and PostgreSQL",[55,58,61,64,67,70,73,76],{"title":56,"body":57},"Create the working directory","Log in to your VPS via SSH, then create the folder that will host the stack:\n\n```bash\nmkdir -p \u002Fopt\u002Flangflow && cd \u002Fopt\u002Flangflow\n```",{"title":59,"body":60},"Write the docker-compose.yml file","Create a `docker-compose.yml` file with two services — `postgres` and `langflow` — and authentication environment variables:\n\n```yaml\nservices:\n  postgres:\n    image: postgres:16\n    restart: unless-stopped\n    environment:\n      POSTGRES_USER: langflow\n      POSTGRES_PASSWORD: strong-password\n      POSTGRES_DB: langflow\n    volumes:\n      - pgdata:\u002Fvar\u002Flib\u002Fpostgresql\u002Fdata\n\n  langflow:\n    image: langflowai\u002Flangflow:latest\n    restart: unless-stopped\n    ports:\n      - \"127.0.0.1:7860:7860\"\n    environment:\n      LANGFLOW_DATABASE_URL: postgresql:\u002F\u002Flangflow:strong-password@postgres:5432\u002Flangflow\n      LANGFLOW_SECRET_KEY: change-this-to-a-random-string\n      LANGFLOW_AUTO_LOGIN: \"false\"\n      LANGFLOW_SUPERUSER: admin\n      LANGFLOW_SUPERUSER_PASSWORD: strong-admin-password\n    depends_on:\n      - postgres\n\nvolumes:\n  pgdata:\n```\n\nNote that port `7860` is bound to `127.0.0.1`: LangFlow is not reachable from the outside without going through the proxy.",{"title":62,"body":63},"Start the stack","Start both containers in the background:\n\n```bash\ndocker compose up -d\n```\n\nFollow LangFlow logs during the first initialization (schema creation in the database, roughly 30 seconds to 1 minute):\n\n```bash\ndocker compose logs -f langflow\n```\n\nWait for the line indicating that the server is listening on port `7860` before continuing.",{"title":65,"body":66},"Verify the interface responds","From your VPS, test that LangFlow responds locally before setting up the proxy:\n\n```bash\ncurl -s http:\u002F\u002F127.0.0.1:7860\u002Fhealth\n```\n\nThe expected response is `{\"status\":\"ok\"}`. If you get a connection refused error, the startup logs contain the cause.",{"title":68,"body":69},"Configure the nginx reverse proxy with HTTPS","Install nginx and certbot if not already done, then create a configuration file:\n\n```nginx\nserver {\n    listen 80;\n    server_name langflow.your-domain.com;\n    return 301 https:\u002F\u002F$host$request_uri;\n}\n\nserver {\n    listen 443 ssl;\n    server_name langflow.your-domain.com;\n\n    ssl_certificate \u002Fetc\u002Fletsencrypt\u002Flive\u002Flangflow.your-domain.com\u002Ffullchain.pem;\n    ssl_certificate_key \u002Fetc\u002Fletsencrypt\u002Flive\u002Flangflow.your-domain.com\u002Fprivkey.pem;\n\n    location \u002F {\n        proxy_pass http:\u002F\u002F127.0.0.1:7860;\n        proxy_http_version 1.1;\n        proxy_set_header Upgrade $http_upgrade;\n        proxy_set_header Connection \"upgrade\";\n        proxy_set_header Host $host;\n        proxy_set_header X-Real-IP $remote_addr;\n    }\n}\n```\n\nThe `Upgrade` and `Connection` headers are essential for WebSocket support, used by the interactive canvas. Obtain the certificate with certbot:\n\n```bash\ncertbot --nginx -d langflow.your-domain.com\n```",{"title":71,"body":72},"Log in and create your first flow","Open `https:\u002F\u002Flangflow.your-domain.com` in your browser. Log in with the credentials set in `LANGFLOW_SUPERUSER` and `LANGFLOW_SUPERUSER_PASSWORD`. In the interface, click **New Flow**, choose a template or start from an empty canvas. Add an LLM component, a prompt and an output component, connect them, then click **Run** to test the pipeline.",{"title":74,"body":75},"Store API keys in global variables","Rather than entering your API keys in each component, use **Global Variables** (icon at the top right): the key is encrypted in the database and reusable across all your flows. From the **API** menu of a flow, you retrieve the `curl` or Python call code to integrate this pipeline into an external application.",{"title":77,"body":78},"Back up flows and the database","Schedule a daily `pg_dump` of the database from the host:\n\n```bash\ndocker exec langflow-postgres-1 pg_dump -U langflow langflow > \u002Fopt\u002Fbackups\u002Flangflow-$(date +%F).sql\n```\n\nAlso export your flows as JSON from the **Export** menu of each flow: it is a versionable safety net in Git, independent of the database state.",{"type":34,"title":80,"body":81},"Advanced configuration: useful environment variables","LangFlow exposes several environment variables to adapt the instance to your context. `LANGFLOW_SECRET_KEY` encrypts sensitive data stored in the database — change the default value before first startup, as a later rotation invalidates existing encrypted data. `LANGFLOW_AUTO_LOGIN` set to `false` always requires an explicit login, even from `localhost`. `LANGFLOW_WORKERS` controls the number of Uvicorn processes: the default value (`1`) is suitable for moderate use, increase to `2` or `4` if multiple users execute flows simultaneously.\n\nFor flows that call local models via Ollama, define `OLLAMA_BASE_URL` in LangFlow's global variables rather than in the Docker environment: the value is then managed by the interface and can be changed without a restart.\n\nIf you update LangFlow, always do a `pg_dump` before `docker compose pull && docker compose up -d`: some version upgrades touch the database schema.",{"type":83,"title":84,"body":85},"tip","Security: do not expose LangFlow directly to the internet","LangFlow has no built-in rate limiting on its API endpoints. Without additional measures, a publicly exposed flow can be called without limit by anyone who knows the URL. Two approaches complement each other.\n\nFirst, keep `LANGFLOW_AUTO_LOGIN=false` permanently and create distinct user accounts for each team member. Second, if your flows should only be called by your own applications (rather than by direct users), add an `auth_basic` nginx block in front of the management interface and expose only the `\u002Fapi\u002Fv1\u002Frun\u002F\u003Cflow-id>` endpoints with token authentication to your applications.\n\nNever leave LangFlow in production with SQLite: the database corrupts under concurrent access and you lose your flows without an explicit error message.",{"type":34,"title":87,"body":88},"Troubleshooting common errors","**OOM error (Out of Memory).** If the LangFlow container restarts spontaneously, check `docker compose logs langflow` and look for `Killed`. The cause is insufficient RAM. Reduce `LANGFLOW_WORKERS` to `1` and, if the problem persists, increase the VPS RAM or avoid running heavy flows simultaneously.\n\n**Connection refused to Ollama.** If LangFlow cannot reach Ollama running on the same VPS, check that Ollama listens on `0.0.0.0` and not only on `127.0.0.1`. In `docker-compose.yml`, add `extra_hosts: [\"host-gateway:host-gateway\"]` to the LangFlow service and use the address `http:\u002F\u002Fhost-gateway:11434` in LangFlow's Ollama components.\n\n**Missing or incomplete flow logs.** LangFlow stores execution logs in the database. If the PostgreSQL database was not ready when LangFlow started, the first requests fail silently. The `depends_on` in `docker-compose.yml` waits for the Postgres container to start, but not necessarily for PostgreSQL to be ready to accept connections. Add a `healthcheck` on the `postgres` service to force the wait.\n\n**Blank canvas or disconnected WebSocket.** Check that the `Upgrade` and `Connection` headers are properly forwarded by nginx. An intermediate proxy (Cloudflare in Full Strict mode, load balancer) may intercept WebSockets: ensure the WebSocket protocol is properly configured in the proxy.",{"type":34,"title":90,"body":91},"Next steps: extending your LangFlow instance","Once LangFlow is running, several integrations expand its scope.\n\nIf you want a fully local LLM model (without any external API call), install Ollama on the same VPS and connect it to LangFlow via the **Ollama** component: your pipelines no longer send data outside your infrastructure. Ollama exposes an OpenAI-compatible API on port `11434`.\n\nFor document RAG, add a **Chroma** or **Qdrant** component — two open source vector databases you can deploy in a neighboring container. Import your PDF documents into a LangFlow flow, chunking and embedding included, and query them from a chatbot or an API.\n\nFinally, if multiple teams use the instance, consider isolating flows by workspace (feature available depending on the version) or deploying one LangFlow instance per project with the ServOrbit template, which automatically configures Docker Compose, PostgreSQL and the reverse proxy.","Host LangFlow on a dedicated VPS","Deploy your own LangFlow instance in minutes on a ServOrbit VPS — full privacy, no API rate limits, secure HTTPS access with TLS certificate included.","Deploy LangFlow","\u002Fmarketplace\u002Fartificial-intelligence\u002Flangflow",[97,112,128],{"id":18,"slug":98,"slugs":99,"title":102,"excerpt":103,"readTime":104,"views":14,"isPinned":15,"publishedAt":105,"category":106,"categories":107,"featuredImage":25,"bgImage":26,"posterImage":109,"relatedSolution":110},"how-to-host-open-webui-on-a-vps",{"fr":100,"en":98,"ar":101},"heberger-open-webui","كيفية-استضافة-open-webui-على-خادم-vps","How to Host Open WebUI on a VPS","A complete guide to deploying Open WebUI on your own VPS. Keep control of your data, avoid cloud API costs, and access your LLMs from a clean web interface.",4,"2026-06-01T00:00:00+00:00",{"id":18,"name":19,"slug":20,"color":21,"icon":22},[108],{"id":18,"name":19,"slug":20,"color":21,"icon":22},"\u002Fblog\u002Fcovers\u002Fheberger-open-webui-poster.svg",{"categorySlug":29,"appSlug":111},"open-webui",{"id":113,"slug":114,"slugs":115,"title":118,"excerpt":119,"readTime":120,"views":14,"isPinned":15,"publishedAt":121,"category":122,"categories":123,"featuredImage":25,"bgImage":26,"posterImage":125,"relatedSolution":126},2,"deploying-dify-on-a-vps-ai-workflows-under-control",{"fr":116,"en":114,"ar":117},"deployer-dify-vps","نشر-dify-على-vps-سير-عمل-الذكاء-الاصطناعي-تحت-السيطرة","Deploying Dify on a VPS: AI Workflows Under Control","Install Dify on a ServOrbit VPS to build agents, chatflows and AI apps without losing control of your data.",3,"2026-02-11T00:00:00+00:00",{"id":18,"name":19,"slug":20,"color":21,"icon":22},[124],{"id":18,"name":19,"slug":20,"color":21,"icon":22},"\u002Fblog\u002Fcovers\u002Fdeployer-dify-vps-poster.svg",{"categorySlug":29,"appSlug":127},"dify",{"id":129,"slug":130,"slugs":131,"title":134,"excerpt":135,"readTime":120,"views":14,"isPinned":15,"publishedAt":136,"category":137,"categories":138,"featuredImage":25,"bgImage":26,"posterImage":140,"relatedSolution":141},121,"hosting-openclaw-on-a-vps",{"fr":132,"en":130,"ar":133},"heberger-openclaw-vps","استضافة-openclaw-على-خادم-vps","Hosting OpenClaw on a VPS","Host OpenClaw on your VPS: the open source personal AI assistant reachable from WhatsApp, Telegram, Discord and 50+ messaging apps. Docker, LLM setup and HTTPS.","2026-02-23T00:00:00+00:00",{"id":18,"name":19,"slug":20,"color":21,"icon":22},[139],{"id":18,"name":19,"slug":20,"color":21,"icon":22},"\u002Fblog\u002Fcovers\u002Fheberger-openclaw-vps-poster.svg",{"categorySlug":29,"appSlug":142},"openclaw",1787661722850]