Skip to content

Deploy Your Application

Varity Team Core Contributors Updated May 2026

Deploy your application to Varity with one command.

  1. Install the CLI

    Terminal window
    pipx install varitykit
  2. Build your project

    Terminal window
    npm run build
  3. Deploy

    Terminal window
    varitykit app deploy
  4. Your app is live!

    Varity will output your live URL:

    ✓ Deployed successfully!
    ✓ URL: https://your-app.varity.app
    ✓ Build time: 1m 23s
    ✓ Status: Live

When you run varitykit app deploy:

  1. Detects your framework - Automatically identifies Next.js, React, Vue, etc.
  2. Builds your app - Runs your build command (npm run build)
  3. Uploads your files - Stores them securely with automatic backups
  4. Makes your app live - Generates a public URL
  5. Returns a live URL - Static apps use https://varity.app/<name>/; dynamic apps use https://<name>.varity.app/

All of this happens automatically.

Choose the right hosting for your application type:

Static Sites

Best for: React, Vue, Next.js static exports, documentation, landing pages

Features:

  • Global CDN distribution
  • Instant cache invalidation
  • Automatic SSL certificates
  • Fixed profile pricing
Terminal window
varitykit app deploy

Dynamic Apps

Best for: Full-stack apps, APIs, real-time applications, databases

Features:

  • Container-based compute
  • Managed container hosting
  • Database support
  • WebSocket support
Terminal window
varitykit app deploy --hosting dynamic

Credentials are managed automatically by Varity. Optionally set your app ID:

.env.local
# Optional: Your Varity App ID
NEXT_PUBLIC_VARITY_APP_ID=<your-app-id>

See Environment Variables for the complete list and Managed Credentials for how credential auto-provision works.

Always test your build works locally:

Terminal window
npm run build
npm run start

Visit http://localhost:3000 and verify everything works.

View your deployment history:

Terminal window
varitykit app list

Output:

ID Status URL Deployed
deploy-1737491000 live https://your-app.varity.app 2 hours ago
deploy-1737484800 archived https://your-app-v2.varity.app 1 day ago
deploy-1737398400 archived https://your-app-v1.varity.app 2 days ago

Revert to a previous deployment:

Terminal window
varitykit app rollback deploy-1737484800

Your app will instantly switch to the selected version. See Rollback a Deployment for a full walkthrough, including how to find deployment IDs and handle caveats around environment variables and database migrations.

Check the details of a specific deployment:

Terminal window
varitykit app info deploy-1737491000

View overall deployment status:

Terminal window
varitykit app status

Every deployment gets a public URL. URL format depends on hosting type:

Terminal window
varitykit app deploy --name my-app
# Static hosting → https://varity.app/my-app/
# Dynamic hosting → https://my-app.varity.app/

See Custom Domains for the current status of bring-your-own domains.

  1. Verify your build works locally:

    Terminal window
    npm run build
  2. Check the build output directory exists:

    • Next.js: .next/ or out/
    • React: dist/ or build/
    • Vue: dist/

Credentials are auto-provided. If you see this error, run varitykit doctor to check your setup.

Check your internet connection:

Terminal window
varitykit doctor

If issues persist, try deploying with verbose output:

Terminal window
varitykit app deploy --verbose
OptionDefaultDescription
--hostingstaticHosting type: static or dynamic
--path.Project directory