Deploy Listmonk — Open Source Mailchimp Alternative
Self-hosted newsletter & mailing list manager, powered by Postgres
Listmonk
Just deployed
/listmonk/uploads
Just deployed
/var/lib/postgresql/data
Deploy and Host listmonk on Railway
listmonk is a high-performance, self-hosted newsletter and mailing list manager built in Go — an open-source alternative to Mailchimp, ConvertKit, and Substack. It handles subscriber management, campaign creation, transactional email, and analytics in a single binary, giving you full ownership of your audience data and no per-subscriber billing.
This template deploys listmonk with a managed PostgreSQL database and a persistent volume for uploads, wired together and ready to configure in minutes.
What This Template Deploys
| Service | Purpose |
|---|---|
| listmonk | The web UI, campaign engine, and REST API on port 9000 |
| PostgreSQL | Primary store for subscribers, lists, campaigns, templates, and analytics |
Both services run on Railway's private network with database credentials injected automatically. A Railway volume persists uploaded images, logos, and attachments across redeploys.
About Hosting listmonk
listmonk's only dependency is PostgreSQL — no Redis, no separate worker process, no external queue. It stores every subscriber, list, campaign, and analytics record in Postgres, so a reliable, persistent database is the one thing it cannot run without. This template provisions that for you and connects the two services on first deploy.
The performance story is the reason people choose it. listmonk is the tool Zerodha, a major Indian fintech, uses to send millions of emails per campaign, and its Go concurrency model handles those volumes on minimal hardware — peak memory stays remarkably low even on large sends. On Railway's Hobby plan it comfortably runs newsletters for small to medium lists, and scales vertically as your audience grows.
One thing to plan for: listmonk schedules and templates email, but it does not send it directly. You connect an external SMTP provider — Amazon SES, Postmark, SendGrid, Mailgun, or similar — and listmonk delivers through it. This is the standard, deliverability-friendly way to run self-hosted email.
Typical cost: ~$5–10/month on Railway for listmonk and Postgres, plus your SMTP provider's per-email cost — which for SES and similar is a fraction of what Mailchimp charges per subscriber.
Deploy in Under 5 Minutes
- Click Deploy on Railway and wait for both services to build (~3 minutes)
- Set
LISTMONK_ADMIN_USERandLISTMONK_ADMIN_PASSWORDto create your super admin - Open the generated Railway domain and log in with those credentials
- In Settings → General, set the Root URL to your Railway domain (no trailing slash)
- In Settings → SMTP, add your email provider's credentials, then create your first list and campaign
The database schema installs automatically on first boot — there is no manual install step.
Common Use Cases
- Mailchimp / ConvertKit replacement — run newsletters at a flat infrastructure cost instead of paying per subscriber as your list grows
- Self-hosted Substack alternative — own your audience relationship and export your subscriber data at any time
- High-volume campaigns — multi-threaded, multi-SMTP queues with throughput and rate-limit controls for large sends
- Transactional email via API — send templated receipts, confirmations, and alerts through listmonk's REST API
- Segmented lifecycle email — SQL-based subscriber segmentation and custom JSON attributes for targeted campaigns
- Product and community updates — single or double opt-in lists with bounce handling and open/click analytics
Configuration
| Variable | Required | Description |
|---|---|---|
LISTMONK_ADMIN_USER | Required | Super admin username, set on first install |
LISTMONK_ADMIN_PASSWORD | Required | Super admin password — use a strong value |
LISTMONK_app__address | Pre-set | 0.0.0.0:9000 so Railway can route to the service |
LISTMONK_db__host | Auto-injected | PostgreSQL host via Railway reference variable |
LISTMONK_db__port | Auto-injected | PostgreSQL port |
LISTMONK_db__user | Auto-injected | PostgreSQL user |
LISTMONK_db__password | Auto-injected | PostgreSQL password |
LISTMONK_db__database | Auto-injected | PostgreSQL database name |
LISTMONK_db__ssl_mode | Pre-set | disable for Railway's private network |
LISTMONK_ORIGIN_0 | Optional | Allowed CORS origin — set to your frontend domain if embedding forms |
Set the Root URL after deploy. listmonk builds campaign links, tracking pixels, and unsubscribe URLs from the Root URL in Settings. If it's left at the default, links in your emails will point to the wrong place. Set it to your Railway domain with no trailing slash.
You must configure SMTP before sending. listmonk does not deliver email on its own. Add an SMTP provider under Settings → SMTP, or campaigns will queue but never send.
Dependencies for listmonk Hosting
- Railway account — Hobby plan (~$5–10/month) covers listmonk and Postgres
- An external SMTP provider (Amazon SES, Postmark, SendGrid, Mailgun, etc.) for delivery
- A sending domain with SPF, DKIM, and DMARC records configured for deliverability
Deployment Dependencies
- listmonk GitHub Repository
- listmonk Documentation
- listmonk Configuration Reference
- Railway Volumes Documentation
Implementation Details
The template runs the official listmonk/listmonk:latest image on port 9000 against a Railway PostgreSQL service. Configuration is entirely environment-variable driven using listmonk's LISTMONK_* convention, so there is no config.toml to mount. Database connection values are supplied through Railway reference variables, and ssl_mode is set to disable because traffic stays on Railway's private network.
listmonk installs its schema idempotently on first boot and applies upgrades on subsequent deploys, so moving to a newer image is a redeploy rather than a manual migration. A Railway volume persists user uploads — campaign images, logos, and attachments — which would otherwise live on the ephemeral container filesystem and be lost on redeploy.
All subscriber and campaign data lives in the PostgreSQL service. That database is your entire audience and history; back it up with pg_dump on a schedule.
Frequently Asked Questions
Does this send email on its own? No. listmonk handles scheduling, templating, and queueing, but delegates delivery to an external SMTP provider. Configure Amazon SES, Postmark, SendGrid, or similar under Settings → SMTP before sending.
Why does it need PostgreSQL? listmonk stores all subscribers, lists, campaigns, and analytics in Postgres. It has no embedded database and does not support SQLite or MySQL — Postgres is the only supported data store.
Can it handle large lists? Yes. listmonk runs in production at Zerodha sending millions of emails per campaign, and its Go concurrency model keeps memory low even on very large sends. Vertical scaling on Railway covers growth comfortably.
How is this cheaper than Mailchimp? Mailchimp and similar bill per subscriber, so cost climbs as your list grows. Here you pay flat Railway infrastructure plus your SMTP provider's per-email rate, which for SES-class providers is a fraction of the per-subscriber model.
Do my email links work correctly? Only once the Root URL is set. listmonk generates tracking, unsubscribe, and campaign links from that setting, so update it to your Railway domain immediately after deploy.
Can I use it for transactional email too? Yes. listmonk exposes a REST API for sending templated transactional messages — receipts, confirmations, alerts — alongside its bulk campaign features.
What about deliverability? Deliverability depends on your SMTP provider and your sending domain's SPF, DKIM, and DMARC records. Set those up on your domain and warm up your sending reputation gradually for best inbox placement.
Why Deploy listmonk on Railway?
Railway is a singular platform to deploy your infrastructure stack. Railway will host your infrastructure so you don't have to deal with configuration, while allowing you to vertically and horizontally scale it.
By deploying listmonk on Railway you get a complete, self-hosted email marketing platform that is yours end to end — listmonk and PostgreSQL pre-wired over a private network, automatic HTTPS, a persistent volume for uploads, and no per-subscriber billing. Own your audience data, bring your own SMTP, and run your newsletters alongside the rest of your stack.
Template Content
Listmonk
railwayapp-templates/listmonkLISTMONK_app__admin_username
Basicauth username
