Deploy Alby Hub

Self-custodial Bitcoin Lightning node and NWC wallet, pinned and persistent

Deploy Alby Hub

/data

Deploy and Host Alby Hub on Railway

Alby Hub is an open-source, self-custodial Bitcoin Lightning wallet and node from Alby. It runs an embedded LDK Lightning node (or connects to LND, Phoenixd or CLN) and lets you link apps to your wallet with Nostr Wallet Connect (NWC), each with its own budget and permissions, from one web interface.

About Hosting Alby Hub

This template runs the official Alby Hub v1.24.7 image, pinned by digest, as one service built from a public GitHub repo, so you get Railway's update notices when the version is bumped. A volume at /data keeps the database, encrypted seed and Lightning channel state across redeploys. A setup code is generated for each deploy: copy SETUP_CODE from the service's Variables tab, open https://YOUR-DOMAIN/?c=SETUP_CODE, choose an unlock password and save your recovery phrase. After each redeploy, open the hub and unlock it so the node starts again. Keep one replica only.

Common Use Cases

  • Run your own always-online, self-custodial Lightning wallet and node
  • Connect Nostr clients, zaps and Lightning apps to your wallet with NWC budgets
  • Receive and send Lightning payments while you keep the keys and channel data

Dependencies for Alby Hub Hosting

  • A Railway volume for the hub's data (included)
  • Outbound internet access to Lightning peers, Esplora/Electrum and Nostr relays (Railway provides it)

Deployment Dependencies

Implementation Details

  • Variables: SETUP_CODE (generated), PORT=8080, RAILWAY_DEPLOYMENT_DRAINING_SECONDS=300 so the node shuts down cleanly. The deploy asks for nothing.
  • Health check: /api/info, which answers without login.
  • Optional: set AUTO_UNLOCK_PASSWORD to start the node without unlocking after a redeploy, LN_BACKEND_TYPE to use an external node, or LOG_LEVEL. See the Alby Hub README.
  • Updates: when the template repo pins a new release, Railway shows an update notice on your project. Read the CHANGELOG in the template repo, apply the update, then unlock the hub again.
  • Back up your recovery phrase. Without it, losing the volume can lose funds.

Why Deploy Alby Hub 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 Alby Hub on Railway, you are one step closer to supporting a complete full-stack application with minimal burden. Host your servers, databases, AI agents, and more on Railway.


Template Content

More templates in this category

View Template
Rocky Linux
Hosted Rocky Linux 9 workspace with SSH and persistent storage. 🚀

codestorm
51
View Template
Foundry Virtual Tabletop
Self-hosted virtual tabletop for role-playing games (license required)

Lucas
71
View Template
NEW
Double Commander in your browser
The Double Commander file manager in the cloud, from any device

Nermin Sabanovic
0