7 min readVPS
Nextcloud is the closest thing there is to running your own Google Drive, Google Photos and Office on hardware you control. Files sync from your laptop and your phone, photos back themselves up as you take them, and documents open and edit in the browser. None of it is anybody else's business model.
The reason people give up on it is almost never the installation. They put it on whatever was cheapest, imported ten years of photos, and watched it crawl. Idle, Nextcloud is a light application. For the first few days it is not light at all, and those are the days you form your opinion of it.
This guide covers picking a server that can cope, installing Nextcloud with the official all-in-one image, and the things that catch people afterwards.
Why CPU matters more than you would expect
A file store should be I/O bound, and Nextcloud mostly is, until you give it a photo library.
Then it has to generate previews: every image thumbnailed at several sizes, and HEIC and RAW decoded before anything can resize them. A first import of a large library will sit on every core you own for hours. Full-text search indexing does the same if you enable it, and so does virus scanning. So does document conversion, every time somebody opens a spreadsheet in the browser.
Shared vCPU hosting is worst at exactly this workload. Burst credits assume short spikes, and a photo import is a sustained hour-long pull on every core, which is precisely when the allowance runs out and the machine drops to a fraction of its advertised speed. You end up watching a progress bar, wondering what it was you bought.
Our KVM VPS plans allocate cores to your server on AMD EPYC 9645 hardware, so a long import runs at the same speed in hour three as it did in minute one. That is the whole argument for dedicated cores here, and it only matters because of what Nextcloud does to a machine.
Memory is the less obvious constraint. The all-in-one install is not one process but several containers: Nextcloud, PostgreSQL, Redis, the web server, and then whatever else you switch on, with Office, preview handling and full-text search each adding another. Four gigabytes will boot. It will not stay pleasant.
Rough sizing
For a household, with a photo library in the low hundreds of gigabytes, KVM VPS 8 is the sensible starting point: 4 dedicated cores, 8 GB of DDR5 ECC and 256 GB of NVMe. Previews keep up and there is room for Office.
For an office of ten to twenty-five people, several of them editing documents at once, KVM VPS 16 doubles the cores and the memory and gives you 512 GB.
Past that you are buying storage, not compute. Work out what you have today, double it, and buy that. Moving a large Nextcloud data directory later is a dull afternoon.
Whichever size you pick, order it with no control panel. cPanel and Plesk both want to own the web server and the certificates, and that is an argument you do not need to have. Ubuntu is the least trouble for this particular install.
Before you start
Two things have to be true before you run anything.
First, point a domain at the server. An A record for something like cloud.yourdomain.com
to its IPv4 address, and an AAAA record to its IPv6 address. Nextcloud needs a real hostname
because it needs a real TLS certificate, and the installer obtains one for you. Let the record
propagate before you carry on.
Second, open the ports the installer needs reachable from outside:
80/tcp certificate validation
443/tcp Nextcloud itself
443/udp optional, HTTP/3
8443/tcp the all-in-one admin interface
Add 3478 on both TCP and UDP if you want Nextcloud Talk for calls.
One trap here catches almost everyone. Docker writes its own firewall rules and they are
evaluated before UFW's, so a published container port answers the internet quite happily while
ufw status reports it closed. Check from another machine what is really listening. If you
want filtering you can trust, put it at the provider's edge and not inside the box.
Installing Nextcloud
Install Docker from the official repository. Ubuntu ships an older build under a different name, and it will confuse you later:
curl -fsSL https://get.docker.com | sh
Then start the all-in-one master container. This command is the install:
sudo docker run \
--init \
--sig-proxy=false \
--name nextcloud-aio-mastercontainer \
--restart always \
--publish 80:80 \
--publish 8080:8080 \
--publish 8443:8443 \
--volume nextcloud_aio_mastercontainer:/mnt/docker-aio-config \
--volume /var/run/docker.sock:/var/run/docker.sock:ro \
ghcr.io/nextcloud-releases/all-in-one:latest
The container you just started does not run Nextcloud. It runs the thing that builds and manages the containers that do, which is why it wants the Docker socket, and why upgrades later are a button.
Now open https://cloud.yourdomain.com:8443, which hands you a long initial password. It is
the only copy, so put it in your password manager before you touch anything else. Enter your
domain, let it check that the name really does point here, and start the containers. The first
run pulls several images and builds the database, so give it a few minutes.
At the end it gives you a second password, the admin login for Nextcloud itself at
https://cloud.yourdomain.com. Different password. Save that one too.
What to switch on, and what to leave alone
The interface offers a list of optional containers, most of which you can ignore. Three are worth the memory.
Imaginary handles previews for the formats the default image library struggles with, HEIC and HEIF among them, which is what your phone has been shooting for years. Turn it on before you import photos, not after.
Nextcloud Office gives you real document editing in the browser. In practice it is the feature that decides whether colleagues use the thing or quietly go back to emailing attachments.
Daily backups live in the same interface. Switch them on today, while there is still nothing in there you would miss, and point them at storage that is not this server. A backup on the same NVMe as the data survives your mistakes but not the machine's.
Leave full-text search alone until you know you want it. It is useful across a large document archive, it is expensive in memory, and adding it in six months costs you nothing.
The parts people get wrong
Snapshots and backups are not the same thing. A provider snapshot gets you out of a broken upgrade. It does nothing about noticing in March that you deleted something in January. Keep the daily backup as well, somewhere else.
Storage grows faster than you expect. Deleted files sit in the trash, old versions of edited files are kept, and on a photo library the previews are themselves a serious pile of data. All three are configurable, and the moment to configure them is while the disk is at forty percent rather than ninety.
Mail has to work. Password resets, share notifications and the failed-backup warning all leave by SMTP. Set it up with real credentials early, then test it, because the first time you need a password reset is a bad moment to discover it was never wired up.
The load is in sync, not in the web interface. Ten people clicking around a browser is nothing. Ten desktop clients that have just been pointed at a large shared folder will pull on CPU, disk and network for as long as it takes. Do the first big import deliberately, overnight if you can, and not on the Monday morning you are showing it to everybody.
And keep it patched. This is a server with your documents on it, answering the public internet. The interface makes Nextcloud updates a button, but the Ubuntu underneath is still yours, and so is Docker.
What it costs to run
The install is an afternoon. Running it is the part that continues: patches, watching the disk, checking the backups really completed, and being the person who fixes it when a client stops syncing during your vacation.
For plenty of people that is a fair trade for owning their own data, and self-managed is the right answer. You get root the moment it boots and we stay out of your way.
If you would rather not be that person, our fully managed VPS puts our engineers on the provisioning, the security baseline and the patching. It is the same hardware either way, and fully managed adds $30 a month to whichever size you pick. It is not the right choice for everybody. If you like running servers, it is a waste of your money.
Not sure which one you are? Ask us. We will tell you, including when the answer is that you should just run it yourself.