Self-hosting Nextcloud on a VPS: what it costs and when it makes sense
TL;DR: Nextcloud gives you file sync, sharing, calendars and contacts on infrastructure you control. The pitch is usually framed as escaping subscription costs, and that framing is misleading, because the real comparison is a per-user subscription against a fixed server cost plus your own time.
For a five-person team the economics are marginal. For twenty-five people with substantial storage, self-hosting wins clearly. The mistake that ruins most installations is under-provisioning: Nextcloud on 2GB of RAM with SQLite and no Redis feels sluggish, and people conclude the software is slow when they have simply built it wrong. Budget 4GB, PostgreSQL and Redis from the start.
What Nextcloud actually is
Nextcloud is a self-hosted platform for file storage, sync and sharing, with an app ecosystem covering calendars, contacts, notes, video calls, collaborative document editing and task management.
The core proposition is that your files sit on your server, under your control, rather than on a provider's infrastructure under their terms.
What it does well: file sync across desktop and mobile with reliable clients, sharing with granular permissions and expiry, calendar and contact sync over open standards so any client works, and a genuinely useful app catalogue.
What it does adequately: collaborative document editing through integrations, which works but is not as polished as the hosted alternatives.
What it does not do: replace a full productivity suite on its own. Email is a separate concern, and document editing depends on a heavy additional component that many small installations skip.
Who it suits: teams with meaningful storage needs, organisations with a specific reason to keep data on their own infrastructure, businesses tired of per-user pricing that scales with headcount, and anyone who wants file sync without a subscription that increases annually.
Who it does not suit: a two-person team, where the subscription is cheap and the maintenance is not worth it. Anyone with no appetite for server administration. And organisations where document collaboration is the primary use case rather than storage and sync.
Being clear about which group you are in before installing saves a lot of subsequent regret.
The honest cost comparison
The economics depend almost entirely on team size and storage volume, and general claims about saving money are usually wrong at small scale.
Hosted services charge per user per month, typically with a storage allowance per seat. Cost scales linearly with headcount, and storage upgrades are additional.
Self-hosted Nextcloud costs the server, the storage, and your time. The server cost is fixed regardless of user count, which is the crucial difference: adding the twenty-first user costs nothing, whereas on a subscription it costs another seat.
Rough shape of the numbers for an Indian business:
A 4GB VPS suitable for a small team runs somewhere around ₹1,500 to ₹2,500 a month depending on storage. Adding object storage for bulk files is typically a few rupees per gigabyte per month.
Against that, a per-user subscription at five users is comparable or cheaper. At twenty-five users it is several times the self-hosted cost. At fifty, it is not close.
The cost people leave out is time. Initial setup is a day if you are comfortable with Linux. Ongoing maintenance is perhaps an hour a month: updates, monitoring, occasional troubleshooting. Major version upgrades take longer and occasionally go wrong.
If you value your time at any professional rate, that hour a month is a real cost, and at five users it can exceed the subscription you were avoiding.
The honest summary: below roughly ten users, self-host for control or curiosity, not for savings. Above twenty-five, the savings are substantial and grow. Between the two, it depends on whether the administration is a burden or something you would enjoy anyway.
Sizing: the mistake everyone makes
Most complaints that Nextcloud is slow trace to under-provisioning, and the guides recommending 1GB or 2GB are a large part of why.
1 vCPU, 2GB RAM. Enough to install and demonstrate. Not enough for a working team instance running PostgreSQL, Redis and a reverse proxy alongside Nextcloud itself. It will swap under any real use, and file operations will feel sluggish.
2 vCPU, 4GB RAM. The realistic starting point for a small team. Comfortable for Nextcloud with PostgreSQL, Redis and a proxy, handling a handful of concurrent users and normal sync activity.
4 vCPU, 8GB RAM. Needed for larger teams, heavy concurrent sync, or if you add collaborative document editing, which is a substantial memory consumer in its own right.
What drives the requirement:
Concurrent sync clients, since each syncing device generates sustained request activity rather than occasional page loads.
Preview generation, which is CPU and memory intensive. A bulk upload of photos triggers thumbnail generation across the whole set, and this is the single most common cause of a server that suddenly feels overwhelmed.
Collaborative editing components, which are heavy and often overlooked in sizing.
Full-text search indexing if enabled.
The practical recommendation: start at 2 vCPU and 4GB even if it feels generous. The cost difference against a 2GB instance is small, and the difference in perceived quality is large. A Nextcloud instance that feels fast gets used; one that feels slow gets abandoned, and then you have paid for the server anyway.
Storage architecture matters more than server size
The decision that determines whether this scales.
Block storage on the VPS. Files live on the server's own disk. Simple, fast, and limited: you are capped by the disk size, and growing means resizing the whole server.
Fine for teams with modest storage. Painful once you pass a few hundred gigabytes, because VPS plans price storage alongside CPU and RAM, so buying more storage means buying compute you do not need.
Object storage as primary. Nextcloud can use S3-compatible object storage as its primary store, with the server handling only metadata and application logic. Storage then scales independently and cheaply, and the server stays small.
This is the configuration that makes self-hosting economical at volume, and it is the one most tutorials skip.
Trade-offs: slightly higher latency on file operations, a dependency on the object storage provider's availability, and a more complex backup story since files and database live in different places.
External storage mounts. Nextcloud can also mount external sources as additional storage, which is useful for integrating existing data rather than as a primary architecture.
The decision rule: if your total storage will stay under roughly 200GB, block storage on the VPS is simpler and fine. Beyond that, object storage as primary is worth the added complexity, and it converts storage from a server-sizing problem into a line item that scales smoothly.
Decide this before you migrate data in, because changing primary storage afterwards is a migration rather than a setting.
The install, and the pieces people skip
Docker Compose is the practical approach, with several services rather than one.
Point DNS first. An A record for your chosen hostname, pointing at the VPS, before starting containers. The reverse proxy needs to resolve the name to obtain a certificate.
Prepare the server. Update packages, create a non-root sudo user, install Docker and the Compose plugin, configure the firewall for ports 22, 80 and 443 only, and harden SSH. The new VPS checklist covers this properly, and it matters more here than usual because this server will hold your organisation's files.
Define the services. Nextcloud itself, PostgreSQL with a named volume, Redis for caching and file locking, and a reverse proxy such as Caddy handling TLS automatically. Set restart: unless-stopped on all of them.
The pieces people skip, and should not:
Redis. Nextcloud without a memory cache is noticeably slow, and without Redis for transactional file locking you get intermittent locking errors that are maddening to diagnose. This is not optional for a real installation.
PostgreSQL rather than SQLite. SQLite works for a single user and degrades badly with concurrency, which is exactly what a sync client generates.
Trusted domains configuration. Nextcloud rejects requests for hostnames not in its trusted domains list, and the resulting error message confuses people for longer than it should.
PHP memory limits. Default values are frequently too low for large uploads and preview generation. Raise them in the container configuration rather than wondering why big files fail.
Background jobs via system cron. Nextcloud defaults to running background tasks on page load, which is unreliable and slow. Switch to system cron calling the job runner every five minutes. This is the single most impactful configuration change after Redis.
Reverse proxy headers. Nextcloud needs correct forwarded headers to generate URLs properly, and getting this wrong produces broken links and sync failures.
| Factor | Nextcloud self-hosted | Hosted drive service |
|---|---|---|
| Cost model | Fixed server cost | Per user per month |
| Cost at 5 users | Comparable or higher | Comparable or lower |
| Cost at 25 users | Substantially lower | Substantially higher |
| Storage cost | Cheap with object storage | Priced per seat tier |
| Data location | Your choice, including India | Provider's regions |
| Setup effort | A day | Minutes |
| Ongoing maintenance | About an hour a month | None |
| Document collaboration | Adequate, needs extra component | Strong |
| Mobile and desktop clients | Good | Excellent |
| Uptime responsibility | Yours | Theirs |
| Adding a user | Free | Another seat |
Nextcloud versus hosted alternatives
Where the honest advantages and disadvantages sit.
Nextcloud wins on: cost at scale, since adding users is free. Data location, which you choose, including keeping data in India. Storage economics with object storage. Extensibility through the app ecosystem. And freedom from a vendor changing terms or pricing.
Hosted services win on: zero maintenance. Superior collaborative document editing. More polished mobile clients. Better search. And uptime that is somebody else's problem at three in the morning.
The data location point deserves nuance. India's data protection framework does not mandate localisation, and cross-border transfer is permitted to jurisdictions not specifically restricted. So keeping files in India is not a legal requirement for most businesses.
Where self-hosting genuinely helps compliance is different: it reduces the number of third parties processing personal data on your behalf, which simplifies your processor register and your vendor agreements. Each hosted service you use is a Data Processor requiring an agreement, as covered in the DPA checklist. Consolidating several into infrastructure you control is a real simplification.
It also transfers responsibility rather than removing it. A breach of your self-hosted Nextcloud is entirely yours, with no vendor security team involved, and the same 72-hour reporting obligations apply.
The realistic position: self-host for cost at scale and for control, not because it is inherently more secure. A well-run hosted service is more secure than a neglected self-hosted one.
Performance tuning that actually matters
Beyond correct sizing, a handful of settings account for most of the difference between an instance that feels fast and one that does not.
Redis for both caching and file locking. Configure local memory cache and distributed cache, and specifically enable Redis for transactional file locking. Without the last one, concurrent operations produce locking errors.
Background jobs on system cron, every five minutes. Page-load-triggered jobs mean maintenance tasks run unpredictably and slowly.
Preview generation strategy. Limit which file types generate previews and cap preview dimensions. Bulk photo uploads triggering full preview generation across thousands of files is the most common cause of a server appearing to die. Consider pre-generating previews on a schedule rather than on demand.
Database indexes and maintenance. Nextcloud ships commands to add missing indexes and convert column types, which the admin interface flags as warnings. Run them; the warnings exist because the missing indexes genuinely hurt.
PHP OPcache properly configured, with sufficient memory allocated. This is a substantial and easily missed improvement.
HTTP/2 or HTTP/3 at the proxy, which helps sync clients making many parallel requests.
Chunked upload size tuned to your network, since defaults may not suit variable connections.
Disable apps you do not use. Nextcloud ships with many enabled by default, and each adds load.
Check the admin overview page. Nextcloud actively tells you what is misconfigured, listing missing indexes, absent caching, incorrect headers and cron problems. A large share of "Nextcloud is slow" cases are resolved by working through that list, which the administrator has never opened.
Backups, and why file copies are not enough
Nextcloud holds your organisation's files. Treat the backup requirement seriously.
Three components, all required for a working restore:
The database, holding all metadata: file listings, shares, permissions, user accounts, app configuration. Without it, your files are an unstructured directory with no sharing, no permissions and no user mapping.
The data directory, containing the actual files, unless you use object storage as primary, in which case files live there and need their own protection.
The configuration directory, holding your instance configuration.
A file-level backup alone is insufficient, because the database is what makes the files meaningful. This is the most common Nextcloud backup mistake: someone backs up the data directory, loses the server, and discovers they have a pile of files with no structure.
Consistency matters. Backing up the database and the files at different moments can produce a mismatch where the database references files that were not yet written. Put Nextcloud into maintenance mode during the backup, or use a snapshot approach that captures both together.
Object storage needs its own strategy. If files live in object storage, enable versioning and lifecycle rules there, and ensure the credentials your server holds cannot delete the entire bucket. A compromised server with full delete permissions on your object storage is the same failure as no backup at all.
Offsite, at a different provider, following the 3-2-1 pattern. A backup on the same VPS protects against nothing that actually kills the server.
Test a restore. Restore database, config and a sample of files into a throwaway instance and confirm the file tree, shares and users appear correctly. Quarterly is enough, and it is the only way to know your backup is real.
The ongoing maintenance you are signing up for
The part that determines whether this is a good decision in year two.
Minor updates, applied reasonably promptly. Nextcloud releases regularly and updates are usually smooth.
Major version upgrades, roughly annually, which are the ones that occasionally go wrong. Nextcloud requires stepping through major versions in sequence rather than jumping, so falling several versions behind creates a longer and riskier upgrade path. Back up before every major upgrade without exception.
App compatibility. Third-party apps sometimes lag behind core releases, and an app you depend on can block an upgrade.
Certificate renewal, automatic with a proper reverse proxy, but verify it is actually succeeding.
Storage monitoring. Disk filling is a classic Nextcloud failure, and it is entirely predictable. Alert at 80%.
Log review and update checking, perhaps twenty minutes a month.
The realistic annual commitment: a day for initial setup, an hour a month ongoing, and half a day for the annual major upgrade. If that sounds acceptable, self-hosting is a reasonable decision. If it sounds like a burden you will neglect, an unpatched Nextcloud holding your company's files is worse than a subscription you resent.
FAQs
Is self-hosting Nextcloud cheaper than Google Drive?
It depends on team size. Below roughly ten users, a per-seat subscription is comparable or cheaper once you account for your own time. Above twenty-five users the savings are substantial and grow, because self-hosting costs a fixed server price regardless of headcount while subscriptions scale linearly.
What server specs does Nextcloud need?
2 vCPU and 4GB of RAM is the realistic starting point for a small team running Nextcloud with PostgreSQL, Redis and a reverse proxy. 1GB and 2GB instances, which many guides suggest, will install and demonstrate but feel sluggish under real sync activity. Move to 4 vCPU and 8GB for larger teams or if you add collaborative document editing.
Why is my Nextcloud so slow?
Most often under-provisioning, no Redis configured, background jobs running on page load rather than system cron, or missing database indexes. Open the admin overview page, which actively lists what is misconfigured. A large share of slow instances are resolved entirely by working through the warnings already displayed there.
Do I need Redis with Nextcloud?
Effectively yes for any real installation. Without a memory cache, Nextcloud is noticeably slow, and without Redis handling transactional file locking you get intermittent locking errors that are difficult to diagnose. Treat it as a required component rather than an optimisation.
Should I use SQLite or PostgreSQL for Nextcloud?
PostgreSQL. SQLite works for a single user and degrades badly under concurrency, which is exactly what sync clients generate since each connected device produces sustained request activity. Choose PostgreSQL before migrating data in, because switching later is a migration rather than a configuration change.
Can Nextcloud use S3 object storage?
Yes, as primary storage, with the server handling only metadata and application logic. This is the configuration that makes self-hosting economical at volume, since storage then scales independently of the server. The trade-offs are slightly higher operation latency and a more complex backup story with files and database in separate places.
What do I need to back up in Nextcloud?
The database, the data directory, and the configuration directory. A file-level backup alone is insufficient, because the database holds all metadata including shares, permissions and user mapping, without which your files are an unstructured directory. Capture both consistently, ideally with the instance in maintenance mode.
Is self-hosted Nextcloud more secure than a hosted service?
Not inherently. It gives you control and removes a third-party processor, but it transfers full responsibility for patching, hardening, monitoring and incident response to you. A well-maintained hosted service is more secure than a neglected self-hosted instance, so the honest answer depends on whether you will actually do the maintenance.
Does self-hosting help with Indian data protection compliance?
Somewhat, though not for the reason usually given. India's framework does not mandate data localisation, so keeping files in India is not a legal requirement. Where self-hosting genuinely helps is by reducing the number of external processors handling personal data on your behalf, simplifying your vendor register and processor agreements.
How much maintenance does Nextcloud need?
Roughly a day for initial setup, about an hour a month for updates, log review and monitoring, and half a day annually for the major version upgrade. Major upgrades must be applied in sequence rather than skipped, so falling several versions behind creates a longer and riskier path.
Can Nextcloud replace Google Workspace entirely?
Not on its own. It covers file storage, sync, sharing, calendars and contacts well. Email is a separate concern requiring its own solution, and collaborative document editing needs a heavy additional component that is adequate rather than equivalent to hosted alternatives. Treat it as a drive replacement rather than a full suite replacement.
Why does my Nextcloud server slow down after a bulk upload?
Preview generation. Uploading a large set of photos triggers thumbnail creation across the whole batch, which is CPU and memory intensive and is the most common cause of a Nextcloud server appearing overwhelmed. Limit which file types generate previews, cap preview dimensions, or pre-generate on a schedule instead of on demand.
Conclusion
Nextcloud is a good piece of software that a lot of people install badly and then blame.
The two decisions that determine whether you end up happy are made before you upload a single file. Size the server properly, meaning 4GB rather than the 2GB most guides suggest, with PostgreSQL and Redis from the start. And choose your storage architecture deliberately, because block storage on the VPS is simpler under 200GB and object storage is what makes this economical above it.
Get those wrong and you have a slow instance that your team quietly stops using, while you continue paying for the server.
On the economics, be honest with yourself about scale. Below ten users this is a control and curiosity decision, not a savings one, once you price your own hour a month. Above twenty-five it is a clear financial win that grows with every person you add.
The backup point is the one that catches people hardest. Backing up the files is not backing up Nextcloud, because the database holds every share, permission and user mapping that makes those files usable. Capture both, consistently, offsite, and restore one into a test instance before you need to.
And open the admin overview page. Nextcloud tells you exactly what is misconfigured, and most instances have never had that list read.
HostCloud runs Linux VPS plans from ₹999 a month on NVMe with full root access, Indian data centres for low-latency sync, snapshot backups from the panel and scalable storage. Details at https://hostcloud.in.
