AWS Lambda MicroVMs: AWS Turned Its Best-Kept Infrastructure Secret Into a Product
If you pay E2B or Modal for CPU-only sandboxes and live in AWS, run the cost comparison now.
For eight years, Firecracker microVMs were the machinery behind AWS Lambda: invisible, undocumented at the API level, and the reason a trillion-invocation multi-tenant platform could put mutually distrusting customers on the same bare-metal host without incident. You benefited from microVMs; you never touched one.
That changed on June 22, 2026. Lambda MicroVMs is a new serverless compute primitive, a separate resource type inside Lambda with its own API, that hands you a dedicated, hardware-isolated, stateful virtual machine per user, per session, or per job, launched from a snapshot in near-real time. AWS built it for one dominant workload: running code your developers didn't write, whether it came from an end user or an LLM.
This is not an incremental Lambda feature. It's AWS entering the "sandbox-as-a-service" market that startups like E2B, Modal, and Fly.io built on top of Firecracker while AWS kept the technology to itself.
What actually launched
Lambda MicroVMs inverts the Lambda Functions model. Functions are stateless, event-driven, and capped at 15 minutes. MicroVMs are stateful, session-oriented, and directly addressable.
The workflow has three stages:
- Build an image. You package an application (say, a Flask app or a code-execution agent) with a Dockerfile and upload the artifact to S3. Lambda runs the Dockerfile, boots the application once, then uses Firecracker to snapshot the running memory and disk state. That frozen, pre-initialised state is your "MicroVM Image."
- Launch sessions. Your control plane calls
run-microvmWith the image ARN and an idle policy. Lambda restores a fresh microVM from the snapshot, with the application already initialised and the process already running, and returns a dedicated HTTPS endpoint for that session. Clients talk to it directly over HTTP/2, gRPC, or WebSockets. No load balancers, no VPC plumbing, no fleet management.
- Suspend and resume. When the session goes idle past your configured window, Lambda suspends the microVM, snapshotting memory and disk. When traffic returns, it resumes with all state intact - variables in memory, files on disk, processes mid-flight.
The hard numbers at launch:
- Resources: up to 16 vCPUs, 32 GB memory, 32 GB disk per microVM
- Session lifetime: up to 8 hours of total runtime
- Architecture: ARM64 (Graviton) only
- Regions: N. Virginia, Ohio, Oregon, Tokyo, Ireland
- Isolation: one dedicated microVM per session, with no shared kernel and no shared resources between tenants
- Privileges: elevated OS privileges inside the guest are supported (security scanners were an explicit design target)
- Pricing: you pay for baseline compute while the microVM runs, plus the active duration of any resources consumed above baseline
- Tooling: Lambda console, CloudFormation, CDK, and the Agent Toolkit for AWS
The snapshot is the whole trick
The headline capability, "near-instant launch of a multi-gigabyte, fully initialised environment," is not new engineering. It's the productisation of a decade of internal work.
Firecracker, open-sourced in 2018, is a minimal virtual machine monitor written in Rust on top of KVM. It strips the device model to virtio essentials, which is how it boots a microVM in roughly 125 ms, holds per-VM overhead under 5 MiB, and creates up to 150 microVMs per second on a single host. That's the density math that makes per-session VMs economically sane in the first place.
Boot speed alone doesn't get you "instant," though; application initialisation does. Loading a Python interpreter, importing pandas, warming a JIT: that's seconds, not milliseconds. AWS's answer, developed for Lambda SnapStart (Java in 2022, Python and .NET at re:Invent 2024), is to do initialisation exactly once, snapshot the result, and clone it. Lambda MicroVMs generalises that mechanism from "resume a function's init phase" to "resume an entire running application, repeatedly, per tenant."
Cloning running VMs sounds simple and is not. Every clone wakes up believing it's the original, which breaks randomness (identical RNG state across clones is a cryptographic disaster), breaks clocks (the guest thinks no time has passed), and breaks anything holding a network connection. The Firecracker release history over the past year reads like a checklist of these exact problems being ground down: VMGenID fixes so guests re-seed entropy correctly on restore, a kvm-clock fix in v1.16 (June 2026) stopping the monotonic clock from jumping by the wall-clock time elapsed since the snapshot, and a new VMClock device in v1.15 (March 2026) that lets guest userspace, not just the kernel, get notified that it's running from a restored snapshot, so applications can invalidate cached tokens, UUIDs, and TLS session state. That last one is the tell: you only build userspace snapshot-awareness if you're about to let customers build applications on top of snapshot restore.
Why now: AI ate the roadmap
The launch messaging barely pretends otherwise. The target workloads are AI coding agents that iteratively execute LLM-generated code while retaining context, reinforcement-learning pipelines that spin up thousands of short-lived environments to evaluate code paths, per-user code interpreters, interactive cloud IDEs, and vulnerability scanners.
The common thread is untrusted code, and containers are the wrong boundary for it. Containers share the host kernel; a kernel exploit in one tenant's sandbox is a breach of every tenant on the box. That's an acceptable risk when you wrote the code, and it passed CI. It's an unacceptable one when the code was written 400 ms ago by a language model prompted by an anonymous user. MicroVMs put a hardware virtualisation boundary (KVM) plus Firecracker's jailer and seccomp filtering between tenants, with a per-VM guest kernel.
AWS already validated the pattern internally. Bedrock AgentCore's runtime gives every agent session its own microVM for up to 8 hours of tool calls and LLM interactions, then destroys the VM and everything in it when the session ends, as Firecracker co-creator Marc Brooker described in September 2025. Lambda MicroVMs is the same primitive with your name on the API. AWS has even published a reference implementation running one MicroVM per Claude agent session, which tells you precisely which market they're chasing: the sandboxing layer under agentic AI products, currently owned by E2B, Modal, Daytona, Northflank, and self-hosted Firecracker/Cloud Hypervisor stacks.
Where it fits, and where it doesn't
Use Lambda MicroVMs when you're multi-tenant, the code is untrusted, sessions are interactive or stateful, and you don't want to operate a bare-metal Firecracker fleet. The suspend/resume economics are the killer feature for interactive products: you stop paying full freight the moment the user walks away, without losing their session.
Don't use it when:
- You need x86. ARM64 only at launch. Binary dependencies without ARM builds mean rebuild work or a hard blocker.
- You need GPUs. Firecracker still has no production GPU passthrough. Upstream added a virtio PCI transport in 2025, and PCI device hotplug shipped as a developer preview in v1.16 (block, pmem, and net devices only). The GPU/PCIe passthrough effort remains a community-driven project, explicitly scoped to exclude GPU snapshotting in its first iteration, and snapshots are the entire premise of this product. AI sandboxes that need CUDA still belong on Modal, or on EC2/EKS with your own isolation story.
- Sessions outlive 8 hours, or the state must survive the session. Durable state belongs in S3/EFS/a database; the microVM's disk and memory are ephemeral by design.
- The workload is a trusted, long-running service. That's Fargate or ECS, at lower cost.
- It's ordinary event-driven glue. Plain Lambda Functions remain cheaper and simpler.
Also, be honest about the ownership line. AWS runs the virtualisation; you still own authentication in front of those per-session HTTPS endpoints, secrets injection, the image build pipeline, network policy, monitoring, and janitorial cleanup of abandoned sessions. "Serverless" here means no hypervisor operations, not no platform work.
And note what's new is also newly attacked: the PCI transport Firecracker added in 2025 already produced CVE-2026-5747 (improper virtio device initialisation sequencing, patched in v1.15.1/v1.14.4, April 2026). Minimal attack surface was Firecracker's founding argument; every added device type spends some of that budget. AWS knows this; it's why features like PCI hotplug and balloon-free page reporting ship as developer previews. But if you're betting a security product on this stack, track the CVE feed.
What the upstream roadmap signals
Firecracker's 2025-2026 releases sketch where the managed product goes next. v1.14 (December 2025) added memory hot-plugging via virtio-mem and virtio-pmem support, the plumbing for resizable sandboxes that grow and shrink under live workloads instead of being fixed-size at launch. v1.15 added the snapshot-safety VMClock work. v1.16 added PCI device hotplug in preview, letting you attach and detach devices on a running microVM, the architectural prerequisite for any eventual accelerator story.
Read together: denser packing, elastic per-session resources, snapshot-aware applications, and a slow march toward richer device models. The eight-year pattern is that whatever ships in Firecracker's release notes shows up in an AWS product two to four quarters later. This time the product shipped three weeks after the release.
Bottom line
- Lambda MicroVMs (GA June 22, 2026) is AWS selling its internal isolation primitive directly: per-session Firecracker VMs, snapshot-launched, stateful up to 8 hours, addressable over HTTPS/gRPC/WebSockets.
- It exists because AI-generated code made "sandbox untrusted code, per tenant, with fast interactive startup" a mainstream requirement containers can't safely meet.
- The differentiator isn't boot speed; it's snapshot/suspend/resume of fully initialized applications, a problem AWS spent years de-risking via SnapStart and upstream Firecracker fixes.
- Hard limits today: ARM64 only, no GPUs, 16 vCPU / 32 GB / 32 GB ceilings, 8-hour sessions, five regions.
- If you're currently paying E2B or Modal for CPU-only sandboxes and you live in AWS, run the pricing comparison this quarter. If you need GPUs or x86, nothing changed for you yet.
Enjoyed reading this content? Let the author know!
Your likes, comments, shares, and saves help creators reach more builders.
Loading recommendations
Loading article