{"id":22591,"date":"2026-11-28T12:03:09","date_gmt":"2026-11-28T09:03:09","guid":{"rendered":"https:\/\/www.hyyat.com\/knowledgebase\/install-nextcloud-on-vps\/"},"modified":"2026-11-28T12:03:12","modified_gmt":"2026-11-28T09:03:12","password":"","slug":"install-nextcloud-on-vps","status":"publish","type":"docs","link":"https:\/\/www.hyyat.com\/en\/knowledgebase\/install-nextcloud-on-vps\/","title":{"rendered":"Install Nextcloud on a VPS: A Private File Cloud for Your Company"},"content":{"rendered":"<div class=\"hkb\" dir=\"ltr\">\n<div class=\"hkb-tldr\"><b>In short<\/b>Nextcloud is an open-source file cloud: sync, sharing, calendars and contacts for your team, with files on <b>your own server<\/b>. Run it with Docker and <b>MariaDB<\/b> behind <b>Caddy<\/b> for HTTPS. Storage usually decides the plan, so size the disk to your team&#8217;s files.<\/div>\n<figure class=\"hkb-fig\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.hyyat.com\/zasogooh\/2026\/11\/hkb-vu-hero-vu-nextcloud-en.webp\" alt=\"Installing Nextcloud on a VPS\" width=\"1200\" height=\"630\" loading=\"lazy\" \/><\/figure>\n<p>Companies that exchange contracts, designs and reports need one organised place for files, with clear permissions per employee. Nextcloud provides that, with phone and desktop apps that sync files automatically, and the data sits on a server you control.<\/p>\n<h2>Choosing resources<\/h2>\n<div class=\"hkb-tbl\">\n<table>\n<thead>\n<tr>\n<th>Use<\/th>\n<th>Suitable plan<\/th>\n<th>Why<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td>A small team with office files<\/td>\n<td>VPS 4GB<\/td>\n<td>Enough memory, 60GB disk to start<\/td>\n<\/tr>\n<tr>\n<td>A mid-size team with images and designs<\/td>\n<td>VPS 8GB<\/td>\n<td>100GB disk and faster previews<\/td>\n<\/tr>\n<tr>\n<td>Many files or video<\/td>\n<td>VPS 16GB<\/td>\n<td>200GB disk, or add external storage<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<h2>1. Install Docker<\/h2>\n<pre class=\"hkb-code\">curl -fsSL https:\/\/get.docker.com | sh\nsystemctl enable --now docker\ndocker compose version<\/pre>\n<h2>2. The docker-compose file<\/h2>\n<pre class=\"hkb-code\">mkdir -p \/opt\/nextcloud &amp;&amp; cd \/opt\/nextcloud<\/pre>\n<pre class=\"hkb-code\">services:\n  db:\n    image: mariadb:11\n    restart: unless-stopped\n    command: --transaction-isolation=READ-COMMITTED\n    environment:\n      - MARIADB_ROOT_PASSWORD=strong-password-1\n      - MARIADB_DATABASE=nextcloud\n      - MARIADB_USER=nextcloud\n      - MARIADB_PASSWORD=strong-password-2\n    volumes:\n      - db:\/var\/lib\/mysql\n  app:\n    image: nextcloud:apache\n    restart: unless-stopped\n    depends_on:\n      - db\n    environment:\n      - MYSQL_HOST=db\n      - MYSQL_DATABASE=nextcloud\n      - MYSQL_USER=nextcloud\n      - MYSQL_PASSWORD=strong-password-2\n      - NEXTCLOUD_TRUSTED_DOMAINS=cloud.example.com\n      - OVERWRITEPROTOCOL=https\n    volumes:\n      - nextcloud:\/var\/www\/html\n  caddy:\n    image: caddy:2\n    restart: unless-stopped\n    ports:\n      - &quot;80:80&quot;\n      - &quot;443:443&quot;\n    volumes:\n      - .\/Caddyfile:\/etc\/caddy\/Caddyfile\n      - caddy_data:\/data\nvolumes:\n  db:\n  nextcloud:\n  caddy_data:<\/pre>\n<p>And the <code>Caddyfile<\/code>:<\/p>\n<pre class=\"hkb-code\">cloud.example.com {\n    reverse_proxy app:80\n}<\/pre>\n<h2>3. Start and first setup<\/h2>\n<pre class=\"hkb-code\">docker compose up -d<\/pre>\n<p>Open <code>https:\/\/cloud.example.com<\/code>, create the admin account, then add team accounts and shared folders for each department. Install the Nextcloud apps on phones and computers to sync.<\/p>\n<h2>Backups<\/h2>\n<ul class=\"hkb-list\">\n<li>A snapshot from the VPS control panel before every update.<\/li>\n<li>A regular copy of the data folder and database to a location off the server.<\/li>\n<li>Upgrade Nextcloud one major version at a time; do not skip versions.<\/li>\n<\/ul>\n<div class=\"hkb-note warn\"><b>A mistake to avoid:<\/b> Treating Nextcloud as a backup. Sync also spreads deletions: if an employee deletes a folder, it disappears from every device. Turn on the trash bin and file versions, and keep a separate backup.<\/div>\n<div class=\"hkb-note\"><b>At Hyyat Host:<\/b> NVMe VPS servers with up to 200GB for your company file cloud: <a href=\"https:\/\/www.hyyat.com\/en\/vps-hosting\/\">VPS plans<\/a>, with our own control panel for power, console and snapshots, and Arabic and English support.<\/div>\n<h2>Frequently asked questions<\/h2>\n<div class=\"hkb-faq\">\n<details>\n<summary>Is Nextcloud an alternative to Google Drive?<\/summary>\n<p>It offers file sync and sharing, calendars and contacts; the difference is that the data is on your server and you are responsible for its upkeep and backups.<\/p>\n<\/details>\n<details>\n<summary>How many users can it handle?<\/summary>\n<p>For small and mid-size teams, a 4GB to 8GB plan is usually enough; storage is what needs more planning.<\/p>\n<\/details>\n<details>\n<summary>Can I add storage later?<\/summary>\n<p>Yes, by upgrading to a larger plan or adding external storage and connecting it to Nextcloud.<\/p>\n<\/details>\n<\/div>\n<div class=\"hkb-rel\"><b>Related guides<\/b><\/p>\n<ul>\n<li><a href=\"https:\/\/www.hyyat.com\/en\/docker-compose-generator\/\">Docker Compose Generator for WordPress and Apps<\/a><\/li>\n<li><a href=\"https:\/\/www.hyyat.com\/en\/vps-setup-script\/\">New VPS Setup Commands, Step by Step<\/a><\/li>\n<li><a href=\"https:\/\/www.hyyat.com\/en\/knowledgebase\/vps-firewall-manage-open-ports\/\">Firewall: Control the Open Ports on Your VPS<\/a><\/li>\n<li><a href=\"https:\/\/www.hyyat.com\/en\/knowledgebase\/when-to-move-from-shared-hosting-to-vps\/\">When Should You Move from Shared Hosting to a VPS? 7 Clear Signs<\/a><\/li>\n<\/ul>\n<p><a href=\"https:\/\/www.hyyat.com\/en\/kb\/servers-without-control-panel\/\">All guides for servers without a panel \u2192<\/a><\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>In shortNextcloud is an open-source file cloud: sync, sharing, calendars and contacts for your team, with files on your own server. Run it with Docker and MariaDB behind Caddy for HTTPS. Storage usually decides the plan, so size the disk to your team&#8217;s files. Companies that exchange contracts, designs and reports need one organised place [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":22581,"comment_status":"open","ping_status":"closed","template":"","meta":{"inline_featured_image":false,"_templately_pack_id":"","_templately_imported_at":"","_templately_source":"","_templately_import_session_id":"","footnotes":""},"doc_category":[2733],"doc_tag":[],"class_list":["post-22591","docs","type-docs","status-publish","has-post-thumbnail","hentry","doc_category-servers-without-control-panel"],"year_month":"2026-11","word_count":518,"total_views":0,"reactions":{"happy":0,"normal":0,"sad":0},"author_info":{"name":"admin","author_nicename":"admin","author_url":"https:\/\/www.hyyat.com\/en\/author\/admin\/"},"doc_category_info":[{"term_name":"Servers Without a Control Panel","term_url":"https:\/\/www.hyyat.com\/en\/kb\/servers-without-control-panel\/"}],"doc_tag_info":[],"knowledge_base_info":[],"knowledge_base_slug":[],"_links":{"self":[{"href":"https:\/\/www.hyyat.com\/en\/wp-json\/wp\/v2\/docs\/22591","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.hyyat.com\/en\/wp-json\/wp\/v2\/docs"}],"about":[{"href":"https:\/\/www.hyyat.com\/en\/wp-json\/wp\/v2\/types\/docs"}],"author":[{"embeddable":true,"href":"https:\/\/www.hyyat.com\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.hyyat.com\/en\/wp-json\/wp\/v2\/comments?post=22591"}],"version-history":[{"count":0,"href":"https:\/\/www.hyyat.com\/en\/wp-json\/wp\/v2\/docs\/22591\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.hyyat.com\/en\/wp-json\/wp\/v2\/media\/22581"}],"wp:attachment":[{"href":"https:\/\/www.hyyat.com\/en\/wp-json\/wp\/v2\/media?parent=22591"}],"wp:term":[{"taxonomy":"doc_category","embeddable":true,"href":"https:\/\/www.hyyat.com\/en\/wp-json\/wp\/v2\/doc_category?post=22591"},{"taxonomy":"doc_tag","embeddable":true,"href":"https:\/\/www.hyyat.com\/en\/wp-json\/wp\/v2\/doc_tag?post=22591"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}