---
title: "Deploy AstralBeam"
description: "Self-host AstralBeam with PostgreSQL 18 and private object storage."
category: "AI/ML"
url: https://railway.com/deploy/astralbeam
---

# Deploy AstralBeam

Self-host AstralBeam with PostgreSQL 18 and private object storage.

**[Deploy AstralBeam on Railway](https://railway.com/template/astralbeam)**

Machine-readable deploy manifest (JSON, validated by TemplateCI): https://railway.com/deploy/astralbeam/manifest.json

- **Creator:** Hasan Kumar
- **Category:** AI/ML
- **Total deploys:** 2

## Template content

### Platform https://raw.githubusercontent.com/AstralBeamAI/astralbeam/main/platform/public/astralbeam-logo-dark.png

- **Image:** ghcr.io/astralbeamai/astralbeam-platform
- **Health check:** /api/status
- **Public domain:** Yes

### Postgres https://devicons.railway.app/i/postgresql.svg

- **Image:** ghcr.io/railwayapp-templates/postgres-ssl:18

## Buckets

- **Files**

## Documentation

# Deploy and Host AstralBeam on Railway

AstralBeam adds an embeddable AI assistant to your application. This template provisions the Platform, PostgreSQL 18, and a private Railway object-storage bucket. It generates infrastructure credentials and connects the resources for you. After deployment, complete operator setup, invite the owner, and connect your organization's model providers.

**Draft status:** Infrastructure deployment has succeeded, but the current Platform image's `/configure` page needs a Railway HTTPS-ingress compatibility fix. Replica scaling and workflow recovery during deployment replacement are not yet validated. Keep this template unpublished and use it only for evaluation until those checks pass.

## About Hosting AstralBeam

The template uses the official Platform image pinned to version `0.23.7`, Railway's PostgreSQL 18 image with persistent storage and daily backups configured, and a private Railway bucket for files. Platform receives the database and bucket credentials through reference variables. The database is not exposed through a public TCP proxy. A pre-deploy command applies database migrations, and the deployment healthcheck calls `/api/status` on port 3000. The application service has one replica and no persistent application volume. Its data lives in PostgreSQL and the bucket. Infrastructure, model-provider, email, and optional sandbox usage are billed by their respective providers.

## Common Use Cases

- Add an AI assistant to an existing web application through the AstralBeam SDK.
- Give an assistant access to application tools and interactive widgets.
- Evaluate self-hosted conversations and file handling with your own model-provider connections.

## Dependencies for AstralBeam Hosting

- A Railway account and a plan that permits deployment. An expired trial can prevent deployment even though template editing works.
- PostgreSQL 18 and a private Railway bucket, both included in this template.
- Real Cloudflare Turnstile site and secret keys authorized for your deployment's hostname.
- A support email address and working transactional email. The existing Resend HTTPS integration is recommended. Railway blocks outbound SMTP on Free, Trial, and Hobby plans.
- At least one supported model-provider connection configured after owner sign-in.
- A supported remote sandbox provider if you enable coding-sandbox features. This template does not include a Docker daemon.

### Complete Setup

1. Deploy the template with the bucket in the same region as the application and database. Railway selects service placement separately from the bucket region. If you customize the bucket region, align both services under **Settings → Regions &amp; Replicas** before completing setup.
2. Open the generated HTTPS application domain at `/configure`.
3. Retrieve the generated `DATABASE_ENCRYPTION_KEY` from Platform's Variables tab and use it to sign in as the operator. Preserve this key and back it up separately. Do not put it in a URL.
4. Test storage. Configure real Turnstile keys, your support address, and transactional email. Test email connectivity, then save.
5. Choose **Invite owner**, follow the email to create the owner's password, and sign in to the application.
6. Configure a model provider and assign an enabled model to an agent before testing chat or integrating the SDK.

The deploy button provisions infrastructure. It does not supply email, Turnstile, or model credentials, and it does not create a default owner account. If you attach a custom domain, update the public base URL and Turnstile hostname configuration.

### Placement and Scaling

Keep the resources in one Railway project, environment, and region for private database connectivity and nearby storage. Same-region placement does not guarantee the same physical host. A bucket's region cannot be changed after creation. Moving an existing database service relocates its volume and causes downtime, so choose the region before onboarding users.

Platform keeps shared state in PostgreSQL and the bucket. Do not attach an application volume, because Railway does not allow replicas on services with attached volumes. Start with one Platform replica. Scaling and rolling-deployment recovery require individually reachable private workflow-runner addresses and remain release gates for this draft. The shared service hostname is not a unique runner address. A second application replica would not make the PostgreSQL service highly available.

The existing application runtime owns background workflows and scheduled maintenance. Keep Serverless disabled. This stack does not require a separate Redis, worker, or Railway cron service.

### Updates and Recovery

Application image auto updates are disabled. To upgrade, read the release notes, back up PostgreSQL and stored objects, preserve the encryption keyring, and select an explicit Platform image version. Check for newly required configuration before deploying. Migrations run before the new application starts. A container rollback does not reverse database migrations or restore files. The daily database backup configuration does not back up the bucket or your keyring.

`/api/status` confirms application SQL access during deployment. It does not prove completed onboarding, storage connectivity, or workflow progress, and Railway does not continuously probe it after deployment. Keep the service always on because Platform runs durable workflows and maintenance. This template makes no high-availability or zero-downtime guarantee.

### Source and Documentation

- <a rel="noopener noreferrer" href="https://github.com/AstralBeamAI/astralbeam">AstralBeam source</a>
- <a rel="noopener noreferrer" href="https://github.com/AstralBeamAI/astralbeam/releases">Release notes</a>
- <a rel="noopener noreferrer" href="https://astralbeam.ai/docs/self-hosting/deploy">Deployment and setup guide</a>
- <a rel="noopener noreferrer" href="https://astralbeam.ai/docs/self-hosting/operations">Backups, upgrades, and recovery</a>

## Why Deploy AstralBeam on Railway?

Railway brings the application, database, and object storage into one project, with generated credentials, private database networking, and a public HTTPS application domain. You can manage deployment configuration and inspect logs from its dashboard while retaining control of your AstralBeam installation and provider connections.


## Similar templates

- [Chat Chat](https://railway.com/deploy/-WWW5r) — Chat Chat, your own unified chat and search to AI platform.
- [Weaviate](https://railway.com/deploy/weaviate-1) — Vector database with hybrid search and an API key-protected API
- [Möbius v0.1 Personal AI OS](https://railway.com/deploy/mobius-v01-personal-ai-os) — Self-hosted AI agent that builds and runs apps for you, with memory.

Open this page in a browser: https://railway.com/deploy/astralbeam
