---
title: "Delete an environment variable"
method: DELETE
path: "/projects/{project_id}/env-vars/{var_id}"
tags: ["Projects"]
---

# Delete an environment variable

`DELETE /projects/{project_id}/env-vars/{var_id}`

## Request

- Base URL: `/api` (relative, and the document was published on a file host, not at the API’s origin)
- URL: `/api/projects/{project_id}/env-vars/{var_id}`
- Auth: HTTP bearer

## Path parameters

- `project_id` integer, required
- `var_id` integer, required

## Response `204`

Environment variable deleted successfully

## Other responses

- `404`: Project or variable not found
- `500`: Internal server error

## Changes

- **2026-11-25** `480a86944327`: 1 info
  - the endpoint scheme security `bearer_auth` was added to the API

[Operation history](https://skmtc.dev/gotempsh/apis/temps/changes/projects/:project_id/env-vars/:var_id/delete.md)

---

[API](https://skmtc.dev/gotempsh/apis/temps.md) - [All operations](https://skmtc.dev/gotempsh/apis/temps/llms.txt) - [OpenAPI document](https://skmtc.dev/gotempsh/apis/temps/revisions/3b040526eb43?raw)
