---
title: "Remove bucket"
sidebar_label: "Remove bucket"
description: "How objects in a bucket are deleted, how deleted objects are charged, possible errors, and how to stop deletion"
sidebar_position: 10
---

import Formbricks from '@theme/MDXComponents/Formbricks'
import TrashIcon from '@selectel/docux/icons/trash'
import CloseIcon from '@selectel/docux/icons/close'

# Remove bucket

:::info

If the bucket has an [access policy](/s3/buckets/bucket-policy/), it must allow the deletion of every object in the bucket and the deletion of the bucket itself; for more information, see the [Actions](/s3/buckets/bucket-policy/about-bucket-policy.mdx#actions) subsection of the [General information about access policies](/s3/buckets/bucket-policy/about-bucket-policy.mdx).

:::

Buckets that contain no more than 500 000 objects (including [object segments](/s3/objects/upload-object.mdx#segmented-upload)) can be deleted via the Control Panel. Buckets with a larger number of objects can only be deleted via [API](/api/).

Bucket removal may take up to 24 hours. During the removal process, you cannot perform any actions on the bucket, except for [stopping the removal](#stop-deletion).

Objects in a bucket are deleted one by one. During bucket removal, egress traffic and the storage volume of objects not yet deleted are charged. DELETE requests are not charged. For more details on payment and consumption, see the [S3 Payment Model and Prices](/s3/about/payment.mdx) guide.

If a bucket has:

* [versioning](/s3/buckets/versioning.mdx) enabled — a bucket with versions will not be deleted automatically; it must be deleted manually;
* [Object Lock](/s3/buckets/object-lock.mdx) is used — only non-locked objects will be deleted. Locked objects and the bucket itself will not be deleted.

## Remove bucket \{#delete-bucket}

Before removal, complete all API requests related to objects in the bucket.

1. In the [control panel](https://my.selectel.ru/storage/), on the top menu, click **Products** and select **S3**.
2. Go to the **Buckets** section.
3. In the bucket line, click .<TrashIcon />
4. Enter the bucket name and click **Delete**. The status `Deleting` will be displayed in the bucket line. Once deletion is complete, a pop-up notification will appear.

## Possible errors \{#potential-errors}

In case of an error, a pop-up notification will appear:

* `Error deleting bucket` — an internal error occurred, [create a ticket](https://my.selectel.ru/tickets/create/);
* `Task limit reached` — the deletion task limit has been exceeded (you can delete no more than 10 buckets simultaneously). Wait for other tasks to complete and [delete the bucket](#delete-bucket).

## Stop removal \{#stop-deletion}

If bucket removal has not finished, you can stop it. When removal is stopped, only the objects that have not yet been deleted remain in the bucket.

1. In the [control panel](https://my.selectel.ru/storage/), on the top menu, click **Products** and select **S3**.
2. Go to the **Buckets** section.
3. Click the link with the notification about the number of buckets being removed.
4. In the bucket line, click .<CloseIcon />

<Formbricks />
