Get StartedMigrationMigrate from Heroku

Migrate from Heroku

This guide walks you through migrating your application from Heroku to Zeabur. Most Heroku apps are Git-based and use standard language buildpacks, making the transition straightforward — Zeabur auto-detects your project with zero configuration.

Before You Begin

  • A Zeabur account.
  • Your application source code in a Git repository.
  • Access to your Heroku dashboard or CLI (heroku).

Step 1: Connect Your Git Repository

Most Heroku apps are already backed by a Git repository. If yours is:

  1. Log in to the Zeabur dashboard.
  2. Create a new project and select a dedicated server (or purchase a new one).
  3. Click Add ServiceGit and connect your GitHub account.
  4. Select the repository for your application.

Zeabur automatically detects Node.js, Python, Ruby, Go, Java, PHP, and many other languages — no Procfile required.

💡

If your code only exists in Heroku Git (not on GitHub), push it to a GitHub repository first:

heroku git:clone -a my-app
cd my-app
git remote add github https://github.com/your-username/my-app.git
git push github main

Step 2: Transfer Environment Variables

Heroku stores configuration in Config Vars. Export them and add them to Zeabur:

  1. List your Heroku config vars:

    heroku config -a my-app
  2. In the Zeabur dashboard, click your service and go to the Variables tab.

  3. Add each variable. You can paste them one by one or use the Bulk Edit feature to paste multiple key-value pairs at once.

💡

You do not need to set PORT on Zeabur. Zeabur automatically assigns and injects the port. If your app reads PORT from the environment (as most Heroku apps do), it will work out of the box.

Step 3: Migrate Your Database

If you’re using Heroku Postgres:

  1. Create a backup and download it:

    heroku pg:backups:capture -a my-app
    heroku pg:backups:download -a my-app

    This downloads a latest.dump file in the custom Postgres format.

  2. Create a database on Zeabur: click Add ServiceDatabasePostgreSQL.

  3. Import your data using the Zeabur PostgreSQL connection string:

    pg_restore -d "your-zeabur-postgres-connection-string" --no-owner latest.dump
  4. Update your app’s database URL: set DATABASE_URL in the Zeabur Variables tab. You can use Zeabur’s variable reference ${POSTGRES_URI} to automatically inject the connection string from the database service.

💡

For Heroku Redis, use redis-cli --rdb to export and import into a Zeabur Redis instance.

Step 4: Replace Heroku Add-ons

Heroku add-ons have equivalents on Zeabur or can be connected as external services:

Heroku Add-onZeabur Equivalent
Heroku PostgresDatabase → PostgreSQL
Heroku RedisDatabase → Redis
Heroku SchedulerUse system cron or a scheduled service
Papertrail (logs)Built-in log viewer in dashboard
SendGridConnect via environment variables
CloudinaryConnect via environment variables

For add-ons that are external SaaS products (SendGrid, Cloudinary, etc.), simply keep using them — just transfer the API keys to Zeabur’s Variables tab.

Step 5: Set Up Custom Domains

  1. In the Zeabur dashboard, click your service and go to the Networking tab.
  2. Click Generate Domain for a free .zeabur.app subdomain, or click Custom Domain to add your own.
  3. Update your DNS records:
    • Remove the old Heroku DNS target (CNAME to *.herokuapp.com or Heroku SSL endpoint).
    • Add a CNAME record pointing to the Zeabur-provided target.

Step 6: Verify and Go Live

  1. Trigger a deployment by pushing a commit to your connected repository (or click Redeploy in the dashboard).
  2. Check the Logs tab in Zeabur to confirm your app starts successfully.
  3. Test your application’s key flows (authentication, database reads/writes, API calls).
  4. Once confirmed, update your production DNS to point to Zeabur.

Key Differences: Heroku vs Zeabur

FeatureHerokuZeabur
ConfigurationProcfile + buildpacksAuto-detect (zero config)
Deploymentgit push heroku mainGit push to GitHub (auto-deploy)
ScalingDyno types (Basic, Standard, Performance)Usage-based, auto-scaling
Sleep behaviorEco dynos sleep after 30 min of inactivityNo sleep — always running
Slug size limit500 MB compressedNo slug size limit
DatabasesHeroku Postgres (managed)Database services (PostgreSQL, MySQL, MongoDB, Redis, etc.)
Add-onsHeroku Add-on marketplaceZeabur prebuilt services + external services
PricingPer-dyno monthly pricingUsage-based, pay for what you use
💡

Heroku’s Procfile is not required on Zeabur. Zeabur auto-detects your start command. If you need to customize it, you can set it in the service settings under Build & Deploy.


That’s it. Your Heroku application is now running on Zeabur with no dynos, no Procfiles, and no slug size limits. If you run into any issues, reach out on our community forum.