Back to feed
Dev.to
Dev.to
6/25/2026
Amazon S3, Object Stores, and the Directories That Don't Exist

Amazon S3, Object Stores, and the Directories That Don't Exist

Short summary

S3 and S3-compatible systems don't store files in real directories—every object has a unique key and prefixes simulate folder structures. Operations like deletion or listing search for matching keys rather than traversing a directory tree, which can be expensive and trigger API charges. Best practice: store known object keys in a database instead of repeatedly asking the storage service to discover them via costly LIST operations.

  • Object storage uses objects with key prefixes, not real directories
  • Prefix-based lookups are expensive operations that incur API charges
  • Store known keys in a database to avoid repeated discovery queries

Generated with AI, which can make mistakes.

Is this a good recommendation for you?

Explore more