---
title: "Deploy bolt.diy App Builder"
description: "bolt.diy AI app builder behind a login gateway; bring your own model key"
category: "AI/ML"
url: https://railway.com/deploy/boltdiy-app-builder
---

# Deploy bolt.diy App Builder

bolt.diy AI app builder behind a login gateway; bring your own model key

**[Deploy bolt.diy App Builder on Railway](https://railway.com/template/boltdiy-app-builder)**

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

- **Creator:** Anton Orel's Projects
- **Category:** AI/ML
- **Total deploys:** 1

## Template content

### bolt-diy

- **Image:** ghcr.io/stackblitz-labs/bolt.diy:v1.0.3@sha256:89f1061e2ffad4f51125c6f931f18a4b2aaec2a1010799ea6b9608f399d7c99e
- **Start command:** `/bin/sh -ec 'mkdir -p /etc/ssl/certs; node -p "require(\"tls\").rootCertificates.join(\"\\n\")" >/etc/ssl/cert.pem; ln -sf /etc/ssl/cert.pem /etc/ssl/certs/ca-certificates.crt; exec pnpm run start'`
- **Health check:** /api/health

### bolt-diy Gateway

- **Image:** caddy:2.11.9-alpine@sha256:003a97808e781aa9f7e75cc2f43d34d461099031faf5e20faefb9f61126836f0
- **Start command:** `/bin/sh -ec '[ "${#BOLT_PASSWORD}" -ge 16 ] || { echo "BOLT_PASSWORD must have 16 or more characters; refusing to start" >&2; exit 64; }; case "${BOLT_USERNAME:-}" in "" | *[!A-Za-z0-9._-]*) echo "BOLT_USERNAME must be letters, digits, dot, dash or underscore" >&2; exit 64;; esac; case "${BOLT_UPSTREAM:-}" in "" | *[!A-Za-z0-9.:-]*) echo "BOLT_UPSTREAM must be host:port" >&2; exit 64;; esac; case "${PORT:-}" in "" | *[!0-9]*) echo "PORT must be a number" >&2; exit 64;; esac; BOLT_PASSWORD_HASH="$(printf "%s\n" "$BOLT_PASSWORD" | caddy hash-password)"; export BOLT_PASSWORD_HASH; unset BOLT_PASSWORD; printf %s "ewoJYWRtaW4gb2ZmCglhdXRvX2h0dHBzIG9mZgoJcGVyc2lzdF9jb25maWcgb2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lIHB1YmxpYyBob3N0IHN0YXlzIGluIFgtRm9yd2FyZGVkLUhvc3QuIGZsdXNoX2ludGVydmFsIC0xIGtlZXBzCgkjIHN0cmVhbWVkIG1vZGVsIG91dHB1dCB1bmJ1ZmZlcmVkLgoJaGFuZGxlIHsKCQliYXNpY19hdXRoIGJjcnlwdCBib2x0LmRpeSB7CgkJCXskQk9MVF9VU0VSTkFNRX0geyRCT0xUX1BBU1NXT1JEX0hBU0h9CgkJfQoJCXJldmVyc2VfcHJveHkgeyRCT0xUX1VQU1RSRUFNfSB7CgkJCWhlYWRlcl91cCAtQXV0aG9yaXphdGlvbgoJCQloZWFkZXJfdXAgSG9zdCB7dXBzdHJlYW1faG9zdHBvcnR9CgkJCWZsdXNoX2ludGVydmFsIC0xCgkJfQoJfQp9Cg==" | base64 -d >/tmp/Caddyfile; exec caddy run --config /tmp/Caddyfile --adapter caddyfile'`
- **Health check:** /healthz
- **Public domain:** Yes

## Documentation

# Deploy and Host bolt.diy App Builder on Railway

Deploy bolt.diy, the open-source AI app builder from the Bolt.new team, behind a password-protected gateway. Describe an app in chat and bolt.diy writes the code, runs it in your browser, and lets you edit, preview and export it, using the model provider and API key you choose.

## About Hosting bolt.diy App Builder

[bolt.diy](https://github.com/stackblitz-labs/bolt.diy) is a self-hosted alternative to Bolt.new that works with OpenAI, Anthropic, Google, OpenRouter, Groq, DeepSeek, Mistral, xAI and any OpenAI-compatible endpoint. This template runs bolt.diy `v1.0.3`, pinned to an exact image digest, as a private service, and puts a Caddy gateway with a generated password in front of it. Generated projects run in a WebContainer in your browser; chats and files are saved in your browser, so the server needs no database or volume.

## Why Deploy bolt.diy App Builder on Railway

bolt.diy has no login of its own, and its server calls model providers with your keys and proxies git requests to any host, so an exposed instance can spend your credits. This template makes the authenticated gateway the only public entry point and generates the password at deploy time. It also fixes two problems that break the upstream image on a plain deployment: the image has no CA certificates, so every server-side HTTPS call to a model provider fails, and its preview server rejects requests for any public host name with 403.

## Common Use Cases

- Prototype web apps and landing pages from a prompt with your own OpenAI, Anthropic, Gemini or OpenRouter key.
- A private Bolt.new-style workspace for yourself or a small team, without per-seat pricing.
- Try different models, including self-hosted OpenAI-compatible endpoints, on the same app-building workflow.

## Dependencies for bolt.diy App Builder Hosting

You need an API key for a language model provider and a recent Chromium-based browser (Chrome, Edge or Brave). Everything else is included and all credentials are generated.

### Deployment Dependencies

- bolt.diy `v1.0.3` (official image) for the app builder UI and model calls.
- Caddy `2.11.9` for HTTP Basic Auth and the public reverse proxy.
- StackBlitz WebContainers, loaded by your browser, to run generated projects. StackBlitz requires a commercial WebContainer API license for production use in a for-profit setting: https://webcontainers.io/enterprise

After deployment, open `bolt-diy Gateway` and sign in with `BOLT_USERNAME` and `BOLT_PASSWORD` from that service's variables, then add your provider key in bolt.diy's first-run setup.

Projects are stored in your browser, not on the server: export them as a ZIP or push them to GitHub to keep a copy. This is a single-login deployment for personal or small-team use. Behind the gateway, running Supabase SQL from chat alerts and cloning private repositories through bolt.diy's git proxy are not supported.


## 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 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/boltdiy-app-builder
