Configuration
Environment Variables
See Environment Variables for the full list.
Database
SendDock uses PostgreSQL 17+. The development compose (docker-compose.yml, used by make dev) exposes Postgres on host port 5434 so you can connect from make dev running on the host without colliding with a local Postgres. Production composes (docker-compose.image.yml, docker-compose.prod.yml) keep Postgres on the internal Docker network only — no host port is exposed, and the container talks to it on the standard 5432.
Defaults bundled by the production compose:
- User:
senddock - Database:
senddock - Password:
$POSTGRES_PASSWORDfrom your.env - Internal port:
5432
Using an external database
Set DATABASE_URL to your PostgreSQL connection string and drop the bundled postgres service from the compose file:
DATABASE_URL=postgres://user:password@host:5432/dbname?sslmode=requireMigrations run automatically on container start (the entrypoint calls goose up against DATABASE_URL). For source-from-scratch runs without Docker:
make migrateManaged Postgres (Neon, Supabase, RDS, Aiven) needs pg_trgm
The email-logs search uses GIN indexes on pg_trgm. The migration 20260528193111_add_email_logs_search_index.sql runs CREATE EXTENSION IF NOT EXISTS pg_trgm for you — this works out of the box on the bundled Postgres image, but some managed Postgres providers require the extension to be on an allowlist before CREATE EXTENSION succeeds:
- Neon, Supabase, Aiven —
pg_trgmis available by default, no action needed. - AWS RDS — add
pg_trgmto theshared_preload_librariesparameter group, or enable viards_superuser. - Google Cloud SQL — enable from the Database flags UI.
If migration fails with permission denied to create extension "pg_trgm", your DB user lacks privileges. Either run CREATE EXTENSION pg_trgm; once as superuser, or grant CREATE on the schema to the SendDock user.
Redis
Redis powers three things:
- Global per-IP rate limiter.
600requests per rolling 60s window by default (every HTTP endpoint except/health). Tune withRATE_LIMIT_PER_MINUTE. - Per-project rate limits on the sending endpoints —
/send(60 req/min),/send/batch(10 req/min),/broadcast(5 req/hour). These are hard-coded. - Cache for the GitHub releases response that drives the "update available" badge in the dashboard.
The development compose exposes Redis on host port 6380. The production composes keep it on the internal Docker network only — the binary talks to it on the standard 6379.
Redis is effectively required in production
The binary boots without Redis — REDIS_URL is technically optional — but every limiter silently turns into a no-op, including the global per-IP cap and the per-project sending caps. For any instance exposed to the internet, that means open abuse vectors: bot traffic, credential stuffing on /auth/login, broadcast spam.
The bundled production composes already ship Redis. Only unset REDIS_URL for ephemeral test environments where you've accepted there is no rate limit.
Security Checklist
Before exposing to the internet:
- [ ] Generate
JWT_SECRETfromopenssl rand -hex 32(orbase64 48) — used for JWT signing and the HMAC on click-tracking URLs. Min 32 chars. - [ ] Set
POSTGRES_PASSWORDto the output ofopenssl rand -base64 32— the production composes refuse to start without it, so there is no default to forget - [ ] Set your public HTTPS domain under Instance in the dashboard (drives unsubscribe + tracking links inside outgoing emails, and the CORS origin)
- [ ] Put SendDock behind HTTPS —
Secure: trueis set on auth cookies when the resolved URL starts withhttps:// - [ ] Keep Redis enabled (it ships in the production composes); without it every rate limit is a no-op
- [ ] Enable two-factor authentication on every account from Settings → Account — see Your account & security
- [ ] On Team workspaces, give each human a least-privilege role (
viewer/developer/admin) instead ofowner - [ ] Set up Postgres backups before going live — see Backups & Recovery
- [ ] Keep SendDock updated — the dashboard surfaces a yellow badge when a new release is available
If anything misbehaves after going live, see Troubleshooting.
Plans and licensing
SendDock is open-core: the AGPL-3.0 Community edition does everything most one-person operations need, and two paid tiers (Pro and Team) add deliverability, reporting and team collaboration. Throughout these docs Core means the free feature set — everything in the Community tier, available with no key. The dashboard labels the three tiers Free, Pro and Team (the "Free" plan is the Community edition); the table below writes it as "Community (Free)". Paid tiers are unlocked with a license key validated against Lemon Squeezy.
On a self-hosted instance you activate that key from the dashboard, under Instance → License — it's stored encrypted in the database and applies immediately, no restart. See Instance settings → Pro license. The legacy SENDDOCK_LICENSE_KEY environment variable still works but is deprecated: if set, it's imported into the database once on boot and support for it is removed in v0.9. On the cloud deployment the environment owns the key.
Self-hosted prices below are flat per instance
The $9 and $29 prices on this page are the self-hosted rates — one license per SendDock instance, unlimited subscribers, unlimited sends. The managed cloud at senddock.dev is live and priced separately on a per-subscriber tier basis (Free up to 2,000, then $19 / $49 / $129 per month) because we operate the platform for you. BYO SMTP applies to both — neither path charges per send.
What each tier unlocks
| Capability | Community (Free) | Pro ($9 / mo, $90 / yr) | Team ($29 / mo, $290 / yr) |
|---|---|---|---|
| Single user, multiple workspaces | ✓ | ✓ | ✓ |
| Subscribers, templates, broadcasts | ✓ | ✓ | ✓ |
| BYO SMTP, unlimited sends | ✓ | ✓ | ✓ |
| Bounce ingestion, suppression list | ✓ | ✓ | ✓ |
| Click & open tracking | ✓ | ✓ | ✓ |
| API keys + webhook dispatcher | ✓ | ✓ | ✓ |
| Analytics dashboard (Overview, Campaigns, Audience, Engagement) | ✓ | ✓ | ✓ |
| Webhooks management UI | — | ✓ | ✓ |
| Deliverability — domain health + per-provider rates + spam rate | — | ✓ | ✓ |
| Report builder — pivots, segment filters, saved reports, CSV | — | ✓ | ✓ |
| Audit log | — | ✓ | ✓ |
| Multi-user workspaces (members + invites) | — | — | ✓ |
| Roles: owner / admin / developer / viewer | — | — | ✓ |
| Admin user creation (no public registration needed) | — | — | ✓ |
| A/B testing, segments & tags, approval workflow | — | — | roadmap |
A future Enterprise tier will add SSO/SCIM, per-project ACLs, white-label tracking domain, per-seat billing and SLA support — pricing on request, starting around $149 / mo.
| License state | What unlocks |
|---|---|
| none | Community — Pro features locked, Team features locked. |
| valid Pro key | Pro features unlocked (Deliverability, Reports, Audit log). Team features stay locked. |
| valid Team key | Pro and Team features unlocked. |
| invalid / revoked | Locked after the next validation tick (24h grace from the last successful check). |
The validator distinguishes Pro from Team by the Lemon Squeezy variant_id of the license — the product/pricing variant the key was purchased against (for example pro_monthly vs team_monthly). There is no separate Team key file or env var: buying Team gives you a single key the validator recognizes as Team-tier; buying Pro gives a key that validates only the Pro features.
The CLOUD flag (which replaced the old DEPLOYMENT_MODE string — see Environment Variables) does not change Pro gating — the license requirement applies the same way to self-hosted and cloud. What it does control is who owns configuration and registration: CLOUD=true opens the public sign-up endpoints used by the senddock.dev managed product and lets the environment own settings like the public URL and license key. A self-hosted instance (the default) keeps registration closed — relying on the first-boot setup screen plus the admin Create user flow on Team workspaces — and owns those settings from the dashboard instead. There is no public sign-up endpoint to call on a self-hosted deploy.
The validator only needs the license key — there is no API key, store ID or webhook secret to configure on the self-hosted side. Those are provisioned on the senddock.dev managed service that issues licenses.
If the license check fails (network outage, key revoked, etc.) SendDock keeps running with the last successful validation result for a grace period, then falls back to free-tier behavior. You'll see the cause on stdout: license: ….
Pro requires the prebuilt image
Pro features ship only in the official prebuilt ghcr.io/senddock/senddock image. Building from source (Option 4 in Installation) gives you Core only — setting SENDDOCK_LICENSE_KEY on a source build does nothing because the Pro features aren't included.
Ports
The numbers depend on which compose file you run.
Production (docker-compose.image.yml, docker-compose.prod.yml)
| Service | Where it listens | Exposed to host? |
|---|---|---|
| SendDock | :8080 inside the container | yes — on $SENDDOCK_PORT (default 8080) |
| PostgreSQL | :5432 inside the container | no — Docker network only |
| Redis | :6379 inside the container | no — Docker network only |
The bundled Postgres and Redis are reachable to the SendDock container by their service names (postgres, redis) on the standard internal ports. They are not published to the host — change that only if you also want to connect from outside Docker, and add an explicit ports: block.
Development (docker-compose.yml, used by make dev)
| Service | Host port |
|---|---|
SendDock API (make run) | 8080 |
| Frontend dev server (Vite) | 5173 |
| PostgreSQL | 5434 |
| Redis | 6380 |
The 5434 / 6380 offsets exist so the dev stack does not collide with a local Postgres / Redis you may have running on the host.