Nextcloud on VPS: your own cloud drive from $10/month

calendar_month марта 15, 2026 schedule 9 min read visibility 6 views
person
Valebyte Team
Nextcloud on VPS: your own cloud drive from $10/month

Want to gain full control over your data and create your own cloud storage without overpaying for subscriptions? Nextcloud on VPS is the ideal solution, allowing you to deploy a powerful and flexible cloud drive with extensive functionality, and you can start for as little as $10/month. This is your personal or corporate self-hosted cloud, which is completely under your control, offering data independence and security.

Why do you need your own Nextcloud on a VPS?

In a world where data privacy is becoming increasingly valuable, the idea of your own Nextcloud on your own server gains particular relevance. Hosting Nextcloud on a VPS offers a number of undeniable advantages:

  • Full data control: Your files are stored on a server that you control, not third-party companies. This is critical for business and personal privacy.
  • Flexibility and customization: Nextcloud offers vast opportunities to extend functionality through apps — from calendars and contacts to video conferencing and collaborative document editing. On a VPS, you can configure it to meet any of your needs.
  • Security: You choose the level of security, configure firewalls, encryption, and backups yourself, without relying on external policies.
  • Long-term savings: For a team of 10-20 people, a monthly subscription to commercial cloud services can be significantly more expensive than renting powerful Nextcloud VPS hosting.
  • Integration: Easily integrates with your other services and infrastructure.

VPS Requirements for Nextcloud: from Minimal to Team-Scale

Choosing the right VPS plan is a key factor for stable and fast operation of Nextcloud VPS. Requirements depend on the number of users, data volume, and intensity of use. Here are the main parameters:

Looking for a reliable server for your projects?

Valebyte offers VPS and dedicated servers with guaranteed resources and fast activation.

View offers →
  • CPU: For basic use (1-5 users), 1-2 vCPUs will suffice. For teams of 10-20 people and active document work, 4-8 vCPUs will be required.
  • RAM: Nextcloud is quite memory-intensive. A minimum of 2 GB is recommended for a single user, but for comfortable work, 4 GB or more is recommended. For 10+ users and the use of additional applications (like Collabora Online), 8-16 GB or more will be needed.
  • Disk: **Always choose SSD.** HDD will be too slow. Disk space depends on the number and size of your files. It is recommended to have extra space, as it fills up quickly.
  • Bandwidth: The more users and the more frequently they synchronize files, the higher the inbound/outbound channels should be. For most tasks, 100-200 Mbps is sufficient, but active use of large files may require 1 Gbps.
  • Operating System: Ubuntu Server (LTS versions) or Debian are the most popular and well-supported options.
  • Stack: PHP (version 8.1+), database (MariaDB or PostgreSQL), web server (Nginx or Apache).

Table: Minimum and Recommended Requirements for Nextcloud

Parameter 1-5 Users (Starter) 5-10 Users (Medium) 10-20+ Users (Advanced)
vCPU 1-2 Cores 2-4 Cores 4-8+ Cores
RAM 2-4 GB 4-8 GB 8-16+ GB
Disk 50-100 GB SSD 100-200 GB SSD 200-500+ GB SSD
Bandwidth 100 Mbps 200 Mbps 1 Gbps

Choosing a VPS Plan on Valebyte.com: How much does your own Nextcloud cost?

On Valebyte.com, you will find a wide selection of VPS plans that are ideal for deploying Nextcloud hosting. Based on the previous table, we can offer the following guidelines:

Table: Example Valebyte VPS Plans for Nextcloud

Purpose Configuration (Valebyte) Estimated Price/Month Comment
Personal Use / Small Team (1-5 users) 2 vCPU, 4 GB RAM, 50-100 GB NVMe SSD From $10-$15 Ideal for getting started with your own Nextcloud. Fast NVMe SSD will ensure excellent performance.
Medium Team (5-10 users) 4 vCPU, 8 GB RAM, 100-200 GB NVMe SSD From $20-$35 Comfortable file handling, ability to use additional applications.
Large Team / Business (10-20+ users) 8 vCPU, 16 GB RAM, 200-500+ GB NVMe SSD From $40-$70+ High performance, support for a large number of active users, scalability.

Please note that prices may vary depending on the chosen server location and current promotions. All our plans include guaranteed bandwidth and fast NVMe SSDs, which is critical for Nextcloud VPS hosting.

Preparing your VPS for Nextcloud Installation

After choosing and renting a VPS, the first step is to prepare it. We will use Ubuntu Server 22.04 LTS and the LEMP stack (Linux, Nginx, MariaDB, PHP-FPM).

1. System Update

sudo apt update && sudo apt upgrade -y
sudo apt install curl wget unzip -y

2. Installing Nginx, MariaDB, and PHP-FPM

sudo apt install nginx mariadb-server php-fpm php-mysql php-gd php-json php-curl php-intl php-imagick php-xml php-zip php-mbstring php-gmp php-bcmath php-apcu redis-server -y

We immediately include the necessary PHP modules, APCu, and Redis for future optimization.

3. MariaDB Configuration

Run the script for basic security:

sudo mysql_secure_installation

Answer the questions: set a password for root, remove anonymous users, disallow remote root login, and remove the test database.

Create a database and user for Nextcloud:

sudo mysql -u root -p
-- Enter your MariaDB root password
CREATE DATABASE nextcloud_db CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci;
CREATE USER 'nextcloud_user'@'localhost' IDENTIFIED BY 'YOUR_STRONG_PASSWORD';
GRANT ALL PRIVILEGES ON nextcloud_db.* TO 'nextcloud_user'@'localhost';
FLUSH PRIVILEGES;
EXIT;

Replace YOUR_STRONG_PASSWORD with a strong password.

4. Basic Firewall Configuration (UFW)

sudo ufw allow OpenSSH
sudo ufw allow 'Nginx Full'
sudo ufw enable

Nextcloud Installation: Step-by-Step Guide

1. Downloading Nextcloud

Navigate to the web server directory and download the latest stable version of Nextcloud:

cd /var/www/
sudo wget https://download.nextcloud.com/server/releases/latest.zip
sudo unzip latest.zip
sudo mv nextcloud html # Or another name, e.g., yourdomain.com

2. Setting Permissions

This is a critically important step for security and correct operation.

sudo chown -R www-data:www-data /var/www/html/
sudo find /var/www/html/ -type d -exec chmod 750 {} \;
sudo find /var/www/html/ -type f -exec chmod 640 {} \;

3. Nginx Configuration

Create a configuration file for your domain (e.g., /etc/nginx/sites-available/yourdomain.com.conf):

server {
    listen 80;
    server_name yourdomain.com www.yourdomain.com; # Replace with your domain

    # Add redirect to HTTPS, which will be configured later
    # return 301 https://$host$request_uri;

    root /var/www/html/; # Path to your Nextcloud installation

    index index.php index.html index.htm;

    location / {
        try_files $uri $uri/ /index.php?$query_string;
    }

    location ~ \.php(?:$|/) {
        fastcgi_split_path_info ^(.+\.php)(/.+)$;
        include fastcgi_params;
        fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
        fastcgi_param PATH_INFO $fastcgi_path_info;
        fastcgi_pass unix:/var/run/php/php8.1-fpm.sock; # Make sure the PHP version is correct
        fastcgi_intercept_errors on;
        fastcgi_buffer_size 128k;
        fastcgi_buffers 4 256k;
        fastcgi_busy_buffers_size 256k;
    }

    # Deny access to sensitive files and directories
    location ~ /\.ht {
        deny all;
    }

    location ~ /\.(?:sqlite|sql|ini|log)$ {
        deny all;
        return 404;
    }

    # Deny access to data directories
    location ~ /(?:build|tests|config|lib|3rdparty|templates|data)/ {
        deny all;
    }

    # Deny access to .ocdata files
    location ~ ^/(?:updater|ocdata)/ {
        internal;
    }
}

Activate the configuration and restart Nginx:

sudo ln -s /etc/nginx/sites-available/yourdomain.com.conf /etc/nginx/sites-enabled/
sudo nginx -t
sudo systemctl restart nginx

4. Completing Nextcloud Installation via Web Interface

Now open your domain in a browser (http://yourdomain.com). You will be prompted to create an administrator account, specify the data path (default /var/www/html/data), and provide database connection details (DB name, user, password). Choose MariaDB/MySQL.

Configuring SSL for Nextcloud with Let's Encrypt

Using SSL/TLS with Let's Encrypt is absolutely essential for the security of your Nextcloud VPS. It's free and automated.

sudo apt install certbot python3-certbot-nginx -y
sudo certbot --nginx -d yourdomain.com -d www.yourdomain.com

Follow the Certbot instructions. It will automatically update your Nginx configuration, adding HTTPS and setting up automatic certificate renewal.

After this, ensure that the following lines are added to the /var/www/html/config/config.php file:

'overwrite.cli.url' => 'https://yourdomain.com',
'overwritehost' => 'yourdomain.com',
'overwriteprotocol' => 'https',

And restart Nginx.

Optimizing Nextcloud for 10+ Users: Boosting Performance

For team use, your own Nextcloud requires additional optimization to avoid slowdowns. This is especially relevant for Nextcloud VPS hosting with a large number of users.

1. Caching with Redis

Redis significantly speeds up Nextcloud, especially for file caching and locking.

Ensure Redis is installed (we did this earlier).

Open /var/www/html/config/config.php and add the following lines:

<?php
$CONFIG = array (
  // ... existing settings ...
  'memcache.local' => '\\OC\\Memcache\\APCu',
  'memcache.distributed' => '\\OC\\Memcache\\Redis',
  'memcache.locking' => '\\OC\\Memcache\\Redis',
  'redis' => array(
     'host' => 'localhost',
     'port' => 6379,
     'timeout' => 0.0,
     'password' => '', // Leave empty if Redis is not password protected
     'dbindex' => 0,
  ),
);

Check Redis status:

sudo systemctl status redis-server

2. PHP-FPM Configuration

Optimize PHP-FPM for better performance. Edit /etc/php/8.1/fpm/pool.d/www.conf (or the corresponding PHP version file):

  • pm = dynamic
  • pm.max_children = 50 (depends on RAM, 10-20 per GB RAM)
  • pm.start_servers = 5
  • pm.min_spare_servers = 5
  • pm.max_spare_servers = 30
  • request_terminate_timeout = 300

Also check memory_limit in /etc/php/8.1/fpm/php.ini and /etc/php/8.1/cli/php.ini, setting it to 512M or 1024M.

sudo systemctl restart php8.1-fpm

3. Cron Jobs

Configure system Cron to execute Nextcloud background tasks; this is much more efficient than AJAX.

sudo -u www-data crontab -e

Add the line:

*/5 * * * * php -f /var/www/html/cron.php --define apc.enable_cli=1

4. Database Optimization

For MariaDB/MySQL, you can configure innodb_buffer_pool_size in /etc/mysql/mariadb.conf.d/50-server.cnf. Allocate 50-70% of available RAM if the database is on the same server and there are no other demanding applications. For example, for 8 GB RAM: innodb_buffer_pool_size = 4G.

sudo systemctl restart mariadb

5. Swap File

If you have a limited amount of RAM (less than 8 GB) and plan to actively use Nextcloud, create a swap file. This will help avoid crashes during peak loads, although it will slow down performance if actively used.

sudo fallocate -l 2G /swapfile # Create a 2 GB swap file
sudo chmod 600 /swapfile
sudo mkswap /swapfile
sudo swapon /swapfile

For persistent use, add the following line to /etc/fstab:

/swapfile none swap sw 0 0

Regular Maintenance and Security

  • Updates: Regularly update Nextcloud and the operating system.
  • Backup: Configure automatic backups of Nextcloud files and the database.
  • Monitoring: Monitor CPU, RAM, and disk usage to detect issues in time.

Conclusion

Deploying Nextcloud on a VPS is not just about creating cloud storage; it's an investment in your digital independence and data security. With Valebyte.com, you get a reliable foundation in the form of high-performance VPS with NVMe SSDs, which are ideal for Nextcloud VPS hosting.

By following this guide, you will be able to not only install but also optimize your own Nextcloud for comfortable work for a team of 10 or more users, while maintaining control over your budget and data. Start your journey to your own self-hosted cloud today by choosing a suitable plan on Valebyte.com!

Ready to choose a server?

Compare VPS and dedicated servers from trusted providers on Valebyte.

Get started now →

Share this post: