Use when deploying applications to Railway — GitHub deploys, Railway CLI, one-click databases (Postgres, MySQL, MongoDB, Redis), environment management, multi-service projects. Also use when comparing deployment platforms for backend services.
| Model | Source |
|---|
| sonnet | pack: deploy |
| Scenario | Platform |
|---|
| Full-stack app + persistent database | Railway |
| Serverless/JAMstack frontend | Vercel |
| Edge workers, global CDN | Cloudflare |
| Container-first, custom infra | Docker + self-host |
Full Reference
┏━ 🚀 railway ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
┃ Use when deploying to Railway — full-stack, ┃
┃ databases, multi-service, per-utilization ┃
┗━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┛
Railway is a cloud platform for full-stack deployments. GitHub push-to-deploy, auto-detected builds via Railpack, one-click databases, private networking between services, and per-second resource billing. The “real server with a database” answer when Vercel’s serverless model doesn’t fit.
| Item | Value |
|---|
| CLI Install | npm i -g @railway/cli or brew install railway |
| Docs | https://docs.railway.com |
| Auth | railway login (browser OAuth) |
| Deploy current dir | railway up |
| Run with env vars | railway run <command> |
| Stream logs | railway logs |
| Key env vars | RAILWAY_PUBLIC_DOMAIN, RAILWAY_PRIVATE_DOMAIN, RAILWAY_ENVIRONMENT |
| Scenario | Platform |
|---|
| Full-stack app + persistent database | Railway |
| Serverless/JAMstack frontend | Vercel |
| Edge workers, global CDN | Cloudflare |
| Container-first, custom infra | Docker + self-host |
| I want to… | File |
|---|
| Install CLI, link a project, initialize, first deploy | reference/setup.md |
railway up, GitHub deploys, Dockerfile, Railpack, railway.toml | reference/deployment.md |
| Add Postgres/MySQL/MongoDB/Redis, connection strings, volumes | reference/databases.md |
| Create environments, variable inheritance, PR environments, secrets | reference/environments.md |
| Multi-service projects, private networking, TCP proxy, service deps | reference/services.md |
| Hobby vs Pro pricing, usage rates, cost estimation | reference/pricing.md |
Usage: Read the reference file matching your task. Each file is self-contained with commands and gotchas.