---
title: CLI
description: A reference of supported operations using the Daytona CLI.
sidebar:
label: Daytona CLI Reference
---
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
Install the Daytona CLI to interact with Daytona sandboxes from the command line.
```bash
brew install daytonaio/cli/daytona
```
Trust the tap once so routine `brew upgrade` keeps the Daytona CLI up to date. Recent Homebrew versions require third-party taps to be explicitly trusted; without it, a bare `brew upgrade` skips the Daytona tap and the CLI goes stale:
```bash
brew trust daytonaio/cli
```
To upgrade the Daytona CLI to the latest version:
```bash
brew upgrade daytonaio/cli/daytona
```
Alternatively, install directly without Homebrew:
For Apple Silicon (`arm64`):
```bash
sudo curl -fL https://github.com/daytona/clients/releases/latest/download/daytona-darwin-arm64 -o /usr/local/bin/daytona && sudo chmod +x /usr/local/bin/daytona
```
For Intel (`amd64`):
```bash
sudo curl -fL https://github.com/daytona/clients/releases/latest/download/daytona-darwin-amd64 -o /usr/local/bin/daytona && sudo chmod +x /usr/local/bin/daytona
```
Choose the command for your Linux architecture. Both commands download the latest binary from GitHub releases and install it to `/usr/local/bin`, overwriting any existing version.
For `amd64` (`x86_64`):
```bash
sudo curl -fL https://github.com/daytona/clients/releases/latest/download/daytona-linux-amd64 -o /usr/local/bin/daytona && sudo chmod +x /usr/local/bin/daytona
```
For `arm64` (`aarch64`):
```bash
sudo curl -fL https://github.com/daytona/clients/releases/latest/download/daytona-linux-arm64 -o /usr/local/bin/daytona && sudo chmod +x /usr/local/bin/daytona
```
```bash
powershell -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.
{/* The section list below is generated by scripts/generate-cli-docs. Do not edit it directly; run pnpm generate:cli-docs:v2. */}
## Sections
The reference groups commands into the following sections. Global flags that apply to every command are listed under [`daytona`](#daytona).
| Section | Commands |
| :------ | :------- |
| [Login and context](/docs/v2/cli/login-and-context) | [`daytona login`](/docs/v2/cli/login-and-context#daytona-login), [`daytona logout`](/docs/v2/cli/login-and-context#daytona-logout), [`daytona profile`](/docs/v2/cli/login-and-context#daytona-profile), [`daytona whoami`](/docs/v2/cli/login-and-context#daytona-whoami) |
| [Sandboxes and resources](/docs/v2/cli/sandboxes-and-resources) | [`daytona cpu-type`](/docs/v2/cli/sandboxes-and-resources#daytona-cpu-type), [`daytona image`](/docs/v2/cli/sandboxes-and-resources#daytona-image), [`daytona mac-model`](/docs/v2/cli/sandboxes-and-resources#daytona-mac-model), [`daytona region`](/docs/v2/cli/sandboxes-and-resources#daytona-region), [`daytona reservation`](/docs/v2/cli/sandboxes-and-resources#daytona-reservation), [`daytona sandbox`](/docs/v2/cli/sandboxes-and-resources#daytona-sandbox), [`daytona snapshot`](/docs/v2/cli/sandboxes-and-resources#daytona-snapshot) |
| [Organization management](/docs/v2/cli/organization-management) | [`daytona audit`](/docs/v2/cli/organization-management#daytona-audit), [`daytona billing`](/docs/v2/cli/organization-management#daytona-billing), [`daytona invite`](/docs/v2/cli/organization-management#daytona-invite), [`daytona key`](/docs/v2/cli/organization-management#daytona-key), [`daytona member`](/docs/v2/cli/organization-management#daytona-member), [`daytona org`](/docs/v2/cli/organization-management#daytona-org), [`daytona org-key`](/docs/v2/cli/organization-management#daytona-org-key), [`daytona project`](/docs/v2/cli/organization-management#daytona-project), [`daytona registry`](/docs/v2/cli/organization-management#daytona-registry), [`daytona role`](/docs/v2/cli/organization-management#daytona-role), [`daytona secret`](/docs/v2/cli/organization-management#daytona-secret), [`daytona service-account`](/docs/v2/cli/organization-management#daytona-service-account) |
| [Other](/docs/v2/cli/other) | [`daytona completion`](/docs/v2/cli/other#daytona-completion), [`daytona config`](/docs/v2/cli/other#daytona-config), [`daytona docs`](/docs/v2/cli/other#daytona-docs), [`daytona version`](/docs/v2/cli/other#daytona-version) |
{/* End of the generated section list. */}
{/* Everything below this line is generated by scripts/generate-cli-docs from the daytona CLI source. Do not edit it directly; run pnpm generate:cli-docs:v2. */}
## daytona
Daytona — sandboxes, images, snapshots and your organization, from the terminal
daytona is the command line for the Daytona platform.
At a terminal it is interactive: tables, pickers and a confirmation before
destructive actions. When piped, redirected or run with --output json it is a
strict tool: no prompts, --yes required for destructive verbs, JSON on stdout,
diagnostics on stderr. Authorization is decided by the server; the CLI only
presents the credential you give it.
Get started:
```shell
daytona login browser login (or --device on a remote host)
daytona image create py312 --ref python:3.12 import a registry image once
daytona sandbox create --image py312
daytona sandbox exec -- python -c 'print(1)'
daytona docs --full the whole reference in one page
```
__Global flags__
Global flags apply to every command.
| Long | Short | Type | Default | Description |
| :--- | :---- | :--- | :------ | :---------- |
| `--api-key` | | `string` | | static credential sent as-is; disables the saved login for this call (env DAYTONA_API_KEY) |
| `--api-url` | | `string` | | API base URL, for test environments (env DAYTONA_V2_API_URL or DAYTONA_API_URL; default https://api.daytona.com) |
| `--debug` | | `bool` | | log every request to stderr |
| `--file` | `-f` | `string` | | JSON request body from a file (or - for stdin); explicit flags override its fields |
| `--no-wait` | | `bool` | | return once the server accepts the operation instead of waiting for it to finish |
| `--org` | | `string` | | organization id or name for this call (env DAYTONA_ORG) |
| `--output` | `-o` | `string` | `table` | output format: table\|json\|yaml |
| `--profile` | | `string` | | config profile to use (env DAYTONA_PROFILE) |
| `--project` | | `string` | | project id or name for this call (env DAYTONA_PROJECT) |
| `--quiet` | `-q` | `bool` | | suppress progress and informational output on stderr |
| `--region` | | `string` | | region slug; filters lists and places creates (env DAYTONA_REGION) |
| `--timeout` | | `string` | `10m` | how long to wait for an operation to finish |
| `--yes` | `-y` | `bool` | | skip confirmation prompts (env DAYTONA_YES=1) |