This inefficiency occurs when small files are stored in S3 storage classes that impose a minimum object size charge, resulting in unnecessary costs. Small files under 128 KB stored in Glacier Instant Retrieval, Standard-IA, or One Zone-IA are billed as if they were 128 KB. If these small files are accessed frequently, S3 Standard may be a better fit. For infrequently accessed small files, transitioning them to archival storage classes like Glacier Flexible Retrieval or Deep Archive can optimize storage spend. Poorly tuned lifecycle policies often allow small files to remain in suboptimal storage classes indefinitely.
S3 storage is billed per GB stored per month, but for certain storage classes like Glacier Instant Retrieval, Standard-IA, and One Zone-IA, a minimum object size charge of 128 KB applies. Even if an object is smaller than 128 KB, billing treats it as if it were 128 KB. This means small files stored in these classes may incur disproportionately high costs compared to larger files. Choosing the right storage class is crucial to avoid unnecessary charges.
Move frequently accessed small objects to S3 Standard to avoid minimum size penalties. Transition infrequently accessed small objects to S3 Glacier Flexible Retrieval or S3 Glacier Deep Archive through updated lifecycle policies. Implement automated lifecycle rules based on object size and last access time to proactively manage small object storage. Periodically audit buckets for small object distribution and adjust policies as data patterns change over time.