All guides
Self-hosting

Your own sync server

Keep your notes on a computer you own: a PC, a NAS, a Raspberry Pi or a VPS. Your devices sync through it, live and end-to-end encrypted.

  • Published
  • 6 min read

What you get

FastMemo Server is the self-hosted alternative to Google Firebase for Cloud Sync. One Docker container, one database file.

  • Private

    Notes are encrypted on your devices before they leave them. The server stores them, it can't read them.

  • Live

    An edit shows up on your other devices in about a second, even in a note that's open.

  • Offline-proof

    A device that can't reach the server keeps its changes and sends them as soon as it can.

  • With a dashboard

    Devices, space, reads, writes and deletes per day, warnings, and one-click backups.

What you need

  • A computer that stays on: a PC, a NAS, a VPS, or a Raspberry Pi 3, 4 or 5 with the 64-bit system.
  • Docker, which runs the server in a box of its own.
  • About 15 minutes. No programming: you copy a few commands.

Start the server

On the computer that will host it, open a terminal (on Windows: PowerShell) and follow these steps.

  1. Install Docker

    Install Docker Desktop (opens in a new tab) on Windows or macOS, or Docker Engine on Linux and Raspberry Pi.

  2. Download the server

    git clone https://github.com/ontech7/fastmemo-server.git
    cd fastmemo-server
    cp .env.example .env

    This copies the server into the fastmemo-server folder and creates its settings file, .env.

  3. Choose the access key

    It's the password your devices connect with, at least 16 characters. Make a random one on macOS or Linux:

    openssl rand -hex 24

    On Windows, or on any computer with Docker:

    docker run --rm node:24-alpine node -e "console.log(require('crypto').randomBytes(24).toString('hex'))"

    Open the .env file and paste it after FASTMEMO_ACCESS_KEY=. Keep it in a password manager: the server never shows it, and doesn't start without it.

    Want a different key for the dashboard? Make another one the same way and put it in FASTMEMO_ADMIN_KEY. Left empty, the access key opens the dashboard.

  4. Start it

    docker compose up -d
    docker compose logs fastmemo

    The server now runs on port 8787 and starts again by itself after a reboot. The second command shows its log: if something's wrong, you'll find it there.

  5. Open the dashboard

    On that computer, open http://localhost:8787 in a browser and sign in with the key. You'll see your devices, the operations per day and the backups.

Reach it from your phone

The web app only connects to https:// addresses. Android and the desktop apps accept http:// too.

An http:// address is fine through Tailscale or a VPN like WireGuard, which encrypt the traffic. Pick the way that suits you:

OptionGood forWhat you need
Tailscale (easiest)Your devices only, nothing exposed to the internetA free Tailscale account
CoolifyYou already run CoolifyCoolify and a domain
Caddy (VPS and domain)A VPS, or a home server with ports 80 and 443 openA domain pointing to the server
Plain http://Trying it out: on the computer it runs on, or from Android, macOS and Linux on your Wi-FiNothing (not for the web app; the app asks to confirm)

Tailscale (easiest)

It puts the server in a private, encrypted network that your devices reach from anywhere: no domain, nothing open to the internet.

  1. Install Tailscale (opens in a new tab) on the server and on each device, and sign in with the same account.

  2. On the server, run:

    sudo tailscale serve --bg 8787

    It prints your server's address, like https://raspberrypi.your-tailnet.ts.net. If it asks to enable HTTPS certificates, open the link it shows: it's one click.

  3. In the .env file, set TRUST_PROXY=true and PORT=127.0.0.1:8787, then start the server again:

    docker compose up -d

    The server is now reached through Tailscale only: nobody on your network can connect to it directly.

Rather have no certificate? An HTTPS address puts its name in public certificate logs: the server stays private, but the name can be seen. In step 2, run this instead:

sudo tailscale serve --bg --tcp=8787 tcp://127.0.0.1:8787

The address becomes http://raspberrypi.your-tailnet.ts.net:8787. Tailscale encrypts it all the same: fine for Android and the desktop apps, not for the web app.

Coolify

  1. Create a resource from the fastmemo-server repository with the Docker Compose build pack.
  2. As the compose file, enter /docker-compose.coolify.yml.
  3. Give the service your domain followed by :8787, for example https://notes.example.com:8787.
  4. Deploy: Coolify takes care of HTTPS and generates the keys (in Environment Variables).

Caddy (VPS and domain)

You need a domain that points to the server, and ports 80 and 443 open.

Put the domain in the .env file, like DOMAIN=notes.example.com, and start the server together with Caddy, which gets the HTTPS certificate by itself:

docker compose -f docker-compose.caddy.yml up -d

Your address is https://notes.example.com.

Connect FastMemo

On each device:

  1. Open Settings → Cloud Sync and turn on Enable Cloud sync.

  2. Under Sync with, choose FastMemo Server.

  3. Enter the Server address (https://… or http://…) and the Access key, then tap Save settings.

  4. On the first device, choose an Encryption password and write down the Recovery key it shows. The other devices ask for the same password.

Backups and updates

  • Back up from the dashboard: one file with everything. The notes in it stay encrypted, but it also holds the titles and the access key: keep it private.
  • Lost a phone? Remove it from the dashboard (or from Manage devices in the app): its access stops at once. To be safe, change the access key too: that phone still knows it.
  • To update the server, run these two commands in its folder:
Update the server
git pull
docker compose up -d --build

Good to know

  • The server never sees what's in your notes, nor your encryption password. The titles aren't encrypted: the app uses them for sorting.
  • An http:// address isn't encrypted. Through Tailscale or a VPN that's fine; on other networks use HTTPS, because a device on HTTP sends your note titles and its credentials in the clear.
  • A Raspberry Pi is more than enough, even for the whole family. By default it takes up to 10 devices (MAX_DEVICES in the .env file).
  • Every detail (all the settings, restoring a backup, PostgreSQL, troubleshooting) is in the README on GitHub (opens in a new tab).