Machine Sizes
Both the CLI (--size) and the dashboard provide the same size options:
vCPU counts represent burstable capacity. Your workspace policy may restrict which sizes are available.
Create Devbox
Create a new Devbox with interactive prompts:In-line params
Pass parameters inline to skip specific prompts:From a Spec File
Define your Devbox configuration in a spec file:devbox.yaml
--from:
- See Spec file reference below for all available configuration options.
- Spec files can be JSON (
.json), YAML (.yaml/.yml), or TOML (.toml). - The
--fromflag works withdevbox acquire.
Reading from stdin
Pass- as the path to read the spec from stdin. Stdin is parsed as YAML by
default; use --from_format to override (json, yaml, or toml):
Ephemeral Devboxes
Devboxes can be created as ephemeral, tying their instance and storage to a single run. When an ephemeral Devbox stops, both its instance and storage are automatically deleted. On restart, it starts fresh. Ephemeral Devboxes suit short-lived tasks or experimentation where you don’t need to retain data across restarts. Create an ephemeral Devbox with the--ephemeral flag:
Listing Devboxes
Via the CLI:--show-all to see all Devboxes in the workspace.
Output as JSON for scripting:
Starting & Stopping
Devboxes start automatically when you connect viadevbox ssh, devbox open-ide, or from the dashboard.
To stop a running Devbox:
Via the CLI:
devbox stop.
Via the Dashboard:
Click the stop button on any running Devbox in the dashboard or from the Devbox detail page.
Stopped Devboxes retain all persistent storage. They resume in seconds on the next connection.
Idleness & Auto-Stop
Control how long a Devbox stays running after becoming idle. Available timeouts: 15 min, 30 min, 1 hour, 4 hours, or 8 hours. CLI:How idleness is detected
A Devbox is considered active (not idle) if any of the following are true:- There is an active SSH connection, whether through
devbox sshor a native SSH client. This includes SSH connections kept open by IDEs. - A session was created within the last 15 minutes.
- Files exist under
/.namespace/tasks, which indicate ongoing tasks and can be created by users.
Deleting
Deleting a Devbox permanently removes it and its associated persistent volume. Via the CLI:--force:
Volume Size
Override the default persistent volume size:Nested Virtualization
Linux Devboxes support nested virtualization:/dev/kvm is available inside the Devbox, so processes can use hardware-assisted virtualization. No flag or spec file option is needed: the device is mounted automatically, and its permissions are set so non-root users can use it without additional setup.
This works the same way with custom images; you don’t need to do anything in your Dockerfile to make /dev/kvm available.
To verify it’s present, run:
linux/amd64. See Android Emulators for more information.
Nested virtualization is not available on macOS Devboxes. See Nested Virtualization for full platform support details.
Spec file reference
Sessions
Each entry insessions has:
Configure one or more
session-command pairs to have the Devbox automatically create sessions and run the specified commands on startup.
Environment Variables
Each entry inenv has a name and exactly one of value or from_secret_id:
Repository
Therepository block supports:
Omit
repository to fall back to the workspace default. To explicitly create a Devbox with no repository checked out:
Network Policy
Thenetwork_policy block restricts outbound network access:
Integrations
Theintegrations object supports:
Example
devbox.yaml
Workspace Defaults
Workspace admins can set default values applied to all newly created Devboxes. Navigate to the Defaults page in the dashboard to configure:- Instance Size: default CPU and memory allocation
- Image: default base image
- Git Repository: default repository to clone
- Access Mode: private (just you) or workspace-wide (shared with all members)
- Idle Timeout: how long Devboxes stay running when idle
- Tailscale: default Tailscale integration spec to connect Devboxes to your tailnet
- Network Policy: default outbound network access restrictions
Git Configuration
Configure the git author name and email used across your Devboxes from the dashboard. Click your name in the Devboxes header to open the git configuration dialog. This setsuser.name and user.email for git operations in all your Devboxes.
Setting Up GitHub CLI
Forward your localgh CLI authentication to a Devbox:
gh CLI (via gh auth login) and git (via gh auth setup-git) to use it, so gh commands and HTTPS git operations are authenticated. This requires gh to be on the Devbox’s PATH.
You can also do this as part of creating or acquiring a Devbox, so you don’t need a separate step. Pass --setup_github:
integrations.github.share_auth:
devbox.yaml
gh token is read before the Devbox is created, so a missing or expired login fails fast. Because it forwards your local authentication, this step requires the Devbox to be activated. When both are given, the --setup_github flag overrides the spec value.
Resource Monitoring
The dashboard shows live resource metrics for running Devboxes:- CPU utilization: overall and per-core usage with historical graphs
- Memory utilization: current usage percentage with history
- Network latency: ping indicator showing connection quality to your Devbox’s site
Site Latency
Devboxes are automatically created in the site closest to you. To manually check latency to available sites:Self-Update
Keep the Devbox CLI up to date:Next Steps
Remote Development → Connect to your Devbox via SSH, VS Code, Cursor, Zed, or JetBrains. Sessions → Persistent terminal sessions that survive disconnections and Devbox restarts. Executing Commands → Run commands in a Devbox withdevbox exec and read their output with devbox logs.
Custom Images →
Build custom base images with your tools and runtimes pre-installed.