Why host your private cloud on a VPS
Storing your files with a consumer provider means accepting quotas, growing storage fees and uncertainty over data residency. A self-hosted private cloud makes you the owner of your Drive: desktop and mobile synchronization, sharing by link, collaborative document editing and calendar/contacts via CalDAV/CardDAV, all on your own hardware. Nextcloud goes beyond simple storage with a well-stocked app store (Talk for video calls, Office for editing, Flow for automation). ownCloud, in its historical PHP version, remains a robust and lighter file manager; its new-generation Infinite Scale, written in Go, adopts a far faster and stateless microservices architecture. The choice depends on your need: a complete suite or high-performance storage.
What a self-hosted private cloud provides
- Multi-device synchronization with no imposed quota, limited only by your VPS's disk.
- Data and documents hosted locally: complete control over residency and access.
- Sharing by link with password, expiry and granular permissions.
- Replacement of several services (Drive, calendar, contacts, video calls) with a single platform.
- Server-side and at-rest encryption configurable according to your requirements.
- Predictable cost tied to the VPS rather than to the volume of data stored.
| Criterion | Nextcloud | ownCloud |
|---|---|---|
| App ecosystem | Very rich app store (Talk, Office, Flow…) | More limited, file-focused |
| Architecture | PHP monolith | PHP (historical) or Infinite Scale in Go (microservices) |
| Performance on large volumes | Good, can get heavy with many apps | Excellent with Infinite Scale (stateless) |
| Collaborative editing | Nextcloud Office / OnlyOffice integrated | Via OnlyOffice/Collabora integration |
| Video conferencing | Native Nextcloud Talk | Not native |
| Database | MariaDB/PostgreSQL recommended | MariaDB/PostgreSQL recommended |
| Recommended RAM | 2 to 4 GB | 2 GB (PHP), variable for Infinite Scale |
| Target profile | Complete collaborative suite | High-performance, streamlined storage |
Hardware and software prerequisites
A private cloud is heavy on disk I/O, which is the determining factor. For Nextcloud as for ownCloud (PHP), plan for a VPS of 2 vCPU and 4 GB of RAM, with an NVMe disk and at least 40 GB of space (to be sized according to your files). Never use SQLite in production: MariaDB or PostgreSQL are mandatory, and Redis is strongly recommended for file locking and caching. ownCloud Infinite Scale, being stateless and in Go, tolerates small CPU configurations better. You need Docker Compose v2, a dedicated domain (cloud.mydomain.com), an HTTPS reverse proxy, and particular attention to the upload limit (client_max_body_size, php_upload_max_filesize) for large files.
Deploy your private cloud on a VPS
Prepare the database and Redis
In the docker-compose, declare mariadb:11 (or postgres:16) with a persistent volume and dedicated credentials, plus a redis:alpine service. These containers support real load; SQLite will block you within a few users.
Configure the application container
Use the nextcloud:apache image (or owncloud/server) pointing MYSQL_HOST, REDIS_HOST and the credentials. Set NEXTCLOUD_TRUSTED_DOMAINS=cloud.mydomain.com, without which the instance will refuse external connections.
Mount the data volume
Mount a dedicated volume on /var/www/html/data (Nextcloud) to isolate user files from the rest of the container and ease backups and storage growth.
Launch and finalize the installation
Run docker compose up -d, wait for initialization, then complete the configuration via the web interface or in CLI with occ maintenance:install. Create the administrator account.
Reverse proxy, HTTPS and large files
Route cloud.mydomain.com via Caddy/Traefik with Let's Encrypt. Increase client_max_body_size to at least 10G on the proxy side and align php_upload_max_filesize to allow the upload of large files without a 413 error.
Enable cron and backups
Switch the background tasks to cron mode (rather than AJAX) for reliability, via a dedicated cron container. Then schedule a database dump + snapshot of the data volume to external storage.
On Nextcloud, the majority of the admin screen's warnings come from forgotten reverse proxy settings: remember to define overwriteprotocol => https, overwrite.cli.url and the trusted_proxies list in config.php, otherwise the share links generate broken http URLs. Also enable the APCu cache in addition to Redis to relieve the database on each page load. For ownCloud, if performance plateaus on large volumes, evaluate migrating to Infinite Scale, which eliminates the PHP bottleneck.