Self-hosting

Self-hosting with Docker Compose

Run the whole stack on your own machine or server under AGPL-3.0, free and without plan limits. One container for small setups, Compose for more control.

How to do it

  1. Get the code Clone the repository from https://github.com/socialhandoff/socialhandoff.
  2. Pick a path For a single machine, run docker compose --profile aio up --build aio. For separate services, use the default Compose file.
  3. Set an encryption key For Compose, set SOCIALHANDOFF_ENCRYPTION_KEY to 32 random bytes, for example with openssl rand -hex 32, and keep it in .env. The all-in-one image generates and stores one for you.
  4. Start and claim the server The first start prints a one-time setup URL in the log. Open it, create the workspace, and save the owner key.
  5. Connect networks Bluesky and Mastodon work straight away. For X and LinkedIn, create your own apps and set their client IDs and secrets.
  6. Put it behind TLS Ports bind to 127.0.0.1 by default. Put a TLS reverse proxy in front before you expose it.
  7. Back up Dump Postgres with pg_dump and keep the encryption key with the dump.

What runs

Compose starts Postgres 16, Redis 7, MinIO for media, the API on port 43110, the worker, and the web inbox on port 43111. The all-in-one image runs the same services in one container, with data under a single volume.

To try it without real accounts, DEMO=true docker compose up --build seeds a demo workspace with a mock network. Never put real tokens in a demo instance; its keys are public.

Without Docker

With Node 22+, pnpm, Postgres, and Redis installed, ./run.sh installs, migrates, and starts everything. ./run.sh --real skips the demo data and prints a setup URL.

Key settings

VariableWhy it matters
SOCIALHANDOFF_ENCRYPTION_KEYEncrypts tokens. Required outside demo mode
SOCIALHANDOFF_PUBLIC_URLPublic API origin, used for OAuth callbacks
SOCIALHANDOFF_WEB_URLBrowser origin for the inbox
SOCIALHANDOFF_DEMO0 for real use

Backups and upgrades

A database dump without the encryption key cannot decrypt tokens, so store them together. To upgrade: back up, pull the new version, keep the same key, and start the API; migrations apply on boot. Downgrades need a restore.

Kubernetes, Railway, Render

The repository has a starting Helm chart and Railway and Render configs. See open source and the self-hosting glossary entry.

Frequently asked questions

Is self-hosting really free?
Yes. The core is AGPL-3.0 with no plan limits on channels or agents. You pay only for your own infrastructure.
What happens if I lose the encryption key?
Stored network tokens and app passwords cannot be decrypted. You would need to reconnect every account. Keep the key in a password manager and with your backups.
Can I expose the server to the internet?
Yes, behind a TLS reverse proxy. Compose binds to 127.0.0.1 by default so nothing is exposed by accident.

Let your agents post. Keep the final say.

Connect your first agent in minutes. Every draft waits in your inbox until you approve it.

14 days free. No card required.

The hosted version is opening soon

Leave your email and we will send one message when hosted accounts open, with your 14-day trial ready. Want it today? Self-host it free from the repo.

Start free trial