E2B vs Modal

E2B gives each agent a Firecracker microVM that can pause with its memory and wake on the next request. Modal gives you short-lived gVisor sandboxes inside a bigger AI cloud, with GPUs from T4 to B300.

The companies and products

E2B

E2B calls itself the AI agent cloud: an API that gives each agent session its own isolated Linux machine.

Every E2B sandbox is a Firecracker microVM that boots from a snapshot, so it starts fast and can be paused and resumed with its memory. You build custom sandboxes from templates based on a Docker image, and drive them from Python or JavaScript SDKs. It is built for teams that run many short code, data or agent jobs, and its runtime is open source.

Modal

Modal is a serverless cloud for AI work: inference, training, batch jobs and sandboxed code, all driven from Python, TypeScript or Go code.

Modal Sandboxes are containers you create from code, run commands in, and then terminate. By default they run under gVisor, a user-space kernel from Google; since October 2026 you can also pick a VM runtime with its own Linux kernel for Docker and FUSE (Battleships tracks that as a separate card, Modal VM Sandboxes). It suits teams that already run models on Modal and want short-lived, scalable code execution next to their GPUs.

Which use cases each one fits

For each use case, Battleships prices every sandbox provider on the same workload and sorts them from the cheapest monthly bill up. “16th cheapest of 367” means 15 of the other 366 providers run that workload, with every feature it needs, for less. “With limits” means the provider runs it but misses something, so it is listed after every full match. Open a use case for its whole ranking and what each provider misses.

Use case and its workloadE2B: price rankModal: price rankboat: price rank
Software factory
100 at once · 4 vCPU / 8 GB · 2,200 sessions of 8 h a month
16th cheapest of 367
$4,143 a month
Can't run it3rd cheapest of 367
$634 a month
Always-on AI employees
50 machines 24/7 · 2 vCPU / 4 GB
Both cap a session at 24 hours, so an always-on assistant has to be paused or restarted; boat ranks 5th with no session cap on paid plans.
51st of 366, with limits
$5,348 a month
196th of 366, with limits
$1,924 a month
5th cheapest of 366
$657 a month
Code interpreter bursts
100 at once · 1 vCPU / 2 GB · 200,000 sessions of 1 min a month
Both fit short code runs; Modal ranks 19th against E2B's 37th, while E2B adds memory pause and wake on request.
37th cheapest of 345
$421 a month
19th cheapest of 345
$181 a month
186th of 345, with limits
$2,000 a month
Sandboxes for your users
300 at once · 2 vCPU / 4 GB · 30,000 sessions of 23 min a month
Both fit sandboxes for your users; E2B can wake a paused one on the next request, and boat ranks 1st with stops that keep the disk.
23rd cheapest of 361
$2,354 a month
11th cheapest of 361
$811 a month
Cheapest of 361
$209 a month
RL rollouts
1,000 at once · 2 vCPU / 4 GB · 1,000,000 sessions of 3 min a month
E2B ranks 2nd and Modal 5th: both are built for many short rollouts, and E2B can fork a running sandbox with its memory.
2nd cheapest of 360
$9,384 a month
5th cheapest of 360
$19,038 a month
34th of 360, with limits
$2,000 a month
Agent evals
250 at once · 4 vCPU / 8 GB · 15,000 sessions of 20 min a month
78th cheapest of 364
$1,975 a month
59th cheapest of 364
$1,244 a month
10th cheapest of 364
$200 a month
CI runners
40 at once · 8 vCPU / 16 GB · 6,000 sessions of 12 min a month
E2B runs Docker in every sandbox while Modal needs its VM runtime, but neither has nested virtualization for Android or VM builds; boat ranks 4th.
337th of 377, with limits
$1,429 a month
126th cheapest of 377
$1,793 a month
4th cheapest of 377
$86 a month
24/7 dev boxes
1 machine 24/7 · 4 vCPU / 8 GB
Neither keeps a dev box running all month, and Modal also resets the root disk when a sandbox ends; boat ranks 18th.
192nd of 368, with limits
$358 a month
138th of 368, with limits
$23 a month
18th cheapest of 368
$26 a month
Computer-use agents
50 at once · 4 vCPU / 8 GB · 20,000 sessions of 15 min a month
E2B has a Linux desktop for computer use and Modal only has a VNC example you set up yourself; boat ranks 6th with a 60fps desktop.
32nd cheapest of 369
$1,342 a month
98th of 369, with limits
$183 a month
6th cheapest of 369
$200 a month
Browser-use agents
50 at once · 2 vCPU / 4 GB · 30,000 sessions of 10 min a month
100th of 367, with limits
$746 a month
177th of 367, with limits
$136 a month
7th cheapest of 367
$200 a month
Scraping & bots (startup scale)
50 at once · 1 vCPU / 2 GB · 100,000 sessions of 3 min a month
57th cheapest of 346
$554 a month
267th of 346, with limits
$394 a month
6th cheapest of 346
$90 a month
Mass scraping & bots (undetectable)
1,000 at once · 1 vCPU / 2 GB · 3,000,000 sessions of 2 min a month
227th of 338, with limits
$9,223 a month
223rd of 338, with limits
$8,795 a month
71st of 338, with limits
$1,800 a month
Parallel red teaming
200 at once · 2 vCPU / 4 GB · 5,000 sessions of 30 min a month
11th cheapest of 360
$1,043 a month
Can't run it2nd cheapest of 360
$200 a month
GPU eval jobs
10 at once · 8 vCPU / 32 GB · 500 sessions of 30 min a month
Modal has GPUs from T4 to B300 and neither E2B nor boat has any, so Modal is the pick here.
Can't run it19th cheapest of 98
$1,187 a month
Can't run it
macOS agents
5 at once · 4 vCPU / 8 GB · 1,000 sessions of 20 min a month
Can't run itCan't run itCan't run it

Key features

FeatureE2BModalboat
IsolationFirecracker microVM with its own kernelgVisor user-space kernel by default; VM runtime with its own kernel availableFull VM with its own kernel on dedicated AMD Ryzen 9 9950X hosts
CPU benchmark (4 vCPU / 8 GB)12.61 runs/s12.79 runs/s (default sandbox)26.69 runs/s
Docker insideYesOnly with the VM runtimeYes, in every sandbox
Nested virtualizationNot supportedVM runtime only, Team and Enterprise plans, on requestYes, /dev/kvm for Android emulators and VMs
Longest session1 hour on Hobby, 24 hours on Pro; pausing resets the clock24 hours (default 5 minutes)No cap on paid plans; you set the time to live
Pause and resumePauses with memory and disk; resumes in about a second with processes runningNo paused state; a finished sandbox is gone, only Volumes keep filesDisk saved every minute and on stop; a stopped sandbox costs nothing and boots again
Wake on requestYes, a paused sandbox resumes on the next HTTP request or SDK callNoNo, a stopped sandbox is started by API
ForkFork a running sandbox with its memory, up to 20 copies per callSnapshot the filesystem into an image and boot new sandboxes from itFork a running sandbox with its disk, without stopping it
GPUsNoneT4 to B300; 10 at once on Starter, 50 on TeamNone
Desktop and computer useLinux desktop for computer useNot offered; an example shows how to set up VNC yourself60fps desktop, Chromium and computer-use API built in
Inbound accessHTTPS URL per port, public by default unless you turn on a tokenEncrypted and raw TCP tunnels, connect tokens, inbound IP allowlistHTTPS URLs for up to 50 ports, token-protected by default, plus raw TCP and a dedicated IP
Keeping API keys out of the sandboxSecrets injected into outbound HTTPS headers (private beta)Secrets are environment variables, or you run your own proxy in a sidecarCredentials proxy for model providers and any HTTPS API; switch a credential to another account when credits run out
RegionsUS by default; EU and APAC on Pro and above, enabled by supportUS, EU and Asia-Pacific plus narrower regions; pinning costs 1.15x to 1.75xEU only (Germany, Finland, France)
Self-hostingOpen-source runtime, plus bring your own cloud on EnterpriseNoNo
Every feature Battleships tracks (43)
FeatureE2BModalboat
Full VM (own kernel)YesNoYes
Docker insideYesNoYes
Nested virtualizationNoNoYes
RootYesYesYes
SystemdYesYesYes
Desktop GUIYesNoYes
BrowserYesNoYes
Computer-use APIYesNoYes
SSHYesYesYes
Persistent diskYesYesYes
Pause/resumeYesNoYes
Automatic snapshotsYesNoYes
Fork/cloneYesYesYes
Live fork (no pause)YesNoYes
Memory forkYesYesNo
Custom image (Docker or snapshot)YesYesYes
≥24 h sessionsYesYesYes
Idle auto-stopYesYesNo
Wake on requestYesNoNo
HTTPS preview URLsYesYesYes
Raw TCP inboundNoYesYes
Public IPv4NoNoNo
Egress allowlistYesYesNo
Secret proxyYesNoYes
Secret proxy for any APIYesNoYes
Preinstalled agentsYesNoYes
Agent harness APINoNoYes
MCP serverYesNoNo
GPUNoYesNo
WindowsNoNoNo
Arm64NoNoNo
Self-hostingYesNoNo
BYOCYesNoNo
Open sourceYesNoNo
Scoped API keysNot publishedNot publishedYes
Spend limitsYesNot publishedYes
Usage per sandbox (API)NoNot publishedYes
Audit logsNot publishedYesNo
SSONoYesNo
SOC 2YesYesNo
HIPAAYesYesNo
EU data residencyYesYesYes
Zero data retentionNot publishedNot publishedYes

Performance

E2B12.61 runs/s
Modal12.79 runs/s
boat26.69 runs/s

All three ran the hpc-sandbox-benchmarks Node.js build-and-test loop at 4 vCPU / 8 GB in the same run on 29 September 2026. E2B did 12.61 runs per second and Modal's default gVisor sandbox 12.79, so the two are close. boat did 26.69, about twice the CPU work of either.

Node.js build-and-test loop at 4 vCPU / 8 GB, higher is better. Measured with the open hpc-sandbox-benchmarks suite. Modal measured on: Sandbox (gVisor), request = size, any region.

Pricing in five scenarios

Each bill is priced from the providers' public price lists by the open Battleships engine, with the cheapest plan that runs the scenario.

ScenarioE2B, a monthModal, a monthboat, a month
One coding agent, workdays
4 vCPU / 8 GB, 50 GB disk, 8 hours a day, 22 days a month, files kept between days
$202 · Pro$15 · Starter · with limits$20 · $20/mo
One agent that never stops
4 vCPU / 8 GB, 50 GB disk, running 24/7 all month
$368 · Pro · with limits$178 · Starter · with limits$26 · $20/mo
50 agents in parallel
50 machines of 4 vCPU / 8 GB at once, 8-hour sessions, 1,100 sessions a month, Docker inside
$2,773 · Pro$2,229 · Starter · with limits$317 · $20/mo × 3 seats
Sandboxes for your users
2 vCPU / 4 GB, 30,000 sessions of 10 minutes a month, up to 300 at once
$1,395 · Pro+ (600 concurrent)$792 · Team$200 · $100/mo × 2 seats
1,000 short jobs at once
2 vCPU / 4 GB, 1,000 at once, 3 minutes each, 200,000 jobs a month
$2,797 · Pro++ (1,100 concurrent)$3,193 · Team · with limits$2,000 · $2000/mo · with limits

E2B: E2B bills per second for the vCPU and RAM you set, idle time included, until you pause or kill the sandbox. Pro costs $150 a month for higher limits with no usage credit, and more concurrency costs $500 a month per 500 slots.

Modal: Modal bills by the second for whichever is higher, the CPU and memory you request or what you use, until the sandbox is terminated. Starter is free with $30 of monthly credit, Team is $250 a month with $100 of credit, and egress above the free allowance costs $0.04 per GiB.

Modal: boat plans start at $20 a month and the whole fee is usage credit. You pay per second while a sandbox runs, and a stopped sandbox costs nothing and keeps its disk.

Limits in those scenarios

Both E2B Pro and Modal cap a session at 24 hours, so neither fits the always-on agent. Modal also wipes the root disk when a sandbox ends and needs its VM runtime for Docker, which is why it misses the workday and 50-agent scenarios even though it costs less there. For 1,000 short jobs at once, E2B Pro++ fits and only queues bursts above 300 starts a minute, while Modal's Team tier runs on shared vCPUs that other tenants can slow down. boat fits the first four scenarios but not that burst, because its start limits per hour and per day are too low.

ScenarioE2BModalboat
One coding agent, workdays
  • disk beyond 20 GiB: price unknown
  • egress price not published
  • files survive a stop only in Volumes: packages installed elsewhere reset
None that bite
One agent that never stops
  • Pro: sessions capped at 24 h
  • disk beyond 20 GiB: price unknown
  • egress price not published
  • Starter: sessions capped at 24 h
  • files survive a stop only in Volumes: packages installed elsewhere reset
None that bite
50 agents in parallel
  • egress price not published
  • missing Docker inside
  • files survive a stop only in Volumes: packages installed elsewhere reset
None that bite
Sandboxes for your users
  • egress price not published
None that biteNone that bite
1,000 short jobs at once
  • egress price not published
  • bursts above 300 starts/min are queued (a burst of 333 takes ~2 min to start)
  • shared vCPUs on this tier (Modal sells dedicated cores separately as “Sandbox (gVisor), request = size, any region”): heavy, sustained CPU use can be slowed by other tenants
  • max 2,400 starts/day (needs ~6,667)
  • max 600 starts/hour (needs ~1,000)
  • bursts above 90 starts/min are queued (a burst of 333 takes ~4 min to start)

Which one should you use?

Use E2B when

your agents run short jobs that pause between requests, need Docker in every sandbox, or you want an open-source runtime you can host.

  • Memory pause and wake on request. For jobs that sleep between requests: a paused E2B sandbox comes back in about a second with its processes still running.
  • Docker in the default sandbox. Every E2B sandbox is a microVM that runs Docker, while Modal needs its separate VM runtime for that.
  • Open source and your own cloud. E2B's runtime is Apache-2.0, and Enterprise customers can run it in their own AWS, GCP or Azure account.

Use Modal when

your sandboxes need GPUs, sit next to models you already run on Modal, or come in huge bursts across many regions.

  • GPUs on the same platform. If your agent trains or runs models, Modal rents GPUs from T4 to B300 next to its sandboxes.
  • More regions to pick from. Modal runs in the US, EU and Asia-Pacific and lets you pin a sandbox to a region, for a higher rate.
  • Very large bursts. Modal's Team plan runs up to 5,000 containers at once, which suits huge waves of short jobs.

Where boat fits

E2B and Modal both shine at short jobs that start fast and end soon. If your agents work for hours or days, with installs, builds, Docker, emulators and a desktop, boat gives each one a full, faster VM that keeps its disk and is never cut off.

No 24-hour cutoff

E2B Pro and Modal both end a session at 24 hours. On E2B your code has to pause and resume the sandbox; on Modal the root disk is gone, so files survive only if you wrote them to a Volume.

About twice the CPU work

On the same benchmark at 4 vCPU / 8 GB, boat did 26.69 runs per second, E2B 12.61 and Modal's default sandbox 12.79. Every install, build and test waits about twice as long on either, and you pay for the wait.

A full machine with agents built in

Neither has /dev/kvm for Android emulators, Modal's default sandbox has no Docker, and on both you wire up the agent harness yourself. boat ships Claude Code, Codex and others, a 60fps desktop, and a proxy that keeps real API keys out.

Use boat when your agents work for hours or days: installs, builds, tests, Docker, emulators and a desktop, on a fast machine that keeps its disk and never cuts them off. Compare it one to one: boat vs E2B and boat vs Modal.

Questions people ask

Is E2B cheaper than Modal?

Usually not. One always-on agent costs $368 a month on E2B against $178 on Modal, and sandboxes for your users cost $1,395 against $792. For 1,000 short jobs at once E2B is cheaper, $2,797 against $3,193, and boat costs less than E2B in every scenario and less than Modal in all but one agent on workdays.

Which is faster, E2B or Modal?

On the hpc-sandbox-benchmarks CPU test at 4 vCPU / 8 GB, E2B did 12.61 runs per second and Modal's default sandbox 12.79, so they are about even. boat did 26.69 in the same run.

Can E2B and Modal run Docker?

E2B runs Docker inside its sandboxes. Modal's default gVisor sandbox does not document Docker; you need its VM runtime. Every boat sandbox runs Docker, and also has /dev/kvm for emulators, which neither of the others offers by default.

How long can a sandbox run on E2B and Modal?

E2B allows 1 hour on Hobby and 24 hours on Pro, and pausing resets the clock. Modal's default timeout is 5 minutes and its maximum is 24 hours. boat has no session cap on paid plans.

Does E2B or Modal have GPUs?

Modal does, from T4 up to B300, on its gVisor runtime. E2B is CPU only, and so is boat.

Can I pause a sandbox and come back later?

E2B can pause a sandbox with its memory and resume it in about a second. Modal has no paused state, so only files in a Volume survive. boat saves the disk every minute and on stop, and a stopped sandbox costs nothing.

Try boat

Install the CLI, then run boat new.

7-day free trial

More comparisons