Requirements

This page lists the hardware and software requirements for self-hosted AFFiNE instances. Actual capacity depends on workspace size, number of collaborators, document size, upload volume, sync activity, and optional services such as monitoring or AI.

Quick planning guide

AreaBaseline guidanceWhy it matters
StorageReserve space for the server itself, Postgres data, uploaded blobs, and configuration. The server installation requires about 1.5 GB of spare space before user data growth.Disk pressure can affect database health, uploads, backups, and restore operations.
CPUUse a host with at least 4 CPU cores.CPU capacity affects response speed and long-running jobs.
MemoryUse at least 2 GB RAM for basic usage. Use 4 GB or more if you expect large documents or heavy collaboration.Sync and document merging can increase memory usage.
PostgresAFFiNE uses Postgres as its primary database.Postgres stores AFFiNE application data and should be treated as the primary backup target.
RedisRedis 6.x or 7.x is required.Redis is used for cache, background tasks, and sync infrastructure.
MonitoringPrometheus and related exporters may be enabled by default.Monitoring helps you detect capacity and reliability issues early.

Hardware

Storage

The necessary storage space depends on the size of your workspaces, number of collaborators, uploaded blobs, and total number of docs.

The server itself requires about 1.5 GB of spare space for installation. The performance of your host file system also affects AFFiNE performance.

Based on space usage monitored at affine.pro:

  • Postgres storage grows by about 100 MB per 1,000 docs, assuming an average of 1,000 words per doc.
  • Blob storage grows by about 10 GB per 1,000 uploaded blobs.

CPU

We recommend at least 4 CPU cores so AFFiNE can handle long CPU-bound jobs. AFFiNE response speed depends on your host CPU specification.

Memory (RAM)

Memory is mostly consumed by the sync system and document merging. The larger the largest document is, and the more modifications it has, the more memory may be required to merge it.

Based on memory consumption monitored at affine.pro:

  • Merging a document with 10,000 modifications can peak at about 1 GB memory usage.

Recommended host memory:

  • Use at least 2 GB RAM for basic usage.
  • Use 4 GB RAM or more if you expect documents with more than 10,000 words or heavy collaboration.

Software components

The following components are either included by some installation methods or configured by more advanced operators.

PostgreSQL

Postgres is the database where AFFiNE stores application data. It is the only database AFFiNE supports. See Postgres for more details.

AFFiNE versionTested Postgres version
0.21.xpostgres:16
0.21.x with AIpgvector/pgvector:pg16
INFO

If you use a self-maintained Postgres instance and want full AI capabilities, install the pgvector extension manually.

Redis

Redis is used for cache, background tasks, and the sync system.

AFFiNE cannot run without a Redis server. See Redis for more details.

Redis 6.x or 7.x is required and fully tested.

Prometheus

By default, Prometheus and related exporters are enabled to monitor AFFiNE instances. These processes consume about 200 MB of memory.

For more information, see Monitoring.