Skip to content

Menu

E2B logo

E2B

Published

AI Agents

At a glance

What it is
E2B is a platform for running AI-generated code inside isolated cloud sandboxes.
Price from
Paid plans from $150 a month per account Details
Best for
Agents that need to run untrusted generated code; Data analysis features in LLM apps
Official site
e2b.dev
Last checked
November 2026
Watch out for
The Hobby plan caps sessions at 1 hour and 10 concurrent sandboxes.

E2B is a platform for running AI-generated code inside isolated cloud sandboxes. It is built by the E2B team, and the main repository at github.com/e2b-dev/E2B is published under the Apache-2.0 license. The docs describe each sandbox as a Linux VM that is created on demand and controlled through an SDK. The project pitches itself as a secure environment for agents that need real tools.

Developers install the `e2b` package from npm or pip, set an `E2B_API_KEY`, and start a sandbox from code. From there an agent can run shell commands, read and write files, and execute code. A separate Code Interpreter SDK adds a `runCode()` call that keeps variables between calls and can return results such as charts. A Desktop SDK exposes mouse, keyboard, screenshot and screen streaming APIs for computer-use agents. Templates define what a sandbox starts with, and sandboxes can be paused and resumed later.

E2B keeps a cookbook of examples across different LLMs and agent frameworks, and its docs are also exposed through a public MCP server. Teams that cannot use the hosted service can self-host the runtime with Terraform on AWS, Google Cloud or Azure, or on a general Linux machine. The pricing page states plainly that GPU sandboxes are not offered, and the free tier caps sessions at one hour, so it suits short agent tasks better than long jobs on that plan.

Key features

On-demand Linux sandboxes
Each sandbox is an isolated Linux VM started from the SDK and shut down when the task ends.
Python and JS/TS SDKs
The core `e2b` package for both languages creates sandboxes, runs commands and handles files.
Code Interpreter SDK
Adds `runCode()` / `run_code()` with state kept between calls and rich results like charts.
Desktop SDK
Gives agents a virtual desktop with mouse, keyboard, screenshot and streaming APIs.
Pause and resume
Pausing saves both filesystem and memory, and paused sandboxes are kept until you kill them.
Custom templates
Templates define the packages and setup a sandbox starts with.
Self-hosting option
The runtime can be deployed with Terraform on AWS, Google Cloud, Azure or a Linux machine.

Pricing

As of November 2026, E2B's pricing page lists three plans. Hobby has no monthly fee and comes with one-time $100 in usage credits, up to 10 concurrent sandboxes, a 1 hour maximum session length, up to 8 vCPUs per sandbox and 10 GiB of disk. Some accounts must verify with a one-time $5 card payment, which is added as non-refundable usage credit. Pro is a $150 monthly plan fee, plus usage, with 100 concurrent sandboxes, 24 hour sessions, custom CPU and RAM and 20 GiB of disk. Pro+ raises concurrency to 600 sandboxes for $650 a month, and Pro++ to 1,100 for $1,150 a month. Enterprise is custom, with a $3,000 monthly minimum on usage. Usage is billed per second: $0.000014 per vCPU-second and $0.0000045 per GiB-second of RAM. Disk is free.

Best for

  • Agents that need to run untrusted generated code
  • Data analysis features in LLM apps
  • Computer-use agents that need a desktop
  • Teams wanting an Apache-2.0 sandbox they can self-host

Limitations

  • The Hobby plan caps sessions at 1 hour and 10 concurrent sandboxes.
  • The pricing page says E2B does not offer GPU sandboxes.
  • Sandboxes top out at 8 vCPUs and 8 GiB of RAM per the pricing page.
  • The free tier is a one-time $100 credit, not a recurring allowance, and Pro starts at $150 a month before usage.
  • Self-hosting means running Terraform-managed infrastructure yourself.

Verdict

E2B is a focused, open-source answer to the question of where an agent should run its code. The SDKs are simple and the pause and desktop features cover more than basic code execution. The one-hour free sessions, lack of GPUs and the jump to $150 a month for Pro are the main things to weigh.

Sources

Written from the vendor's own site and documentation, checked November 2026. We have no paid relationship that affects what this page says.

How we research: where our facts come from, how often we re-check them, and why no one can pay for a review or a verdict.

Reviews and commentsShow

Reviews

Sign in to leave a review.

Loading reviews…

Comments

Sign in to leave a comment.

Loading comments…