CLI
Daytona provides command-line access to core features for interacting with Daytona Sandboxes, including managing their lifecycle, snapshots, and more.
The CLI reference lists all commands supported by the daytona command-line tool, complete with a description of their behavior, and any supported flags.
You can access this documentation on a per-command basis by appending the --help/-h flag when invoking daytona.
Installation
Section titled “Installation”Install the Daytona CLI to interact with Daytona sandboxes from the command line.
brew install daytonaio/cli/daytonapowershell -Command "irm https://get.daytona.io/windows | iex"After installing the Daytona CLI, use the daytona command to interact with Daytona Sandboxes from the command line.
Update
Section titled “Update”To update the Daytona CLI to the latest version:
brew upgrade daytonaio/cli/daytonapowershell -Command "irm https://get.daytona.io/windows | iex"daytona
Section titled “daytona”Daytona CLI
daytona [flags]Flags
| Long | Short | Description |
|---|---|---|
--help | help for daytona | |
--version | -v | Display the version of Daytona |
daytona archive
Section titled “daytona archive”Archive a sandbox
daytona archive [SANDBOX_ID] | [SANDBOX_NAME] [flags]Flags
| Long | Short | Description |
|---|---|---|
--help | help for daytona |
daytona autocomplete
Section titled “daytona autocomplete”Adds a completion script for your shell environment
daytona autocomplete [bash|zsh|fish|powershell] [flags]Flags
| Long | Short | Description |
|---|---|---|
--help | help for daytona |
daytona create
Section titled “daytona create”Create a new sandbox
daytona create [flags]Flags
| Long | Short | Description |
|---|---|---|
--auto-archive | Auto-archive interval in minutes (0 means the maximum interval will be used) | |
--auto-delete | Auto-delete interval in minutes (negative value means disabled, 0 means delete immediately upon stopping) | |
--auto-stop | Auto-stop interval in minutes (0 means disabled) | |
--class | Sandbox class type (small, medium, large) | |
--context | -c | Files or directories to include in the build context (can be specified multiple times) |
--cpu | CPU cores allocated to the sandbox | |
--disk | Disk space allocated to the sandbox in GB | |
--dockerfile | -f | Path to Dockerfile for Sandbox snapshot |
--env | -e | Environment variables (format: KEY=VALUE) |
--gpu | GPU units allocated to the sandbox | |
--label | -l | Labels (format: KEY=VALUE) |
--memory | Memory allocated to the sandbox in MB | |
--name | Name of the sandbox | |
--network-allow-list | Comma-separated list of allowed CIDR network addresses for the sandbox | |
--network-block-all | Whether to block all network access for the sandbox | |
--public | Make sandbox publicly accessible | |
--snapshot | Snapshot to use for the sandbox | |
--target | Target region (eu, us) | |
--user | User associated with the sandbox | |
--volume | -v | Volumes to mount (format: VOLUME_NAME:MOUNT_PATH) |
--help | help for daytona |
daytona delete
Section titled “daytona delete”Delete a sandbox
daytona delete [SANDBOX_ID] | [SANDBOX_NAME] [flags]Flags
| Long | Short | Description |
|---|---|---|
--all | -a | Delete all sandboxes |
--help | help for daytona |
daytona docs
Section titled “daytona docs”Opens the Daytona documentation in your default browser.
daytona docs [flags]Flags
| Long | Short | Description |
|---|---|---|
--help | help for daytona |
daytona exec
Section titled “daytona exec”Execute a command in a sandbox
daytona exec [SANDBOX_ID | SANDBOX_NAME] -- [COMMAND] [ARGS...] [flags]Flags
| Long | Short | Description |
|---|---|---|
--cwd | Working directory for command execution | |
--timeout | Command timeout in seconds (0 for no timeout) | |
--help | help for daytona |
daytona info
Section titled “daytona info”Get sandbox info
daytona info [SANDBOX_ID] | [SANDBOX_NAME] [flags]Flags
| Long | Short | Description |
|---|---|---|
--format | -f | Output format. Must be one of (yaml, json) |
--help | help for daytona |
daytona list
Section titled “daytona list”List sandboxes
daytona list [flags]Flags
| Long | Short | Description |
|---|---|---|
--format | -f | Output format. Must be one of (yaml, json) |
--limit | -l | Maximum number of items per page |
--page | -p | Page number for pagination (starting from 1) |
--help | help for daytona |
daytona login
Section titled “daytona login”Log in to Daytona
daytona login [flags]Flags
| Long | Short | Description |
|---|---|---|
--api-key | API key to use for authentication | |
--help | help for daytona |
daytona logout
Section titled “daytona logout”Logout from Daytona
daytona logout [flags]Flags
| Long | Short | Description |
|---|---|---|
--help | help for daytona |
daytona mcp
Section titled “daytona mcp”Manage Daytona MCP Server
daytona mcp [flags]Flags
| Long | Short | Description |
|---|---|---|
--help | help for daytona |
daytona mcp config
Section titled “daytona mcp config”Outputs JSON configuration for Daytona MCP Server
daytona mcp config [AGENT_NAME] [flags]Flags
| Long | Short | Description |
|---|---|---|
--help | help for daytona |
daytona mcp init
Section titled “daytona mcp init”Initialize Daytona MCP Server with an agent (currently supported: claude, windsurf, cursor)
daytona mcp init [AGENT_NAME] [flags]Flags
| Long | Short | Description |
|---|---|---|
--help | help for daytona |
daytona mcp start
Section titled “daytona mcp start”Start Daytona MCP Server
daytona mcp start [flags]Flags
| Long | Short | Description |
|---|---|---|
--help | help for daytona |
daytona organization
Section titled “daytona organization”Manage Daytona organizations
daytona organization [flags]Flags
| Long | Short | Description |
|---|---|---|
--help | help for daytona |
daytona organization create
Section titled “daytona organization create”Create a new organization and set it as active
daytona organization create [ORGANIZATION_NAME] [flags]Flags
| Long | Short | Description |
|---|---|---|
--help | help for daytona |
daytona organization delete
Section titled “daytona organization delete”Delete an organization
daytona organization delete [ORGANIZATION] [flags]Flags
| Long | Short | Description |
|---|---|---|
--help | help for daytona |
daytona organization list
Section titled “daytona organization list”List all organizations
daytona organization list [flags]Flags
| Long | Short | Description |
|---|---|---|
--format | -f | Output format. Must be one of (yaml, json) |
--help | help for daytona |
daytona organization use
Section titled “daytona organization use”Set active organization
daytona organization use [ORGANIZATION] [flags]Flags
| Long | Short | Description |
|---|---|---|
--help | help for daytona |
daytona preview-url
Section titled “daytona preview-url”Get signed preview URL for a sandbox port
daytona preview-url [SANDBOX_ID | SANDBOX_NAME] [flags]Flags
| Long | Short | Description |
|---|---|---|
--expires | URL expiration time in seconds | |
--port | -p | Port number to get preview URL for (required) |
--help | help for daytona |
daytona snapshot
Section titled “daytona snapshot”Manage Daytona snapshots
daytona snapshot [flags]Flags
| Long | Short | Description |
|---|---|---|
--help | help for daytona |
daytona snapshot create
Section titled “daytona snapshot create”Create a snapshot
daytona snapshot create [SNAPSHOT] [flags]Flags
| Long | Short | Description |
|---|---|---|
--context | -c | Files or directories to include in the build context (can be specified multiple times). If not provided, context will be automatically determined from COPY/ADD commands in the Dockerfile |
--cpu | CPU cores that will be allocated to the underlying sandboxes (default: 1) | |
--disk | Disk space that will be allocated to the underlying sandboxes in GB (default: 3) | |
--dockerfile | -f | Path to Dockerfile to build |
--entrypoint | -e | The entrypoint command for the snapshot |
--image | -i | The image name for the snapshot |
--memory | Memory that will be allocated to the underlying sandboxes in GB (default: 1) | |
--region | ID of the region where the snapshot will be available (defaults to organization default region) | |
--help | help for daytona |
daytona snapshot delete
Section titled “daytona snapshot delete”Delete a snapshot
daytona snapshot delete [SNAPSHOT_ID] [flags]Flags
| Long | Short | Description |
|---|---|---|
--all | -a | Delete all snapshots |
--help | help for daytona |
daytona snapshot list
Section titled “daytona snapshot list”List all snapshots
daytona snapshot list [flags]Flags
| Long | Short | Description |
|---|---|---|
--format | -f | Output format. Must be one of (yaml, json) |
--limit | -l | Maximum number of items per page |
--page | -p | Page number for pagination (starting from 1) |
--help | help for daytona |
daytona snapshot push
Section titled “daytona snapshot push”Push local snapshot
daytona snapshot push [SNAPSHOT] [flags]Flags
| Long | Short | Description |
|---|---|---|
--cpu | CPU cores that will be allocated to the underlying sandboxes (default: 1) | |
--disk | Disk space that will be allocated to the underlying sandboxes in GB (default: 3) | |
--entrypoint | -e | The entrypoint command for the image |
--memory | Memory that will be allocated to the underlying sandboxes in GB (default: 1) | |
--name | -n | Specify the Snapshot name |
--region | ID of the region where the snapshot will be available (defaults to organization default region) | |
--help | help for daytona |
daytona ssh
Section titled “daytona ssh”SSH into a sandbox
daytona ssh [SANDBOX_ID] | [SANDBOX_NAME] [flags]Flags
| Long | Short | Description |
|---|---|---|
--expires | SSH access token expiration time in minutes (defaults to 24 hours) | |
--help | help for daytona |
daytona start
Section titled “daytona start”Start a sandbox
daytona start [SANDBOX_ID] | [SANDBOX_NAME] [flags]Flags
| Long | Short | Description |
|---|---|---|
--help | help for daytona |
daytona stop
Section titled “daytona stop”Stop a sandbox
daytona stop [SANDBOX_ID] | [SANDBOX_NAME] [flags]Flags
| Long | Short | Description |
|---|---|---|
--help | help for daytona |
daytona version
Section titled “daytona version”Print the version number
daytona version [flags]Flags
| Long | Short | Description |
|---|---|---|
--help | help for daytona |
daytona volume
Section titled “daytona volume”Manage Daytona volumes
daytona volume [flags]Flags
| Long | Short | Description |
|---|---|---|
--help | help for daytona |
daytona volume create
Section titled “daytona volume create”Create a volume
daytona volume create [NAME] [flags]Flags
| Long | Short | Description |
|---|---|---|
--size | -s | Size of the volume in GB |
--help | help for daytona |
daytona volume delete
Section titled “daytona volume delete”Delete a volume
daytona volume delete [VOLUME_ID] [flags]Flags
| Long | Short | Description |
|---|---|---|
--help | help for daytona |
daytona volume get
Section titled “daytona volume get”Get volume details
daytona volume get [VOLUME_ID] [flags]Flags
| Long | Short | Description |
|---|---|---|
--format | -f | Output format. Must be one of (yaml, json) |
--help | help for daytona |
daytona volume list
Section titled “daytona volume list”List all volumes
daytona volume list [flags]Flags
| Long | Short | Description |
|---|---|---|
--format | -f | Output format. Must be one of (yaml, json) |
--help | help for daytona |