Seafile is an open-source file sync and share platform focused on doing that one job very well: fast, reliable syncing of large libraries, with versioning, sharing links and optional client-side encryption. Compared with Nextcloud, it does fewer things, but syncs large numbers of files noticeably faster and with lower server load. It runs nicely on a VPS with Docker.

Seafile vs Nextcloud in one table

Seafile Nextcloud
Focus File sync and share Full collaboration suite (files, calendar, contacts, office, apps)
Sync performance Very fast, efficient delta sync Good, but heavier with many files
Storage format Blocks in its own object store (not plain files on disk) Plain files on disk
Client-side encryption Encrypted libraries End-to-end encryption app
Resource use Light Heavier (PHP stack)

Pick Seafile for fast file sync, and Nextcloud if you want the whole suite. See install Nextcloud.

Requirements

  • A VPS with 2 vCPU and 2–4 GB RAM is enough for a small team.
  • Enough disk for your files, plus versions and history.
  • Docker and Docker Compose. See install Docker.
  • A domain, e.g. files.example.com, pointing to the server.

1. Docker Compose setup

Seafile publishes official Compose files for each version. Download the current ones from the Seafile manual (Community Edition), or start from this outline:

# /opt/seafile/compose.yaml (outline – use the official file for your version)
services:
  db:
    image: mariadb:10.11
    environment:
      - MYSQL_ROOT_PASSWORD=change-me-db-root
      - MYSQL_LOG_CONSOLE=true
    volumes:
      - ./mysql:/var/lib/mysql
    restart: unless-stopped

  memcached:
    image: memcached:1.6
    entrypoint: memcached -m 256
    restart: unless-stopped

  seafile:
    image: seafileltd/seafile-mc:12.0-latest
    ports:
      - "127.0.0.1:8000:80"
    volumes:
      - ./seafile-data:/shared
    environment:
      - DB_HOST=db
      - DB_ROOT_PASSWD=change-me-db-root
      - TIME_ZONE=Etc/UTC
      - [email protected]
      - SEAFILE_ADMIN_PASSWORD=change-me-admin
      - SEAFILE_SERVER_HOSTNAME=files.example.com
      - SEAFILE_SERVER_PROTOCOL=https
    depends_on:
      - db
      - memcached
    restart: unless-stopped

Recent versions (12+) use an .env file and slightly different variable names. Follow the manual for your exact version. Then:

cd /opt/seafile
docker compose up -d
docker compose logs -f seafile

Use strong, unique passwords, and store them in a password manager.

2. HTTPS with a reverse proxy

Expose Seafile through Nginx (or Caddy) with Let’s Encrypt:

server {
    server_name files.example.com;
    client_max_body_size 0;              # allow large uploads
    proxy_read_timeout 1200s;
    location / {
        proxy_pass http://127.0.0.1:8000;
        proxy_set_header Host $host;
        proxy_set_header X-Real-IP $remote_addr;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_set_header X-Forwarded-Proto $scheme;
    }
    # listen 443 ssl; certificates via certbot --nginx
}

Make sure SERVICE_URL / FILE_SERVER_ROOT in Seafile’s settings use https://files.example.com, or uploads and downloads fail. See Nginx reverse proxy and Let’s Encrypt.

3. Users, libraries and clients

  • Log in as the admin, and create users or enable LDAP/OIDC.
  • Users create libraries (top-level folders that sync independently).
  • Install the Seafile desktop client (Windows, macOS, Linux) and the mobile apps. There’s also SeaDrive, a virtual drive that shows files without downloading them all.
  • Share via links (with passwords and expiry) or with users and groups.

Encrypted libraries: the password is required to decrypt, and files are encrypted on the client. The server operator can’t read them. Don’t lose the password, because there’s no recovery.

4. Storage planning

Seafile stores data as deduplicated blocks, so you can’t browse files directly on disk. That’s normal. Plan storage for files plus version history (configure history retention per library). A storage VPS (500 GB SSD in the USA or Hong Kong on VPS.DO) suits larger libraries, and object storage backends are supported in some editions. See storage VPS.

5. Backups

Back up both the databases and the seafile-data directory, in that order, so they stay consistent:

docker compose exec -T db mysqldump -uroot -p"$DB_ROOT" --all-databases > /backups/seafile-db-$(date +%F).sql
rsync -a /opt/seafile/seafile-data/ /backups/seafile-data/

Copy them off-server. Seafile’s documentation describes restore steps, so test them. See backup strategy.

Maintenance

  • Garbage collection removes blocks no longer referenced (after deleting files or old history). Run it periodically per the manual (seaf-gc.sh).
  • Updates: follow the upgrade notes between major versions, and back up first. See updating self-hosted apps.
  • Security: 2FA for users, strong admin passwords, and keep the server patched.

Quick reference

Task Command / place
Start docker compose up -d
Logs docker compose logs -f seafile
Reverse proxy Nginx → 127.0.0.1:8000, client_max_body_size 0
Clients Seafile desktop, SeaDrive, mobile apps
Backup DB dump + seafile-data
Free space Garbage collection (seaf-gc.sh)

Related: Syncthing and ownCloud Infinite Scale.

  • Self-Hosting
  • File Sync
  • Docker