The Heroku Exodus: Why Everyone is Leaving
Heroku was revolutionary in 2011. It made deployment trivial: git push heroku main. But Salesforce’s neglect has turned it into a liability:
- Price: Dyno costs have tripled. A simple web app that cost $50/month now costs $150+.
- Stagnation: No meaningful new features since 2018. The platform is frozen in time.
- Lock-In: Heroku Add-ons are proprietary. Migrating away is painful by design.
Kubernetes is where the industry has moved. It’s not “easy,” but it’s flexible, cost-effective, and future-proof. The challenge is doing the migration without destroying your team’s velocity.
Technical Deep Dive
1. Preserving the 12-Factor App Model
Heroku enforced the 12-Factor App methodology:
- Stateless Processes: Pods in K8s are naturally stateless.
- Config via Environment Variables: K8s ConfigMaps and Secrets replace Heroku Config Vars.
- Port Binding: Your app listens on a port, K8s Services route traffic to it.
- Logs as Event Streams: K8s stdout/stderr logs are collected by Fluentd/Fluent Bit.
The Migration is Conceptually Simple: Your Heroku app already follows K8s patterns. The hard part is the tooling around it.
2. From Buildpacks to Container Images
Heroku uses Buildpacks to automatically detect your language and build your app. Kubernetes uses Container Images.
Migration Path:
- Use Cloud Native Buildpacks (the open-source evolution of Heroku Buildpacks) to build OCI images.
- Push images to a registry (Docker Hub, ECR, GCR).
- Deploy to K8s using a Deployment manifest.
3. Replacing Heroku Add-ons
Heroku Add-ons (Postgres, Redis, etc.) are just managed services. You have choices:
- Cloud-Managed: Use AWS RDS (Postgres), ElastiCache (Redis), etc.
- K8s Operators: Run Postgres or Redis inside K8s using operators (not recommended for production databases).
- Hybrid: Keep databases cloud-managed, run stateless apps in K8s.
Architecture Transformation
graph TB
subgraph "Heroku (Before)"
A[Git Push] --> B[Heroku Build]
B --> C[Dyno Deploy]
C --> D[Heroku Postgres Add-on]
C --> E[Heroku Redis Add-on]
end
subgraph "Kubernetes (After)"
F[Git Push] --> G[CI/CD: GitHub Actions]
G --> H[Build Container: Buildpacks]
H --> I[Push to Registry: ECR]
I --> J[Deploy: ArgoCD/Flux]
J --> K[EKS Cluster]
K --> L[RDS Postgres]
K --> M[ElastiCache Redis]
end
A -.Migration.-> F
style K fill:#326ce5,stroke:#fff,stroke-width:2px,color:#fff
style C fill:#430098,stroke:#fff,stroke-width:2px,color:#fff
How to Choose a Heroku to Kubernetes Migration Partner
If you are obsessed with Developer Experience: Loft Labs. They built vCluster and DevPod specifically to make K8s feel like a managed platform. Your developers won’t riot.
If you need 24/7 “Heroku-like” support: Dysnix. They offer managed K8s services that feel like Heroku’s hands-off experience. You don’t want to be on-call for cluster failures.
If you want to learn K8s deeply: Container Solutions. They don’t just migrate you—they train your team to become cloud-native experts. You end up owning the platform, not renting it.
If you are on AWS: Caylent. They are AWS Premier Partners and specialize in EKS migrations with deep integration into AWS services (IAM, VPC, ALB).
If cost control is critical: Kubecost. They provide real-time cost visibility. You’ll know exactly what each namespace costs, down to the pod level.
When to Hire Migration Services
1. The Price Shock
Heroku sent you a renewal notice. Your bill is now 3x what it was last year. You’re spending $200k/year on dynos when AWS EKS would cost $60k. Trigger: “Our CFO said ‘find an alternative or we cut the budget.‘“
2. The Feature Roadblock
You need advanced networking (VPC peering, private endpoints, custom CNI) or compliance features (PCI-DSS, HIPAA) that Heroku cannot provide. Trigger: “Heroku doesn’t support our security requirements.”
3. The Scalability Wall
You’re hitting Heroku’s limits. You need custom autoscaling logic, GPU workloads, or multi-region active-active deployments. Trigger: “We need to scale beyond what Heroku can offer.”
Total Cost of Ownership: Heroku vs. Kubernetes
| Line Item | Heroku (Annual) | Kubernetes on AWS (Annual) |
|---|---|---|
| Compute | $120k (Performance Dynos) | $40k (EKS: t3.medium Spot instances) |
| Database | $50k (Heroku Postgres Premium) | $25k (RDS: db.t3.large with Reserved Instances) |
| Add-Ons (Redis, etc.) | $20k | $8k (ElastiCache) |
| Ops/Management | $0 (Included) | $30k (Tooling: Datadog, ArgoCD, etc.) |
| Labor | $0 | $50k (0.5 FTE DevOps Engineer) |
| Total | $190k | $153k |
Savings: ~$37k/year (~20%)
But: If you overprovision K8s or ignore cost controls, you can easily spend $250k+. This is why Kubecost is essential.
Typical Migration Roadmap
Phase 1: Proof of Concept (Weeks 1-2)
- Pick the simplest app (e.g., a background worker, not the main web app).
- Containerize it using Cloud Native Buildpacks.
- Deploy to a staging K8s cluster.
- Validate logs, metrics, and alerts work.
Phase 2: Developer Experience Setup (Weeks 3-4)
- Install Tilt or Skaffold for local K8s dev.
- Set up GitOps (ArgoCD or Flux) for automated deployments.
- Configure Horizontal Pod Autoscaler (HPA).
- (Optional) Implement an Internal Developer Platform (IDP) like Backstage or Port.dev to give devs a self-service catalog.
Phase 3: Production Migration (Months 2-4)
- Migrate one service at a time (blue/green or canary).
- Use DNS-based traffic shifting to gradually move users.
- Monitor costs with Kubecost.
- Decommission Heroku dynos as apps migrate.
Phase 4: Optimization (Month 5+)
- Right-size instances based on actual usage.
- Implement Cluster Autoscaler and Karpenter (for AWS).
- Add Spot instances for non-critical workloads.
FAQ
Do we need to hire a full-time Kubernetes expert?
Not immediately. A migration partner can set up the platform, train your team, and then hand it off. You’ll eventually need someone with K8s skills, but they don’t need to be a CNCF-certified expert on day one.
What about managed K8s services like GKE Autopilot or Fargate?
They reduce operational overhead but come with tradeoffs:
- GKE Autopilot: Excellent for teams wanting “Heroku-like” simplicity. Google manages nodes, autoscaling, and security. Cost: ~20% premium over DIY GKE, but you eliminate 0.5-1 FTE of ops work. Verdict: Best for small teams (<10 engineers).
- AWS Fargate for EKS: Serverless pods. No node management, pay-per-pod. Great for stateless workloads, but 30-50% more expensive than EC2 at scale. Verdict: Use for bursty/unpredictable workloads, not 24/7 production.
Can we migrate our Heroku Postgres database?
Yes. Use pg_dump and pg_restore to move data to AWS RDS, Google Cloud SQL, or a self-managed Postgres instance. Downtime can be minimized using streaming replication or tools like AWS DMS (Database Migration Service).