dynobase-icon
Dynobase

DynamoDB: Delete Table (Guide w/ Code Examples)

Rafal Wilinski

Provided by Rafal Wilinski

Last updated: October 23rd, 2026

DeleteTableCommand deletes the table and its data asynchronously. Confirm the account, Region and table name before running it; use the waiter when subsequent work requires deletion to finish.

Install @aws-sdk/client-dynamodb and @aws-sdk/lib-dynamodb, use an ES module on a supported Node.js runtime, and configure an AWS Region and credentials. The examples use an existing Orders table with String keys pk and sk unless an index or timestamp key is described.

import { DynamoDBClient, DeleteTableCommand, waitUntilTableNotExists } from "@aws-sdk/client-dynamodb"; const client = new DynamoDBClient({}); await client.send(new DeleteTableCommand({ TableName: "Orders" })); await waitUntilTableNotExists( { client, maxWaitTime: 120 }, { TableName: "Orders" }, );

Deletion protection must be disabled before this operation can succeed. Deleting the table also removes its indexes; it is different from deleting all items.

Reference: AWS DeleteTable API. For related access patterns, see DynamoDB query examples.

Dynobase is a Professional GUI Client for DynamoDB

Start your 7-day free trial today

Product Features

Download
/
Pricing
/
Member Portal
/
Privacy
/
EULA
/
Twitter
© 2026 Dynobase
+
Still using AWS DynamoDB Console?
Try Dynobase to accelerate your DynamoDB workflow. Start your 7-day free trial today.