Migrate from Vercel to Varity
Move your existing Vercel app to Varity in under 3 minutes. The migration tool removes Vercel-specific code, installs Varity packages, and deploys your app automatically.
What gets migrated automatically
Section titled “What gets migrated automatically”vercel.json: removed@vercel/*npm packages: removed frompackage.json- Next.js image optimizer config (
unoptimized: true): set automatically - Vercel-specific environment variable names: renamed to Varity equivalents
- Edge runtime declarations: updated
All changes are backed up to .vercel-migration-backup/ so you can roll back.
Migrate using AI (recommended)
Section titled “Migrate using AI (recommended)”The fastest path is to ask your AI editor to migrate for you.
Ask your AI editor:
“Migrate my Vercel app at https://github.com/username/my-app to Varity”
The varity_migrate MCP tool will:
- Clone your GitHub repository
- Remove Vercel-specific artifacts
- Build the transformed app to verify it compiles
- Deploy to Varity and return a live URL
To preview what would change without deploying:
“Do a dry run migration of https://github.com/username/my-app”
Migrate using the CLI
Section titled “Migrate using the CLI”-
Install the CLI (if you haven’t already)
Terminal window pipx install varitykit -
Preview what will change (optional)
Terminal window varitykit migrate --url https://github.com/username/my-app --dry-runOr for a local directory:
Terminal window varitykit migrate --path ./my-app --dry-run -
Run the migration
Terminal window varitykit migrate --url https://github.com/username/my-appThis clones your repo, applies codemods, and deploys to Varity. Your app will be live at a
varity.appURL.
Advanced: step-by-step control
Section titled “Advanced: step-by-step control”Use subcommands if you want to inspect changes before deploying:
# 1. Analyze only (read-only, no changes)varitykit migrate analyze ./my-app
# 2. Apply codemods but don't deployvaritykit migrate apply ./my-app
# 3. Deploy when readyvaritykit app deploy --path ./my-app
# Undo all codemods if something goes wrongvaritykit migrate rollback ./my-appAfter migration
Section titled “After migration”- Your app runs on Varity infrastructure with database and hosting included
- Environment variables are managed automatically. No manual configuration needed
- Review any warnings from the migration output and fix manually if needed
- Set a custom subdomain or check the cost of your new deployment
Troubleshooting
Section titled “Troubleshooting”Build fails after migration
Section titled “Build fails after migration”If the transformed app fails to build, common causes are:
- TypeScript errors introduced by removing
@vercel/*peer dependencies - Edge runtime APIs not available outside Vercel (check warnings in migration output)
Fix the errors in your source repository, then run varitykit migrate again.
Roll back to Vercel code
Section titled “Roll back to Vercel code”varitykit migrate rollback ./my-appThis restores all files from .vercel-migration-backup/.
Next steps
Section titled “Next steps”- Deploy your app: understand what happens during deploy
- Environment variables: how credentials work
- Custom domains: set a custom subdomain for your app