How to determine the size of an S3 bucket

aws s3 ls s3://bucketName/ --recursive --summarize | grep "Total Size:"
aws s3 ls s3://bucketName/prefix/ --recursive --summarize | grep "Total Size:"
See also  How to change EBS volume type