Home/Tutorials/AWS/Error fix
Error fixAWS · 3 min read · Updated 4 Dec 2026

AWS S3 Access Denied (403): Causes and How to Fix

S3 AccessDenied (403) comes from IAM policies, bucket policies, Block Public Access, KMS keys or object ownership. Find which one blocks you and fix it.

QUICK ANSWERS3 returns AccessDenied (HTTP 403) when any policy in the chain says no, or none says yes. Check in this order: the IAM policy of the user or role, the bucket policy (an explicit Deny wins), S3 Block Public Access for public files, the KMS key policy for encrypted objects, and object ownership when another account uploaded the file. CloudTrail and the IAM Policy Simulator show which one blocked the request.
AWS S3 AccessDenied 403: causes and fixes
AWS S3 AccessDenied 403: causes and fixes

How S3 decides allow or deny

For every request AWS evaluates all policies that apply: the caller's IAM policies, the bucket policy, any SCP from AWS Organizations, VPC endpoint policies and, for encrypted objects, the KMS key policy. An explicit Deny anywhere wins. Otherwise at least one policy must Allow the exact action (for example s3:GetObject) on the exact resource ARN.

A very common mistake is the ARN: arn:aws:s3:::my-bucket covers bucket actions such as ListBucket, while objects need arn:aws:s3:::my-bucket/*.

Causes and fixes

CauseSignFix
IAM policy missing the actionWorks for admin, fails for app roleAdd s3:GetObject/PutObject on bucket/*
Wrong resource ARNListBucket works, GetObject fails (or the reverse)Use both bucket and bucket/* ARNs
Bucket policy DenyDenied even for admins; often a condition on VPC endpoint, IP or TLSRead the bucket policy conditions
Block Public Access onPublic website or public file gives 403Prefer CloudFront with Origin Access Control; only turn off BPA deliberately
KMS key not allowedError mentions KMS, or only encrypted objects failGrant kms:Decrypt (and GenerateDataKey for uploads) in the key policy or IAM
Object owned by another accountCross-account uploads unreadableSet Object Ownership to "Bucket owner enforced"
Object does not exist and no ListBucket403 instead of 404Grant s3:ListBucket to see 404 for missing keys

Fix it step by step

  1. Confirm who you are: aws sts get-caller-identity. Many "bugs" are the wrong profile or role.
  2. Reproduce with the CLI: aws s3api get-object --bucket my-bucket --key path/file.txt out.txt.
  3. Check the caller's IAM policy covers the action and the bucket/* ARN. Test it in the IAM Policy Simulator.
  4. Open the bucket policy and look for "Effect": "Deny" with conditions such as aws:SourceVpce, aws:SecureTransport or IP ranges.
  5. If the object is SSE-KMS encrypted, check the key policy allows the caller to decrypt.
  6. For public content, keep Block Public Access on and serve through CloudFront with Origin Access Control.
  7. Still stuck: find the denied call in CloudTrail (event GetObject with errorCode AccessDenied); newer error messages also say which policy type denied it.

Questions

Why do I get 403 instead of 404 for a missing file?

Without s3:ListBucket permission S3 will not tell you whether the key exists, so it returns 403 for missing objects.

Should I turn off Block Public Access to fix 403?

Only for a deliberate public bucket. For websites, CloudFront with Origin Access Control keeps the bucket private and is the recommended setup.

Does an explicit Deny in the bucket policy beat an admin IAM policy?

Yes. An explicit Deny in any policy always wins over any Allow.