Why am I getting an Access Denied error when I open the link to an Amazon S3 object that I have access to?
Last updated: 2021-04-13
I have the permission to access an object in Amazon Simple Storage Service (Amazon S3). But when I open the HTTPS link provided in the Amazon S3 console for that object, I get an Access Denied error message. How can I fix this?
Instead of opening the HTTPS link to the object, use the Amazon S3 console to download the object. When you download the object, the request includes the credentials that you used to sign in to the Amazon S3 console.
The HTTPS link to the object doesn't include your user credentials, so the request to the object is anonymous. Amazon S3 returns an Access Denied error for anonymous requests to objects that aren't public. To include the user credentials in the object request, consider setting up a presigned URL.
It's a security best practice to keep objects private and to set up users with a presigned URL for authenticated requests to access objects. However, if your use case supports public read access to your objects, modify the permissions for the objects. To set up public read access to the object, see Granting read-only permission to an anonymous user.