tencent cloud

Cloud Object Storage

Release Notes and Announcements
Release Notes
Announcements
Product Introduction
Overview
Features
Use Cases
Strengths
Concepts
Regions and Access Endpoints
Specifications and Limits
Service Regions and Service Providers
Billing
Billing Overview
Billing Method
Billable Items
Free Tier
Billing Examples
Viewing and Downloading Bill
Payment Overdue
FAQs
Getting Started
Console
Getting Started with COSBrowser
User Guide
Creating Request
Bucket
Object
Data Management
Batch Operation
Global Acceleration
Monitoring and Alarms
Operations Center
Data Processing
Content Moderation
Smart Toolbox
Data Processing Workflow
Application Integration
User Tools
Tool Overview
Installation and Configuration of Environment
COSBrowser
COSCLI (Beta)
COSCMD
COS Migration
FTP Server
Hadoop
COSDistCp
HDFS TO COS
GooseFS-Lite
Online Tools
Diagnostic Tool
Use Cases
Overview
Access Control and Permission Management
Performance Optimization
Accessing COS with AWS S3 SDK
Data Disaster Recovery and Backup
Domain Name Management Practice
Image Processing
Audio/Video Practices
Workflow
Direct Data Upload
Content Moderation
Data Security
Data Verification
Big Data Practice
COS Cost Optimization Solutions
Using COS in the Third-party Applications
Migration Guide
Migrating Local Data to COS
Migrating Data from Third-Party Cloud Storage Service to COS
Migrating Data from URL to COS
Migrating Data Within COS
Migrating Data Between HDFS and COS
Data Lake Storage
Cloud Native Datalake Storage
Metadata Accelerator
GooseFS
Data Processing
Data Processing Overview
Image Processing
Media Processing
Content Moderation
File Processing Service
File Preview
Troubleshooting
Obtaining RequestId
Slow Upload over Public Network
403 Error for COS Access
Resource Access Error
POST Object Common Exceptions
API Documentation
Introduction
Common Request Headers
Common Response Headers
Error Codes
Request Signature
Action List
Service APIs
Bucket APIs
Object APIs
Batch Operation APIs
Data Processing APIs
Job and Workflow
Content Moderation APIs
Cloud Antivirus API
SDK Documentation
SDK Overview
Preparations
Android SDK
C SDK
C++ SDK
.NET(C#) SDK
Flutter SDK
Go SDK
iOS SDK
Java SDK
JavaScript SDK
Node.js SDK
PHP SDK
Python SDK
React Native SDK
Mini Program SDK
Error Codes
Harmony SDK
Endpoint SDK Quality Optimization
Security and Compliance
Data Disaster Recovery
Data Security
Cloud Access Management
FAQs
Popular Questions
General
Billing
Domain Name Compliance Issues
Bucket Configuration
Domain Names and CDN
Object Operations
Logging and Monitoring
Permission Management
Data Processing
Data Security
Pre-signed URL Issues
SDKs
Tools
APIs
Agreements
Service Level Agreement
Privacy Policy
Data Processing And Security Agreement
Contact Us
Glossary

Deleting Objects

PDF
Modo Foco
Tamanho da Fonte
Última atualização: 2025-09-26 11:18:44

Overview

Tencent Cloud Object Storage (COS) supports deleting one or more objects uploaded to a bucket. You can delete objects in batches through the console, API, or SDK. By default, an empty response is returned if the task deletion completes successfully. If an error occurs, an error message is returned.
Note:
A maximum of 1000 objects can be deleted per request. If needed, split the list and send the request separately.
If you select delete "folder", it will trigger simultaneous deletion of all objects under the "folder". With Versioning Not Enabled, data deletion cannot be recovered or accessed.
If versioning is enabled for your current bucket (including enabled and paused states), performing deletion operation does not actually delete the object but adds a deletion marker to the current version object. At the same time, your storage usage will not reduce. To truly delete an object, you need to specify a version ID. For more information, please refer to Version Control Overview.
If you need to delete large amounts of data or nested folders, it may take a long time to complete the deletion. For such scenarios, it is recommended to set lifecycle for deletion.

Applicable Scenarios

Tencent Cloud Object Storage (COS) supports directly deleting one or multiple objects. To delete an object, you only need to provide its object key and call an API request to delete it.

Usage

Using the COS Console

Deleting an Object in a Bucket with Versioning Not Enabled

1. Log in to the COS Console.
2. In the left sidebar, click Bucket List to go to the bucket list page.
3. Find the bucket where the object is located and click the bucket name to enter the bucket management page.
4. In the left sidebar, select File List to go to the file list page.
5. Select one or more objects you want to delete, click More Operations > Delete at the top.
6. In the pop-up prompt window, click Delete to delete the object.

Deleting an Object in a Bucket with Versioning Enabled/Suspended

Note:
If the bucket has used the version control feature, you must specify a Version ID to actually delete an object. If you delete an object without specifying a Version ID, the object will not be actually deleted. Instead, a deletion marker will be added to the current version. For more information, please refer to Version Control Overview.
1. Log in to the COS Console.
2. In the left sidebar, click Bucket List to go to the bucket list page.
3. Find the bucket where the object is located and click the bucket name to enter the bucket management page.
4. In the left sidebar, select File List to go to the file list page.
5. Turn on the "Show Noncurrent Versions" option at the top, then select one or more object versions to delete, and click More Operations > Delete at the top.
6. In the pop-up prompt window, click Delete to actually delete the object.

Using the REST API

You can use the REST API to initiate deletion requests for one or more objects. See the DELETE Object and DELETE Multiple Objects API documents.

Using SDKs

Directly call the single object deleting method in the SDK. For more information, see the SDK documentation for the corresponding programming language below:

Ajuda e Suporte

Esta página foi útil?

comentários