Skip to content
Home / Migrations / Vercel → Railway

Vercel → Railway

medium

Railway removes Vercel's egress fees and function execution limits. Better for server-rendered apps, background workers, and long-running processes.

Estimated: 2-4h · 5 steps
Progress0%
Step 1: Create Railway project

railway login && link to your GitHub repo. Railway auto-detects the build command.

railway login && railway init
Step 2: Configure build

For Next.js: set the start command to `node .next/standalone/server.js`. Set NODE_ENV=production.

railway variables set NODE_ENV=production
Step 3: Add database

Click 'New Service' → PostgreSQL. Railway auto-injects DATABASE_URL.

Step 4: Set environment variables

Copy all Vercel env vars to Railway. Railway: Settings → Variables.

✓ App builds and starts successfully on Railway URL
Step 5: Update DNS

Add custom domain in Railway settings. Update DNS CNAME from Vercel to Railway.

Get started with Railway →

What this migration involves

Moving from Vercel to Railway is rated medium and takes about 2-4h on a typical project. The guide breaks it into 5 steps, 2 of which ship with runnable commands and 1 with a verification check. On pricing, Vercel is freemium and Railway is freemium with a free plan to test the move.

FAQ

How long does migrating from Vercel to Railway take?

Around 2-4h for a typical project — 5 steps, difficulty rated medium, 2 of them with copy-paste commands.

Is moving from Vercel to Railway reversible?

No reverse guide is tracked yet, so treat this as a one-way move and keep a full export of your Vercel data before you start.

What does Railway cost compared to Vercel?

Vercel: freemium from $20/mo, free plan available. Railway: freemium from $5/mo, free plan available.