How to deploy a Claude Code app

Terminal coding agent that writes code into a folder on your machine. Deploy like any Git project.

Short answer

Easiest: Railway. Cheapest: Cloudflare Pages. Database: Neon. Login: Clerk. Copy your environment variables into the host before the first build, and add the new URL to your auth provider.

Easiest

Railway

Deploys from GitHub or Dockerfile, handles servers and databases in one place.

Cheapest

Cloudflare Pages

Free for static sites and light serverless functions.

What Claude Code gives you

Anything you asked for.

Built-in hosting

No built-in hosting.

First: which kind of project do you have?

Type How to tell What the host needs
Static / SPA Build outputs dist/, build/ or out/. Cloudflare Pages, Netlify, Vercel, DigitalOcean static.
Server app / API / bot Has a start command that keeps running, often a Dockerfile. Railway, Render, Fly.io, DigitalOcean App Platform.

Get your code out

  • Ask it to initialise git and create a GitHub repo, or run git init / git push yourself.

Build settings

Build command
From package.json / Dockerfile
Output
Depends on framework
Node
Match local

Environment variables to copy

  • Everything in .env — add each value in the host dashboard.

Blank page after deploying?

Gotchas

  • Agents sometimes hard-code keys during prototyping. Search the code for secrets before pushing.

Step-by-step guides for Claude Code

Database & login

Data: Neon (opens in a new tab): Free: 100 projects, 100 CU-hours per project/month, 1 GB storage per project (20 GB total). Compare databases · Which database to pick

Auth: Clerk (opens in a new tab): Hobby: free — 50,000 monthly retained users per app, up to 3 social connections.

Common errors with Claude Code apps

Related guides

Common questions

What is the easiest way to host a Claude Code app?

Railway. Deploys from GitHub or Dockerfile, handles servers and databases in one place.

What is the cheapest way to host a Claude Code app?

Cloudflare Pages. Free for static sites and light serverless functions.

Does Claude Code have built-in hosting?

No built-in hosting. Not applicable.

Can I use a custom domain with Claude Code?

Set up at your host.

What build command and output folder does a Claude Code app use?

Build command From package.json / Dockerfile; output: Depends on framework.