Railway

Deploy Tinykit — Self-Hosted AI App Builder

Self-host an AI app builder — DB, storage & 100+ apps, one service

Deploy Tinykit — Self-Hosted AI App Builder

Just deployed

/app/pocketbase/pb_data

Deploy and Host Tinykit on Railway

Tinykit is an open-source, self-hosted AI app builder — a self-hostable alternative to Lovable, v0, and Replit. Prompt an AI agent to write code, create database tables, and wire it together, then deploy instantly. Because it's powered by PocketBase, every app gets a real-time database, authentication, and file storage built in — no separate services to add. And it's dense: a single Railway service can host 100+ small real-time apps, each updated by typing /tinykit after its domain. This template deploys the whole thing in one click.


What This Template Deploys

ServicePurpose
TinykitThe AI builder studio, runtime, and embedded PocketBase (database, auth, storage) on port 5173

A single self-contained service — no separate database to provision. PocketBase runs inside it, providing the real-time database, authentication, and file storage. A persistent volume holds all your apps, data, and uploads.


About Hosting

Tinykit is refreshingly self-contained, and understanding how it's built explains why it's cheap and simple to run.

One service, everything included — thanks to PocketBase. Tinykit embeds PocketBase, so the database, real-time subscriptions, authentication, and file storage all live inside the single container. There's no separate Postgres or Redis to wire up. That's what makes "real-time database & storage included" literal: deploy one service and you have the full backend, which keeps cost and complexity low.

Host 100+ apps on one deployment. Tinykit runs the builder (the "studio") and the apps it creates on the same server. You build at /tinykit, deploy to a domain, and can point many domains at one instance — hosting dozens or hundreds of small real-time apps from a single Railway service. Each app is one Svelte file with auto-generated tables that sync in real time, updated by adding /tinykit after its domain.

Bring your own LLM key. The AI agent needs a model. Configure your LLM from inside the app, or set the API key as an environment variable. You supply the key and pay your provider directly; Tinykit orchestrates the prompting and code generation.

Persist the volume — it holds everything. Your apps, their databases, content, and uploaded assets all live in Tinykit's data directory. Mount the volume so nothing is lost on redeploy. Tinykit also keeps snapshots on every change ("time travel"), so you can undo edits — but that history lives in the same persistent store.

It's early alpha — scope it accordingly. Tinykit is in active early-alpha development. It's excellent for personal utility tools, small-business CRUD apps, and internal tools, and AI-generated code should be reviewed before handling sensitive data or running in production. Pin a version, since it evolves quickly, and treat it as a fast-moving project rather than a stable platform.

Typical cost: ~$5–10/month on Railway for the single service — remarkably cheap for the number of apps it can host — plus your own LLM usage. Tinykit is open source and free.


How It Compares

Tinykit (self-hosted)Lovable / v0Bolt.diyReplit
Cost modelFlat infra + your LLMSubscriptionYour LLMSubscription
Data ownershipFull — your serverVendorFullVendor
Backend includedDB, auth, storageManagedYou addManaged
Apps per instance100+Per projectPer projectPer project
Self-hostableYesNoYesNo
Code accessFull (Svelte)ExportFullFull

Lovable, v0, and Replit are polished but keep your code and data on their servers and bill monthly. Bolt.diy is self-hostable but you assemble the backend yourself. Tinykit's edge is being genuinely self-contained — AI builder, runtime, and a full PocketBase backend in one cheap service, hosting many apps at once, with your code and data entirely on infrastructure you own.


Deploy in Under 5 Minutes

  1. Click Deploy on Railway — Tinykit builds automatically (~2 minutes)
  2. Confirm the volume is mounted for apps, data, and uploads
  3. Visit /setup on your Railway domain to complete first-time setup
  4. Add your LLM API key (in-app or as an environment variable)
  5. Go to /tinykit, prompt the agent to build an app, and deploy it to a domain

Point additional domains at the same instance to host more apps from one deployment.


Common Use Cases

  • Internal tools — spin up CRUD apps, dashboards, and admin panels for a team by describing them to the AI
  • Small-business apps — build booking forms, inventory trackers, or client portals without a dev team
  • Personal utilities — quick single-purpose apps with a real-time database, hosted on your own server
  • Rapid prototyping — go from prompt to working app with data and storage in minutes, then iterate
  • Multi-app hosting — run many small apps for different clients or projects from one cheap deployment
  • Private vibe-coding — the Lovable/v0 experience with your code and data staying entirely on your infrastructure

Configuration

VariableRequiredDescription
PORTPre-set5173 — the Tinykit studio and app runtime
OPENAI_API_KEYRecommendedLLM key for the AI agent (or configure a provider in-app)
DATA_DIRPre-setPath to the apps, database, and uploads on the mounted volume
PB_ENCRYPTION_KEYOptionalEncrypts the embedded PocketBase settings at rest

Persist the data volume — it holds all your apps and data. Every app, its database, content, and uploads live in Tinykit's data directory. Without a mounted volume, a redeploy erases them. Snapshots also live here.

Bring your own LLM key, and review generated code. Set your model API key in-app or via environment. Because Tinykit is early alpha, review AI-generated code before using it with sensitive data or in production.


Dependencies for Tinykit Hosting

  • Railway account — ~$5–10/month for the single service, plus LLM usage
  • A persistent Railway volume for apps, database, and uploads (included)
  • An LLM API key (OpenAI-compatible or a supported provider) for the AI agent
  • No external database — PocketBase is embedded

Deployment Dependencies

Implementation Details

The template runs Tinykit as a single self-contained service on port 5173. It bundles an AI agent, a code editor, and a runtime with an embedded PocketBase instance that supplies the database, real-time subscriptions, authentication, and file storage — so no external data services are required. All state (apps, databases, content, and uploaded assets) lives in the data directory on a persistent volume, and Tinykit records a snapshot on every change to support undo.

The builder studio is reachable at /tinykit and the apps it generates are served from the same instance, each as a single Svelte file with auto-generated, real-time-syncing tables. Because the builder and the built apps share one server, a single deployment can host 100+ small apps, with additional domains pointed at the same instance. The AI agent requires an LLM, configured in-app or via an environment variable, and calls out to your chosen provider.

Tinykit is in early-alpha development and evolving rapidly, so pinning a version and reviewing generated code before production use is recommended. First-time setup is completed at /setup after deployment.


Frequently Asked Questions

Do I need a separate database? No. Tinykit embeds PocketBase, which provides the real-time database, authentication, and file storage inside the single service. That's what "database & storage included" means — one container, full backend.

How many apps can I host? A single instance can run 100+ small real-time apps, since the builder and the apps share one server. Point multiple domains at the same deployment and update any app by adding /tinykit after its domain.

Do I need to bring my own AI model? Yes. Configure an LLM key in-app or as an environment variable — you supply the model and pay your provider directly, while Tinykit handles the agentic code generation.

Is it production-ready? It's early alpha, best for personal tools, small-business CRUD apps, and internal tools. Review AI-generated code before using it with sensitive data or in production, and pin a version since it changes fast.

Do my apps persist across redeploys? Yes, with the volume mounted — apps, databases, content, and uploads all live there, along with the snapshot history. Without the volume, they reset.

What does "time travel" do? Tinykit snapshots on every change, so you can undo any edit and roll an app back. That history is stored on the volume.

How is it different from Lovable or v0? Same prompt-to-app experience, but self-hosted — your code and data stay on your infrastructure, no subscription, and one cheap service hosts many apps with a full backend included.


Why Deploy Tinykit 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 Tinykit on Railway you get a self-hosted AI app builder in one click — the studio, runtime, and a full PocketBase backend in a single service, with a persistent volume and automatic HTTPS. Prompt-to-app development with real-time database and storage included, hosting many apps at once, on infrastructure you own.


Template Content

More templates in this category

View Template
Chat Chat
Chat Chat, your own unified chat and search to AI platform.

okisdev
113
View Template
stella
Self-host stella with web, API, Postgres, Redis, and object storage.

Jan Kubica
1
View Template
Hermes Agent | OpenClaw Alternative with Dashboard
Self-Hosted Hermes AI Agent for Telegram, Discord & Slack

codestorm
56