Platform CLI Use cases
Learn
Developer docs User guide Quickstart CLI and AI agents Blog
Company
Services About Contact Links Get started
One-click deploy

Deploy Raytha on Railway

The Raytha template on Railway sets up the CMS, a PostgreSQL database and a volume for your uploads in one project. Click deploy, open your new site and create the first administrator.

What you get

Two services, wired together

The template creates a Raytha service from the official Docker image and a PostgreSQL service next to it. Railway generates the database password and hands the connection string to Raytha, so there is nothing to copy and paste.

  • Raytha from the raythahq/raytha Docker image, with a public Railway domain and HTTPS
  • PostgreSQL 17 (Railway's postgres-ssl image) with its own volume
  • A volume at /data on the Raytha service; uploads go to /data/user-uploads
  • Database migrations applied automatically on every start
  • A health check on /healthz
  • Optional SMTP variables for password resets and sign-in emails

Read the Railway guide

ConnectionStrings__DefaultConnection=<from the Postgres service>
APPLY_PENDING_MIGRATIONS=true
FILE_STORAGE_PROVIDER=Local
FILE_STORAGE_LOCAL_DIRECTORY=/data/user-uploads
FILE_STORAGE_MAX_FILE_SIZE=100000000
FILE_STORAGE_ALLOWED_MIMETYPES=text/*,image/*,video/*,audio/*,application/pdf

# optional
SMTP_HOST=
SMTP_PORT=
SMTP_USERNAME=
SMTP_PASSWORD=
SMTP_FROM_ADDRESS=
SMTP_FROM_NAME=
Your first fifteen minutes

From click to a working site

You need a Railway account. Everything else comes with the template.

railway.com/deploy/raytha-cms
  -> Deploy
  -> raythahq/raytha  ... Active
  -> Postgres         ... Active

What it costs

Raytha is free and MIT licensed. You pay Railway for the resources the two services use, at Railway's usage rates. A summary of Railway's published pricing, as of October 2026:

Railway planPriceNotes
Trial$0A one-time $5 credit, usable for up to 30 days
Free$0 / month$1 of credit a month; 0.5 GB RAM per service and 0.5 GB volumes
Hobby$5 / monthIncludes $5 of resource usage a month; 5 GB volumes
Pro$20 / monthIncludes $20 of resource usage a month

Usage above the included amount is billed per minute: RAM at $10 per GB per month, CPU at $20 per vCPU per month, volume storage at $0.15 per GB per month and egress at $0.05 per GB. Your bill depends on how much memory and CPU Raytha and PostgreSQL actually use, so watch the project's usage page for the first few days. Check railway.com/pricing and Railway's plan docs for the current numbers.

Railway deletes volumes created on a Trial account 30 days after the trial credit expires, so upgrade to a paid plan before then if you want to keep the site.

Domains, backups and upgrades

  • Custom domain. Add it in the Raytha service's networking settings on Railway, then change the Website URL under Settings, Configuration in the Raytha admin. If Cloudflare proxies the domain, set TRUSTED_PROXY_HOPS=2. See Running behind a proxy.
  • Backups. Both services keep their data on Railway volumes, and Railway can back up volumes on a daily, weekly or monthly schedule. Keep your own pg_dump as well. See Backups and upgrades on Railway.
  • Upgrades. The template tracks the raythahq/raytha image's latest tag with automatic updates off, so nothing changes until you redeploy. Pin a version tag such as raythahq/raytha:2.0.1 if you want to choose exactly when to move.
FAQ

Raytha on Railway

Do I need a Railway account?

Yes. The template deploys into your own Railway account and project, and Railway bills you for what the services use. Raytha itself is free.

Can I move off Railway later?

Yes. Raytha is a standard Docker image and a PostgreSQL database. Take a pg_dump of the database, copy the uploads from the volume, and run the same Raytha version anywhere with Docker. See Backups and restores.

Which version of Raytha does the template run?

The template uses the raythahq/raytha image without a tag, which means latest, with Railway's automatic image updates turned off. A redeploy pulls whatever latest is at that moment. To stay on one version, set the service's image to a version tag such as raythahq/raytha:2.0.1.

Where are uploaded files stored?

On the Raytha service's volume, at /data/user-uploads, so they survive redeploys. You can switch to S3-compatible storage or Azure Blob with the variables in File storage.

Do I have to know .NET?

No. You work in the admin, in Liquid templates, and with the REST API or the CLI. .NET matters only if you want to change Raytha's own code.

Will email work?

Only after you add SMTP settings, either as the SMTP_* variables on the Raytha service or in the admin. Without them, password resets and sign-in emails cannot be sent. See Sending emails.

Is there a hosted Raytha service instead?

No. Raytha is self-hosted. Railway is the quickest way to run it; Docker and source builds work anywhere. For hands-on help, see services and support.

Run Raytha on Railway

Raytha and PostgreSQL in one project. Open source, and yours to move whenever you want.