Skip to main content

DynamoDB: Delete Unused Tables or Global Secondary Indexes

Difficulty: Medium

Description

These tables or indexes have had no reads in 30 days but still cost you storage and capacity. When a whole table is unused, the saving also includes its unused global secondary indexes. If nothing depends on them, delete them.


Selection Criteria

  • The table, including its global secondary indexes, OR the global secondary index alone, had no consumed read capacity in the last 30 days.

  • Tables need CloudWatch metrics for the period. Only global secondary indexes with provisioned read capacity are evaluated.

  • The resource still has capacity or storage costs that can be removed.


Expected Saving

100% of the unused resource’s annualized costs (table or GSI), calculated as follows:

  • Storage savings: 100% of the storage allocated to the unused resource

    • Table: base table storage

    • GSI: index storage (based on projected attributes size)

  • Write savings: 100% of write capacity costs for the unused resource

    • Provisioned mode: based on ProvisionedWriteCapacityUnits metrics

    • On-Demand mode: based on ConsumedWriteCapacity

Saving varies depending on the resource size, capacity mode, and (for GSIs) projected attribute set.


Operational Impact

Table

Breaking change (application): YES — CRITICAL ⚠️

Deleting this table will immediately break any application queries that depend on it. Before proceeding, confirm with the development team that no production code references this table. This must be an explicit customer approval step.


GSI

Downtime (table): None — deleting a GSI does not interrupt read or write operations on the parent table. Other indexes remain unaffected.

Breaking change (application): YES — CRITICAL ⚠️

Deleting this GSI will immediately break any application queries that depend on it. Before proceeding, confirm with the development team that no production code references this GSI. This must be an explicit customer approval step.

Deletion is permanent: A deleted GSI cannot be restored. Recreating it requires a full reindex of the table, which can consume significant WCU and time, depending on table size.


References

Did this answer your question?