Course contentsShow
← Cloud and Infrastructure
Lesson 157 of 2,9893. Storage PrimitivesFree lesson

Versioning Lifecycle and MFA Delete

Control version retention, suspension, and require multi-factor authentication for permanent deletions.

Versioning Lifecycle and MFA Delete

What you'll learn: How to control when versioned objects are deleted or archived, and protect critical data with multi-factor authentication.

Managing Version Lifecycles

Now that you understand object versioning (Lesson 156), you need to control what happens to those versions over time. Without lifecycle rules, versioned buckets accumulate old versions forever—driving up storage costs.

Lifecycle policies let you automatically:

  • Transition older versions to cheaper storage classes (move 30-day-old versions to cold storage)
  • Expire (delete) non-current versions after a set period (remove versions older than 90 days)
  • Suspend versioning on a bucket (new uploads overwrite, but existing versions remain)

Think of it like email retention policies: you might keep current emails forever, last month's emails in an archive folder, and permanently delete anything older than a year.

MFA Delete Protection

MFA Delete adds a critical safety layer: before permanently deleting a version or suspending versioning on a bucket, you must provide a code from a physical multi-factor authentication device (like a key fob or authenticator app).

This prevents accidental or malicious deletions—even if someone steals your password, they can't erase critical versioned data without the physical MFA device. It's like requiring both a key and a fingerprint scan to access a vault.

MFA Delete must be enabled by the bucket owner using root account credentials and only applies to version deletion and versioning suspension—not regular uploads or retrievals.

Key Takeaway: Lifecycle policies automate version retention and cleanup to control costs, while MFA Delete requires physical authentication to prevent permanent data loss on versioned buckets.