---
title: Studio
description: Persistent GPU dev workspaces.
canonical: 'https://lightning.ai/docs/cli/stable/command-details/studio'
---
# Studio {#studio}

Persistent GPU dev workspaces.

**Usage:**

```console
lightning studio [OPTIONS] COMMAND [ARGS]...
```

## Commands {#studio-commands}

| Command | Description |
| --- | --- |
| [`connect`](#studio-connect) | Connect to a Studio. |
| [`cp`](#studio-cp) | Copy a Studio file. |
| [`create`](#studio-create) | Create a new Studio. |
| [`delete`](#studio-delete) | Delete a Studio. |
| [`env`](#studio-env) | Manage Studio environment variables. |
| [`list`](#studio-list) | List Studios in a teamspace. |
| [`ls`](#studio-ls) | List contents of a directory in Studio. |
| [`open`](#studio-open) | Open a local file or folder in a Lightning Studio. |
| [`rm`](#studio-rm) | Remove a Studio file or directory. |
| [`ssh`](#studio-ssh) | SSH into a Studio. |
| [`start`](#studio-start) | Start a Studio — a persistent GPU cloud workspace. |
| [`stop`](#studio-stop) | Stop a Studio. |
| [`switch`](#studio-switch) | Switch a Studio to a different machine type. |

## lightning studio connect {#studio-connect}

Connect to a Studio.

**Usage:**

```console
lightning studio connect [OPTIONS] [NAME]
```

### Arguments {#studio-connect-arguments}

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `NAME` | `text` | no | Optional Studio name to connect to. |

### Options {#studio-connect-options}

| Option | Type | Required | Default | Description |
| --- | --- | --- | --- | --- |
| `--teamspace` | `TEXT` | no | `Sentinel.UNSET` | Override default teamspace (format: owner/teamspace) |
| `--cloud` | `TEXT` | no | `Sentinel.UNSET` | Cloud provider or cloud account to create the studio on. Defaults to teamspace default. |
| `--machine` | `[CPU_SMALL|CPU|CPU_X_2|CPU_X_4|CPU_X_8|CPU_X_16|DATA_PREP|DATA_PREP_MAX|DATA_PREP_ULTRA|T4_SMALL|T4|T4_X_2|T4_X_4|T4_X_8|L4|L4_X_2|L4_X_4|L4_X_8|L40S|L40S_X_2|L40S_X_4|L40S_X_8|RTXP_6000|RTXP_6000_X_2|RTXP_6000_X_4|RTXP_6000_X_8|A100|A100_X_2|A100_X_4|A100_X_8|H100|H100_X_2|H100_X_4|H100_X_8|H200|H200_X_2|H200_X_4|H200_X_8|B200|B200_X_8]` | no | `Sentinel.UNSET` | The machine type to start the studio on. Defaults to CPU-4 |
| `--gpus` | `TEXT` | no | `Sentinel.UNSET` | The number and type of GPUs to start the studio on (format: TYPE:COUNT, e.g. L4:4) |
| `--studio-type` | `TEXT` | no | `Sentinel.UNSET` | The base studio template name to use for creating the studio. Must be lowercase and hyphenated (use ‘-’ instead of spaces). Run ‘lightning base-studio list’ to see all available templates. Defaults to the first available template. |
| `--interruptible` | — | no | `Sentinel.UNSET` | Start the studio on an interruptible instance. |

### Examples {#studio-connect-examples}

```console
  lightning studio connect
```

## lightning studio cp {#studio-cp}

Copy a Studio file.

SOURCE: Source file to copy from. For Studio files, use the format lit://<owner>/<my-teamspace>/studios/<my-studio>/<filepath>, or lit:///studios/<my-studio>/<filepath> for the current teamspace.

DESTINATION: Destination file to copy to. For Studio files, use the same formats.

**Usage:**

```console
lightning studio cp [OPTIONS] SOURCE DESTINATION
```

### Arguments {#studio-cp-arguments}

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `SOURCE` | `text` | yes | Source path in the Studio filesystem. |
| `DESTINATION` | `text` | yes | Destination path in the Studio filesystem. |

### Options {#studio-cp-options}

| Option | Type | Required | Default | Description |
| --- | --- | --- | --- | --- |
| `-r`, `--recursive` | — | no | `Sentinel.UNSET` | Copy directories recursively |

### Examples {#studio-cp-examples}

```console
  lightning studio cp source.txt lit://<owner>/<my-teamspace>/studios/<my-studio>/destination.txt
  lightning studio cp source.txt lit:///studios/<my-studio>/destination.txt
  lightning studio cp -r source_folder/ lit:///studios/<my-studio>/destination_folder/
```

## lightning studio create {#studio-create}

Create a new Studio.

**Usage:**

```console
lightning studio create [OPTIONS]
```

### Options {#studio-create-options}

| Option | Type | Required | Default | Description |
| --- | --- | --- | --- | --- |
| `--name` | `TEXT` | no | `Sentinel.UNSET` | The name of the studio to create. If not provided, a random name will be generated. |
| `--teamspace` | `TEXT` | no | `Sentinel.UNSET` | Override default teamspace (format: owner/teamspace) |
| `--cloud` | `TEXT` | no | `Sentinel.UNSET` | Cloud provider or cloud account to create the studio on. Defaults to teamspace default. |
| `--studio-type` | `TEXT` | no | `Sentinel.UNSET` | The base studio template name to use for creating the studio. Must be lowercase and hyphenated (use ‘-’ instead of spaces). Run ‘lightning base-studio list’ to see all available templates. Defaults to the first available template. |
| `--json` | — | no | — | Output the created Studio as JSON. |

### Examples {#studio-create-examples}

```console
  lightning studio create
```

## lightning studio delete {#studio-delete}

Delete a Studio.

**Usage:**

```console
lightning studio delete [OPTIONS] NAME
```

### Arguments {#studio-delete-arguments}

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `NAME` | `text` | yes | No description provided. |

### Options {#studio-delete-options}

| Option | Type | Required | Default | Description |
| --- | --- | --- | --- | --- |
| `--teamspace` | `TEXT` | no | `Sentinel.UNSET` | Override default teamspace (format: owner/teamspace). |
| `--yes`, `-y` | — | no | — | Delete without prompting for confirmation. |

## lightning studio env {#studio-env}

Manage Studio environment variables.

**Usage:**

```console
lightning studio env [OPTIONS] COMMAND [ARGS]...
```

### Commands {#studio-env-commands}

| Command | Description |
| --- | --- |
| [`delete`](#studio-env-delete) | Delete one directly configured Studio environment variable. |
| [`list`](#studio-env-list) | List directly configured Studio environment variables. |
| [`set`](#studio-env-set) | Set one Studio environment variable from KEY=VALUE. |

### lightning studio env delete {#studio-env-delete}

Delete one directly configured Studio environment variable.

**Usage:**

```console
lightning studio env delete [OPTIONS] KEY
```

#### Arguments {#studio-env-delete-arguments}

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `KEY` | `text` | yes | No description provided. |

#### Options {#studio-env-delete-options}

| Option | Type | Required | Default | Description |
| --- | --- | --- | --- | --- |
| `--name` | `TEXT` | no | `Sentinel.UNSET` | Studio to use. Falls back to the current Studio or configured default. |
| `--teamspace` | `TEXT` | no | — | The teamspace to use, as a bare name or an ‘owner/teamspace’ slug. Defaults to the current teamspace. |
| `--org` | `TEXT` | no | — | The organization owning the teamspace (if any). Defaults to the current organization.(DEPRECATED: Pass the owner as part of –teamspace instead, e.g. ‘–teamspace owner/teamspace’. This option will be removed in a future release.) |
| `--user` | `TEXT` | no | — | The user owning the teamspace (if any). Defaults to the current user.(DEPRECATED: Pass the owner as part of –teamspace instead, e.g. ‘–teamspace owner/teamspace’. This option will be removed in a future release.) |
| `--json` | — | no | — | Output as JSON. |

### lightning studio env list {#studio-env-list}

List directly configured Studio environment variables.

**Usage:**

```console
lightning studio env list [OPTIONS]
```

#### Options {#studio-env-list-options}

| Option | Type | Required | Default | Description |
| --- | --- | --- | --- | --- |
| `--name` | `TEXT` | no | `Sentinel.UNSET` | Studio to use. Falls back to the current Studio or configured default. |
| `--teamspace` | `TEXT` | no | — | The teamspace to use, as a bare name or an ‘owner/teamspace’ slug. Defaults to the current teamspace. |
| `--org` | `TEXT` | no | — | The organization owning the teamspace (if any). Defaults to the current organization.(DEPRECATED: Pass the owner as part of –teamspace instead, e.g. ‘–teamspace owner/teamspace’. This option will be removed in a future release.) |
| `--user` | `TEXT` | no | — | The user owning the teamspace (if any). Defaults to the current user.(DEPRECATED: Pass the owner as part of –teamspace instead, e.g. ‘–teamspace owner/teamspace’. This option will be removed in a future release.) |
| `--json` | — | no | — | Output as JSON. |

### lightning studio env set {#studio-env-set}

Set one Studio environment variable from KEY=VALUE.

**Usage:**

```console
lightning studio env set [OPTIONS] ASSIGNMENT
```

#### Arguments {#studio-env-set-arguments}

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `ASSIGNMENT` | `text` | yes | No description provided. |

#### Options {#studio-env-set-options}

| Option | Type | Required | Default | Description |
| --- | --- | --- | --- | --- |
| `--name` | `TEXT` | no | `Sentinel.UNSET` | Studio to use. Falls back to the current Studio or configured default. |
| `--teamspace` | `TEXT` | no | — | The teamspace to use, as a bare name or an ‘owner/teamspace’ slug. Defaults to the current teamspace. |
| `--org` | `TEXT` | no | — | The organization owning the teamspace (if any). Defaults to the current organization.(DEPRECATED: Pass the owner as part of –teamspace instead, e.g. ‘–teamspace owner/teamspace’. This option will be removed in a future release.) |
| `--user` | `TEXT` | no | — | The user owning the teamspace (if any). Defaults to the current user.(DEPRECATED: Pass the owner as part of –teamspace instead, e.g. ‘–teamspace owner/teamspace’. This option will be removed in a future release.) |
| `--json` | — | no | — | Output as JSON. |

## lightning studio list {#studio-list}

List Studios in a teamspace.

**Usage:**

```console
lightning studio list [OPTIONS]
```

### Options {#studio-list-options}

| Option | Type | Required | Default | Description |
| --- | --- | --- | --- | --- |
| `--teamspace` | `TEXT` | no | `Sentinel.UNSET` | Override default teamspace (format: owner/teamspace) |
| `--all` | — | no | — | List all studios, not just the ones belonging to the authed user |
| `--sort-by` | `[name|teamspace|status|machine|cloud-account]` | no | — | the attribute to sort the studios by. |
| `--json` | — | no | — | Output as JSON. |

### Examples {#studio-list-examples}

```console
  lightning studio list --teamspace owner/teamspace
```

## lightning studio ls {#studio-ls}

List contents of a directory in Studio.

PATH: Studio path in the format lit://<owner>/<teamspace>/studios/<studio>/<directory-path>, or lit:///studios/<studio>/<directory-path> for the current teamspace.

**Usage:**

```console
lightning studio ls [OPTIONS] PATH
```

### Arguments {#studio-ls-arguments}

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `PATH` | `text` | yes | Studio filesystem path to list. |

### Examples {#studio-ls-examples}

```console
  lightning studio ls lit://<owner>/<my-teamspace>/studios/<my-studio>/data
  lightning studio ls lit:///studios/<my-studio>/data
```

## lightning studio open {#studio-open}

Open a local file or folder in a Lightning Studio.

**Usage:**

```console
lightning studio open [OPTIONS] [PATH]
```

### Arguments {#studio-open-arguments}

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `PATH` | `path` | no | Local path to open in Lightning Studio. |

### Options {#studio-open-options}

| Option | Type | Required | Default | Description |
| --- | --- | --- | --- | --- |
| `--teamspace` | `TEXT` | no | — | The teamspace to create the Studio in. Should be of format <OWNER>/<TEAMSPACE\_NAME>. If not specified, tries to infer from the environment (e.g. when run from within a Studio.) |
| `--cloud` | `TEXT` | no | — | Cloud provider or cloud account to create the studio on. |
| `--resume` | — | no | `Sentinel.UNSET` | Resume an incomplete upload. |
| `--restart` | — | no | `Sentinel.UNSET` | Restart an incomplete upload. |

## lightning studio rm {#studio-rm}

Remove a Studio file or directory.

PATH: Studio path to remove. Use the format lit://<owner>/<my-teamspace>/studios/<my-studio>/<filepath>, or lit:///studios/<my-studio>/<filepath> for the current teamspace.

**Usage:**

```console
lightning studio rm [OPTIONS] PATH
```

### Arguments {#studio-rm-arguments}

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `PATH` | `text` | yes | Studio filesystem path to remove. |

### Options {#studio-rm-options}

| Option | Type | Required | Default | Description |
| --- | --- | --- | --- | --- |
| `-r`, `--recursive` | — | no | `Sentinel.UNSET` | Remove directories recursively |
| `-f`, `--force` | — | no | `Sentinel.UNSET` | Ignore nonexistent files, never prompt |

### Examples {#studio-rm-examples}

```console
  lightning studio rm lit://<owner>/<my-teamspace>/studios/<my-studio>/file.txt
  lightning studio rm -r lit:///studios/<my-studio>/folder/
```

## lightning studio ssh {#studio-ssh}

SSH into a Studio.

**Usage:**

```console
lightning studio ssh [OPTIONS]
```

### Options {#studio-ssh-options}

| Option | Type | Required | Default | Description |
| --- | --- | --- | --- | --- |
| `--name` | `TEXT` | no | `Sentinel.UNSET` | Studio to use. Falls back to the current Studio or configured default. |
| `--teamspace` | `TEXT` | no | `Sentinel.UNSET` | Override default teamspace (format: owner/teamspace) |
| `--option`, `-o` | `TEXT` | no | `Sentinel.UNSET` | Additional options to pass to the SSH command. Can be specified multiple times. |

### Examples {#studio-ssh-examples}

```console
  lightning studio ssh --name my-studio
```

## lightning studio start {#studio-start}

Start a Studio — a persistent GPU cloud workspace.

**Usage:**

```console
lightning studio start [OPTIONS]
```

### Options {#studio-start-options}

| Option | Type | Required | Default | Description |
| --- | --- | --- | --- | --- |
| `--name` | `TEXT` | no | `Sentinel.UNSET` | Studio to use. Falls back to the current Studio or configured default. |
| `--teamspace` | `OWNER/NAME` | no | `Sentinel.UNSET` | Override the default teamspace. |
| `--create` | — | no | `Sentinel.UNSET` | Create the Studio if it doesn’t exist. |
| `--machine` | `TYPE` | no | `Sentinel.UNSET` | Machine type to start on. Default: \[bold #6FB3E8\]CPU\_4\[/bold #6FB3E8\]. \[#6FB3E8\]CPU\[/#6FB3E8\] · \[#6FB3E8\]T4\[/#6FB3E8\] · \[#6FB3E8\]L4\[/#6FB3E8\] · \[#6FB3E8\]L40S\[/#6FB3E8\] · \[#6FB3E8\]RTXP\_6000\[/#6FB3E8\] · \[#6FB3E8\]A100\[/#6FB3E8\] · \[#6FB3E8\]H100\[/#6FB3E8\] · \[#6FB3E8\]H200\[/#6FB3E8\] · \[#6FB3E8\]B200\[/#6FB3E8\] x1-8 · full list: \[bold #a78bfa\]lightning machine list\[/bold #a78bfa\] |
| `--gpus` | `TYPE:COUNT` | no | `Sentinel.UNSET` | GPUs to attach, e.g. \[bold #6FB3E8\]L4:4\[/bold #6FB3E8\]. |
| `--interruptible` | — | no | `Sentinel.UNSET` | Use a cheaper interruptible (spot) instance. |
| `--cloud` | `TEXT` | no | `Sentinel.UNSET` | Cloud provider or account. Default: teamspace. (with –create) |

### Examples {#studio-start-examples}

```console
  lightning studio start --name my-studio --machine A100 --create
```

## lightning studio stop {#studio-stop}

Stop a Studio.

**Usage:**

```console
lightning studio stop [OPTIONS]
```

### Options {#studio-stop-options}

| Option | Type | Required | Default | Description |
| --- | --- | --- | --- | --- |
| `--name` | `TEXT` | no | `Sentinel.UNSET` | Studio to use. Falls back to the current Studio or configured default. |
| `--teamspace` | `TEXT` | no | `Sentinel.UNSET` | Override default teamspace (format: owner/teamspace) |
| `--json` | — | no | — | Output as JSON. |

### Examples {#studio-stop-examples}

```console
  lightning studio stop --name my-studio
```

## lightning studio switch {#studio-switch}

Switch a Studio to a different machine type.

**Usage:**

```console
lightning studio switch [OPTIONS]
```

### Options {#studio-switch-options}

| Option | Type | Required | Default | Description |
| --- | --- | --- | --- | --- |
| `--name` | `TEXT` | no | `Sentinel.UNSET` | Studio to use. Falls back to the current Studio or configured default. |
| `--teamspace` | `TEXT` | no | `Sentinel.UNSET` | Override default teamspace (format: owner/teamspace) |
| `--machine` | `[CPU_SMALL|CPU|CPU_X_2|CPU_X_4|CPU_X_8|CPU_X_16|DATA_PREP|DATA_PREP_MAX|DATA_PREP_ULTRA|T4_SMALL|T4|T4_X_2|T4_X_4|T4_X_8|L4|L4_X_2|L4_X_4|L4_X_8|L40S|L40S_X_2|L40S_X_4|L40S_X_8|RTXP_6000|RTXP_6000_X_2|RTXP_6000_X_4|RTXP_6000_X_8|A100|A100_X_2|A100_X_4|A100_X_8|A100_40GB|A100_40GB_X_2|A100_40GB_X_4|A100_40GB_X_8|A100_80GB|A100_80GB_X_2|A100_80GB_X_4|A100_80GB_X_8|H100|H100_X_2|H100_X_4|H100_X_8|H200|H200_X_2|H200_X_4|H200_X_8|B200|B200_X_8]` | no | `Sentinel.UNSET` | The machine type to switch the studio to. |
| `--interruptible` | — | no | `Sentinel.UNSET` | Switch the studio to an interruptible instance. |

---

**Navigation**

- Parent: [Command details](/docs/cli/2026.11.04/command-details.md)
