> ## Documentation Index
> Fetch the complete documentation index at: https://docs.staging.alpic.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# environment-variable remove

> Remove an environment variable from an Alpic environment

Removes an environment variable from an Alpic environment. Prompts to select the key interactively unless `--key` is provided.

## Usage

```bash theme={null}
alpic environment-variable remove
```

Prompts to select the variable to remove interactively.

## Extended Usage

**Remove a specific variable non-interactively:**

```bash theme={null}
alpic environment-variable remove --key DATABASE_URL
```

**Remove a variable from a specific environment:**

```bash theme={null}
alpic environment-variable remove --key DATABASE_URL --environment-id <environmentId>
```

## Options

| Flag                | Description                                                              |
| ------------------- | ------------------------------------------------------------------------ |
| `--environment-id`  | The ID of the environment (optional — read from local config if omitted) |
| `--key`             | The key of the environment variable to remove                            |
| `--non-interactive` | Disable interactive prompts. Requires `--key`                            |

<Tip>
  When running from a directory linked to an Alpic project (via `alpic deploy`), `--environment-id` is optional — the
  CLI reads it from the local `.alpic` config file.
</Tip>
