I want to know the cost of each Amazon Simple Storage Service (Amazon S3) bucket in my account or in an AWS Region. Or, my Amazon S3 storage costs for a particular Region went up, and I want to know which bucket is driving that increased cost. How can I do that?

Follow these steps:

  1. Add a common tag to each bucket.
  2. Activate the tag as a cost allocation tag.
  3. Use the AWS Cost Explorer to create a cost report for the tag.

Note: Cost allocation tags won't show you costs that you incurred before you set up the tags.

Before you begin, your AWS Identity and Access Management (IAM) policy must have permission to:

Note: As a best practice, don't use your AWS account root user for this procedure. Instead, use an IAM user or role with the permissions that you need.

Add a common tag to each bucket

  1. Open the Amazon S3 console.
  2. From the list of buckets, choose the bucket that you want to track costs for.
  3. Choose the Properties view.
  4. Under Advanced settings, choose Tags.
  5. Choose Add tag.
  6. For Key, enter a name for the tag that you'll add to all the buckets that you want to track costs for. For example, enter "S3-Bucket-Name".
  7. For Value, enter the name of the bucket.
  8. Repeat steps 1 through 7 for all the buckets that you want to track costs for.

Activate the tag as a cost allocation tag

  1. Open the Billing and Cost Management console.
  2. From the navigation pane, choose Cost allocation tags.
  3. In the search bar, type the name of the tag that you created for your buckets. For example, type "S3-Bucket-Name".
  4. Select the tag.
  5. Choose Activate.

Use the AWS Cost Explorer to create a cost report for the tag

  1. Open the Billing and Cost Management console.
  2. From the navigation pane, choose Cost Explorer.
  3. Choose Launch Cost Explorer.
  4. From the navigation pane, choose Saved reports.
  5. Choose New report.
  6. For Report Templates, select Cost & Usage report, and then choose Create Report.
  7. Under Filters, for Service, select S3 (Simple Storage Service). Then, choose Apply filters.
  8. For Tag, select the tag that you created. For example, select S3-Bucket-Name. Then, check each bucket that you want to track costs on, and choose Apply filters.
    Note: If you don't see your tag in the filter list, it's likely that the tag was just created and applied to a bucket. Wait 24 hours, and then try creating the report again.
  9. Under Advanced options, confirm that Show only untagged resources is unchecked.
  10. From the top of the graph, choose Group by, and then select the tag that you created.
  11. Choose Save as...
  12. Enter a title for your cost report.
  13. Choose Save Report.

After you create the cost report, you can use it to review the cost of each bucket that has the cost allocation tag that you created.

Note: You can set up a daily or hourly AWS Cost and Usage report to get more Amazon S3 billing details. However, these reports won't show you who made requests to your buckets. To see where requests to your bucket are coming from, enable either object-level logging or server access logging. To get more information on certain Amazon S3 billing items, you must have enabled logging ahead of time. Then, you'll have logs that contain Amazon S3 request details.


Did this page help you? Yes | No

Back to the AWS Support Knowledge Center

Need help? Visit the AWS Support Center

Published: 2019-03-25