
Tired of paying monthly subscriptions for Google One, Dropbox Pro, or OneDrive Plus? Want complete control over your sensitive data without routing it through external corporations' datacenters? Nextcloud lets you build a self-hosted cloud storage solution on your own VPS — a private Google Drive and Dropbox alternative. This guide walks you through installation on Ubuntu, step by step, so you can own your cloud storage and save money long-term.
What is Nextcloud?
Nextcloud is an open-source file hosting platform. You download it, install it on your own server, and instantly gain a private cloud. Unlike Google Drive or Dropbox (where data sits in corporate datacenters), Nextcloud stores everything on YOUR VPS, under YOUR control. Access and permissions? You decide. Who can see your files? You control that. All data remains encrypted in your server's storage.
The core appeal is ownership. Nextcloud is software, not a subscription service. You pay only for the VPS that hosts it. AsiaGB offers Linux VPS starting at just 500 baht/month with root access — far cheaper than annual subscriptions to cloud storage rivals. More importantly, you get unlimited storage (limited only by your VPS disk size) rather than paying per gigabyte like Google or Microsoft.
Why Self-Host Nextcloud on a VPS?
Three major advantages stand out. First, Privacy. Your data never passes through Google, Microsoft, or Dropbox servers. No tracking, no data-sharing with advertisers, no compliance with foreign government requests. You're the sole administrator. Second, Permanent cost savings. A VPS at 500 baht/month costs 6,000 baht/year — cheaper than most annual cloud storage plans — yet you get unlimited storage (your disk size). Third, Feature-rich ecosystem. Nextcloud includes Collabora for real-time document editing (like Google Docs), built-in Calendar, Contacts, Bookmarks, Tasks. No need to buy Office 365 or other tools separately.
Downsides? You maintain the server. You apply security updates. You arrange backups. It's ideal for privacy-conscious teams or organizations with specific data residency needs. For "set and forget" users, Google Drive remains simpler.
VPS Requirements
Nextcloud demands Linux (Ubuntu 20.04 LTS or 22.04 LTS recommended), PHP 7.4 or newer (8.2+ preferred), MySQL 5.7+ or MariaDB 10.3+, Apache or Nginx with rewrite support, and an SSL certificate (mandatory).
Hardware minimums: 1 CPU core, 2 GB RAM, 20 GB SSD storage. This handles 5–10 concurrent users comfortably. AsiaGB's entry-level VPS meets these specs exactly — 1 Core, 2 GB RAM, 20 GB SSD Linux VPS at 500 baht/month, available on servers in Thailand (CS Loxinfo) or Singapore (OVHcloud). Customers get full root access, allowing you to install and configure Nextcloud your way.
Step 1: Provision VPS and Prepare Environment
Order a Linux VPS with Ubuntu 20.04 or 22.04. Register a domain name (e.g., mycloud.yourdomain.com) and point its DNS A record to your VPS IP. Then, arrange an SSL certificate. AsiaGB offers free Let's Encrypt (auto-renewal included) or paid certificates starting at 1,000 baht/year. Finally, SSH into your VPS using credentials provided in your account.
Step 2: Install LAMP or LEMP Stack
Update system packages, then install web server and database. For Apache:
sudo apt update && sudo apt upgrade -ysudo apt install -y apache2 libapache2-mod-php php-mysql php-gd php-curl php-json php-zip php-xml php-mbstringsudo apt install -y mysql-server- Enable services:
sudo systemctl enable apache2 mysql-server - Start services:
sudo systemctl start apache2 mysql-server
Alternatively, choose Nginx instead of Apache if you prefer. Both work equally well with Nextcloud.
Step 3: Create MySQL Database and User
Log into MySQL and execute these SQL commands:
sudo mysql -u rootCREATE DATABASE nextcloud;CREATE USER 'nextcloud_user'@'localhost' IDENTIFIED BY 'your-strong-password';GRANT ALL PRIVILEGES ON nextcloud.* TO 'nextcloud_user'@'localhost';FLUSH PRIVILEGES; EXIT;
Use a genuinely strong password, not "123456." This protects your database from brute-force attacks.
Step 4: Download and Extract Nextcloud
Navigate to your web server's document root and download Nextcloud:
cd /var/www/htmlsudo wget https://download.nextcloud.com/server/releases/latest.zipsudo unzip latest.zipsudo chown -R www-data:www-data nextcloudsudo chmod -R 755 nextcloud
Then, visit https://mycloud.yourdomain.com/nextcloud in your browser (HTTPS is mandatory).
Step 5: Complete Nextcloud Setup via Web Interface
Nextcloud's web installer appears. Create an admin username and password, select MySQL as your database, enter the database name (nextcloud), database user (nextcloud_user), and password you created earlier. Click "Finish Setup." Nextcloud initializes the database automatically. After a minute, you're logged in and ready to use your private cloud.
Step 6: Secure with SSL Certificate
Install and activate SSL using Certbot:
sudo apt install -y certbot python3-certbot-apachesudo certbot --apache -d mycloud.yourdomain.com
Certbot automatically generates the certificate and configures Apache to renew it before expiration. Access https://mycloud.yourdomain.com/nextcloud from now on.
Step 7: Whitelist Your Domain in Trusted Domains
Nextcloud may reject requests from domains not in its whitelist. Edit the config file:
sudo nano /var/www/html/nextcloud/config/config.php- Find the 'trusted_domains' array and add your domain:
'trusted_domains' => array (0 => 'localhost', 1 => 'mycloud.yourdomain.com'), - Save and exit (Ctrl+X, then Y, then Enter in nano)
Step 8: Install Desktop and Mobile Clients
Download Nextcloud Desktop Client from https://nextcloud.com/install/#install-clients for Windows, Mac, or Linux. Install the Nextcloud Mobile App on iPhone or Android. Enter your server URL, username, and password. Files sync across all devices in real-time. Changes on your phone appear on your desktop instantly, and vice versa.
Critical: Backup Strategy
Backups are your safety net. Back up three components: Nextcloud application files (/var/www/html/nextcloud), MySQL database, and user data folders. Schedule regular backups (e.g., twice monthly) to external storage (external HDD, AWS S3, Google Drive backup folder). AsiaGB's VPS includes automatic backups on the 1st and 15th of each month, providing a baseline. Add your own external backup for defense-in-depth — a 2-3 backup strategy is standard practice at enterprises.
Tip: If your shared hosting doesn't provide root access, Nextcloud won't work there. You need a VPS with full SSH root access. AsiaGB offers Linux VPS starting at 500 baht/month with complete root control, SSD storage, 99% uptime guarantee, and automatic backup support twice monthly on the 1st and 15th.
Frequently Asked Questions
How does Nextcloud differ from Google Drive or Dropbox?
Nextcloud runs on your own server. Your data never passes through external corporations. Perfect for teams requiring maximum privacy control, though you're responsible for server maintenance. Google Drive and Dropbox handle everything, convenient but charged monthly.
What Linux skills do I need to install Nextcloud on VPS?
You'll need basic Linux knowledge: SSH login, terminal commands (cd, sudo, apt-get, nano), and MySQL basics. If you're new to Linux, this tutorial walks through each step. You can also contact AsiaGB support at [email protected] for help — they speak English.
What VPS specifications does Nextcloud require?
Minimum: 1 Core CPU, 2 GB RAM, 20 GB SSD running Ubuntu 20.04 LTS or later, PHP 7.4+, MySQL 5.7+, Apache or Nginx. AsiaGB offers Linux VPS starting at just 500 baht/month with these specs, full root access, and Thailand or Singapore datacenters.
Is SSL certificate mandatory for Nextcloud?
Yes. Nextcloud enforces HTTPS connections. Use free Let's Encrypt (auto-renewable) or purchase a paid SSL certificate. AsiaGB sells SSL certificates from 1,000 baht/year. Both options are equally secure.
How should I backup Nextcloud data?
Backup three components: Nextcloud files, MySQL database, and user data folders. Perform backups regularly (e.g., twice monthly). AsiaGB VPS includes automatic backups on the 1st and 15th of each month, but adding your own external backup (to HDD, Google Drive, etc.) provides extra safety.
Which ports does Nextcloud use?
Nextcloud uses standard web ports: 80 (HTTP) and 443 (HTTPS). Configure via Apache Virtual Hosts or Nginx Server Blocks. If using Docker, set port mappings in your docker-compose file.
Get Started with Nextcloud Today
Order a Linux VPS from AsiaGB for just 500 baht/month. Includes root access, SSD storage, 99% uptime, and automatic backups twice per month (1st and 15th).
Order Linux VPS Now