- Newest
- Most votes
- Most comments
The behavior you're experiencing is related to changes in Amazon S3 URL formats and endpoint configurations. Here's what might be happening:
-
Legacy vs. Regional Endpoints: AWS has been moving towards using regional endpoints for S3 buckets. The URL format without the region (https://mybucketname.s3.amazonaws.com/...) is considered a legacy global endpoint, while the one with the region (https://mybucketname.s3.us-east-1.amazonaws.com/...) is a regional endpoint.
-
Bucket Creation Date: The difference in behavior you're seeing between buckets might be due to when these buckets were created. Buckets created after a certain date (around March 20, 2019) in most regions require the use of regional endpoints.
-
Temporary Redirects: In some cases, when you use the legacy endpoint for newer buckets or in certain regions, you might receive a temporary redirect (HTTP 307) to the correct regional endpoint. This redirect might be happening transparently for some of your buckets, making it appear as if the legacy URL still works.
-
Best Practice: AWS recommends always using the regional endpoints with the region code in the hostname. This is considered more reliable and future-proof.
-
Bucket Configuration: While you mention that all your buckets have the same properties and permissions, there might be subtle differences in their configurations or the time they were created that affect this behavior.
-
Public Access: Ensure that the bucket and object permissions allow public access if you intend for these URLs to be publicly accessible.
To resolve this issue and ensure consistency:
- Always use the regional endpoint format for your S3 URLs.
- Double-check your bucket and object permissions to ensure they allow the intended access.
- If you need to support legacy URLs, you might need to implement a redirection mechanism on your application side.
Remember that using presigned URLs or configuring buckets as static websites provides more control over URL formats and access, which might be worth considering depending on your use case.
Sources
Community | Format and Parse Amazon S3 URLs
Sharing objects with presigned URLs - Amazon Simple Storage Service
answered 2 years ago
Hi,
This usually comes from an ACL issue (which is different from policy): https://docs.aws.amazon.com/AmazonS3/latest/userguide/about-object-ownership.html
It happens very frequently when you replicate objects from 1 bucket to the other with tools like AWS DataSync: the replica keeps the original ownership and you start having auth issues. The page above will explain you how to fix it.
Best,
Didier
Relevant content
asked 2 years ago
asked 2 years ago
- AWS OFFICIALUpdated a year ago

All buckets were created in Aug. 2021. In other buckets, both the Object URLs with and without region name are loading without any redirection. (Browser's Network inspection shows Status 200.)
I had read somewhere that us-east-1 region has some special/different treatment. All my buckets are in us-east-1.
I understand that I must move on to start using regional end points for all documents. I am just trying to understand the reason behind current behavior/observation of a specific bucket.