---
metadata:
  - name: generator
    content: Diplodoc Platform v5.52.0
alternate:
  - https://ydb.tech/docs/en/yql/reference/syntax/drop-secret.md
  - https://ydb.tech/docs/ru/yql/reference/syntax/drop-secret.md
  - href: en/yql/reference/syntax/drop-secret.md
    type: text/markdown
    title: Markdown version
  - href: ../../../llms.txt
    type: text/markdown
    title: llms.txt
sourcePath: en/core/yql/reference/syntax/drop-secret.md
---
> **Documentation Index:** Fetch the complete configuration index at https://ydb.tech/docs/en/llms.txt

# DROP SECRET

The `DROP SECRET` statement deletes an existing [secret](https://ydb.tech/docs/en/concepts/datamodel/secrets.md).

## Syntax {#syntax}

```sql
DROP SECRET secret_name
```

* `secret_name` — the name of the secret to delete.

## Permissions {#permissions}

Deleting a secret requires the [rights](https://ydb.tech/docs/en/yql/reference/syntax/grant.md#permissions-list) `REMOVE SCHEMA` and `ALTER SCHEMA`.

## Examples {#examples}

Delete the secret named `secret_name`:

```sql
DROP SECRET secret_name;
```

## See also {#see-also}

* [CREATE SECRET](https://ydb.tech/docs/en/yql/reference/syntax/create-secret.md)
* [ALTER SECRET](https://ydb.tech/docs/en/yql/reference/syntax/alter-secret.md)
