In short.
E2B’s sandbox lifecycle guide teaches developers building AI agents how to manage isolated Linux VMs, but does not provide complete setup or persistence instructions. It demonstrates creation, timeout resets, information retrieval and shutdown in JavaScript/TypeScript and Python. JavaScript timeouts use milliseconds; Python uses seconds. The page states continuous runtime limits of one hour for Hobby and 24 hours for Pro, with pause/resume described as the route to longer workloads. Prices are unknown, and no examples were executed.
Researched and written by an AI model and checked by a second AI model. How it works
Coverage includes the complete page at [https://docs.e2b.dev/sandbox.md], including the continuous-runtime notice, timeout-unit warnings, lifecycle descriptions and all JavaScript/TypeScript and Python examples. Linked pages, including the documentation index, persistence guide and sandbox-lifetime/stream-connections guidance, are excluded. No code or SDK calls were executed. Actual lifecycle behavior, persistence, isolation, performance and billing were not tested.
The overview
Identity
Sandbox lifecycle is an E2B documentation guide about controlling an isolated Linux VM used by an agent. The original page is [https://docs.e2b.dev/sandbox.md]. Its concrete examples use the Sandbox class from the JavaScript/TypeScript and Python e2b libraries.
Assessment
The guide is useful as a focused reference for developers who already have E2B available and need to control sandbox lifetime. Paired language examples explain the main calls and a consequential difference in timeout units. It is insufficient as a standalone introduction because installation, authentication, connection and persistence configuration are absent. Execution reliability, performance and isolation strength were not assessed.
Users
The strongest audience is developers integrating Linux environments into AI-agent applications. The suggested pattern of resetting a timeout when a user interacts with an application is relevant to interactive sessions. Beginners can follow the lifecycle concepts, but will need separate onboarding instructions before using the snippets.
Capabilities
The examples demonstrate creating a sandbox, changing its timeout while running, retrieving information and shutting it down immediately. Information examples include identifiers, template, metadata, timestamps, state, CPU count, memory and lifecycle settings.
The page also describes connecting, pausing, resuming and automatically pausing at timeout, but does not provide calls or configuration examples for those operations.
Using it
Requirements
Using the snippets requires a JavaScript/TypeScript or Python environment with the corresponding e2b library available. The JavaScript examples use await. Installation commands, authentication, account prerequisites, supported language versions and required SDK versions are not specified on this page.
Mechanism
Creation assigns a timeout to the sandbox. Calling setTimeout in JavaScript or set_timeout in Python replaces that timeout with a new duration measured from the call; it does not add that duration to the existing deadline. JavaScript uses milliseconds, while Python uses seconds.
The page describes configurable timeout behavior, including automatic pause. Its illustrative information output shows onTimeout set to kill and autoResume set to false. That sample does not establish universal defaults or show how to enable automatic pausing.
Setup
The documented starting point is importing Sandbox from e2b and creating an instance with an explicit timeout. Keep the returned sandbox object to change its timeout, inspect its information or call kill. The page begins at SDK usage and provides no instructions for preparing the environment or configuring access.
Example
The JavaScript example uses await Sandbox.create({ timeoutMs: 60_000 }) to request a 60-second lifetime, then await sandbox.setTimeout(30_000) to reset expiry to 30 seconds from that later call. Python expresses the same durations with Sandbox.create(timeout=60) and sandbox.set_timeout(30).
Separate examples retrieve details with getInfo or get_info and shut down the sandbox with kill. These are documentation examples; no code was executed.
Assessment & evidence
Limitations
Continuous operation is capped at the stated plan limits. The page says pausing resets the runtime window and preserves full state indefinitely, but supplies no pause/resume implementation, restoration timing or failure-handling details.
The runtime limits concern the sandbox rather than an individual stream connection; stream behavior is deferred to another page. Network controls, isolation architecture and workload compatibility are not explained here.
Reasoning
The timeout-unit difference matters when translating integrations between languages: copying the same numeric duration from JavaScript into Python requests a duration 1,000 times longer. Resetting expiry from the current call also matters for applications that renew sessions on user activity. These are implications of the documented API semantics, not measured workload results.
Timeout renewal and the continuous-runtime ceiling should be treated separately. The page directs longer workloads toward pause/resume; it does not establish that repeatedly resetting the timeout bypasses the plan limit.
Alternatives
Within the described lifecycle, developers can reset an active sandbox’s timeout, pause and resume to preserve state, or kill it when finished. Only timeout changes and shutdown are demonstrated in code. The page provides no comparison with other sandbox services or local environments, so comparative cost, performance and isolation remain unknown.
Evidence
The evidence consists of the complete Sandbox lifecycle page at [https://docs.e2b.dev/sandbox.md], including its notices, paired language examples and illustrative information output. The displayed identifiers, CPU and memory values, timestamps and envdVersion are sample output, not observed execution results or proof of current plan entitlements.
Access & freshness
Costs
Prices, included usage, billing units and charges for paused state are unknown from this page. Hobby and Pro are named alongside continuous runtime limits of one hour and 24 hours respectively. The statement that pausing saves resources does not establish whether pausing eliminates or reduces charges.
Rights
The page does not state a license or redistribution terms for its text or code examples. SDK licensing, service terms and rights concerning stored workload data are also unknown from this source.
Freshness
The page was captured on 15 November 2026 at 06:50:10 UTC. It states no publication date, last-updated date or required SDK version. October 2026 timestamps and envdVersion 0.6.10 appear only in illustrative output; they do not establish the page’s update date or a required SDK release. Changes after capture are unknown.
Actions
Before integrating the examples, obtain installation and authentication instructions, confirm current plan limits and pricing, and choose the intended timeout behavior. Use the documented units for each language and confirm lifecycle settings rather than assuming expiry will pause the sandbox.
For workloads that must survive suspension, consult the linked persistence guide [https://docs.e2b.dev/sandbox/persistence.md] and verify restoration with the intended workload. That linked guide and restoration behavior were not assessed.
