Database-as-a-service providers face an impossible trade-off: Offer serverless flexibility with cold starts that frustrate users, or provide always-on availability with costs that eliminate free tiers. Prisma, the company behind the most popular ORM in the TypeScript ecosystem, partnered with Unikraft to build Prisma Postgres, a managed PostgreSQL service that delivers always-on availability with pay-as-you-go pricing and no cold starts. With Unikraft’s millisecond cloud infrastructure, Prisma achieved what other providers couldn’t: A generous free tier with enterprise-grade performance.
The Opportunity
Prisma believes deploying a database should be as simple as adding a new page in Notion. Yet the database-as-a-service market was forcing developers to make painful compromises. Serverless databases like AWS Aurora promise auto-scaling and pay-as-you-go pricing, but they come with significant drawbacks that impact developer experience and application performance.
As Prisma looked to expand their product suite beyond their industry-leading ORM, they identified several critical challenges in the existing database landscape:
- Cold starts killing user experience: Serverless databases can scale to zero to save costs, but waking up a suspended database creates latencies that frustrate users. Some providers even require manual intervention to restart suspended databases.
- Unsustainable free tiers: Database providers relying on container-based systems or reselling AWS infrastructure struggle with the economics of free tiers. Companies like PlanetScale and Heroku have discontinued their free offerings entirely because of this!
- Infrastructure inefficiency: Traditional approaches (whether building on cloud provider infrastructure or using Kubernetes-based orchestration) carry overhead that gets passed on to customers through higher prices.
- Isolation versus performance trade-offs: Container-based solutions offer weaker isolation than virtual machines, while traditional VMs are too slow and resource-intensive for serverless use cases.
With Unikraft, we can run over 100,000 strongly isolated PostgreSQL instances on a single machine - that density is unheard of in legacy architectures and fundamentally changes the economics of the game. And the Unikraft team is pushing even beyond those boundaries, towards 1 million instances on a single box.
— Søren Bramer Schmidt, Founder & CEO, Prisma.
The Solution
Prisma partnered with Unikraft to build Prisma Postgres on a fundamentally different architecture. Rather than reselling cloud provider infrastructure or building complex container orchestration, they deployed directly on bare metal machines using Unikraft’s millisecond cloud platform.
Unikraft provided the capabilities Prisma needed to solve the serverless database paradox:
- Millisecond scale-to-zero and resume: Unikraft Cloud’s optimized network layer, custom platform controller, and next generation virtualization stack enable databases to scale to zero and resume in single-digit milliseconds, eliminating cold starts while greatly improving cost efficiency.
- Extreme server density: Hundreds of thousands of database instances can run on a single bare metal machine, creating unit economics that allow for generous free tiers.
- Hardware-level isolation: Each PostgreSQL instance runs as a lightweight microVM, providing the security isolation of virtual machines with the performance characteristics of containers.
- Multi-tier snapshotting: Using Snapshots, Unikraft enables Prisma to hibernate databases after inactivity and restore them instantly (eg, < 10 ms) when requests arrive.
Specialized PostgreSQL Images for Maximum Efficiency
Working closely with the Unikraft team, Prisma created optimized PostgreSQL images that contain only what’s needed to run the database (no unused packages, no general-purpose OS overhead). The result: A binary image 5x smaller than standard PostgreSQL containers.
| Configuration | Image Size |
|---|---|
| Original PostgreSQL Image | 280 MB |
| Prisma Postgres on Unikraft Cloud | 61 MB (78% reduction) |
Unikraft enables us to achieve unmatched server density, unlocking new and differentiated pricing and performance. The Unikraft Cloud orchestration is simple and effective at managing hundreds of thousands of VMs per host. We’re able to provision Postgres instances faster than other providers can resume from standby.
— Tyler Hogarth, Head of Engineering
The Outcome
Prisma Postgres represents a fundamental shift in what’s possible for managed database services. By building on Unikraft’s millisecond infrastructure, Prisma delivered capabilities that were previously mutually exclusive:
- Zero cold starts with always-on availability: Databases resume from hibernation in single-digit milliseconds, providing the cost benefits of scale-to-zero without the user experience penalties.
- Sustainable free tier economics: The superior server density enabled by Unikraft Cloud allows Prisma to offer a generous free tier that other providers cannot match. 100K+ databases per bare metal instance with around 2 orders of magnitude cost saving vs. traditional solutions.
- True pay-as-you-go pricing: Charging only for queries, storage, and egress but no fixed compute costs. Developers pay for what they use, not for idle resources.
- Enterprise-grade isolation: Hardware-level isolation via microVMs provides security guarantees that container-based solutions cannot offer.
- Rapid time to market: Unikraft enabled Prisma to go take Prisma Postgres from PoC, to Early Access and eventually General Availability in just a few months.
| Metric | Result |
|---|---|
| Cold start time | Single-digit milliseconds |
| Image size reduction | 78% smaller (From 280 MB to 61 MB) |
| Instances per machine | Hundreds of Thousands |
| Infrastructure cost savings | 2 orders of magnitude (99%) |
Prisma Postgres shows how a modern database should be built in 2025, delivering on the usability, performance and security promises that hyperscalers made, but failed to keep. This is possible thanks to cloud infra that was designed from the ground up for millisecond responsiveness and extreme efficiency. With Unikraft Cloud, Prisma has delivered a radical new product, the next leap in serverless databases.
Learn how Unikraft Cloud can help you build the impossible. Book call with our CEO Felipe