How to download a file from S3
TL;DR
Three patterns. In S3 Viewer, open the ⋮ menu on the row and choose Download (a 15-minute presigned URL is signed server-side, so your AWS keys never reach the browser, and the file saves under the last segment of its object key). Run aws s3 cp s3://bucket/key ./ from a terminal. Or send someone a presigned URL — Copy link in the same menu — when they don't have AWS access.
Steps
Step-by-step.
- 01
In S3 Viewer: ⋮ → Download
Open the ⋮ menu on the object's row and choose Download. The browser fetches the file straight from your bucket via a 15-minute presigned URL signed server-side with your encrypted credentials — the bytes never pass through our servers and your access key never reaches the client. The file saves under the last segment of its object key, soreports/2026/q4.pdflands on disk asq4.pdf. - 02
AWS CLI: aws s3 cp (single file)
For one file. Streams directly to disk.aws s3 cp s3://my-bucket/path/to/file.pdf ./ - 03
AWS CLI: aws s3 sync (whole prefix)
Mirrors a prefix to a local directory and skips files you already have. The right pattern for backups or local development.aws s3 sync s3://my-bucket/reports/ ./reports/ - 04
AWS SDK: GetObject
For a backend, stream the response body to a file or to a response stream.const obj = await s3.getObject({ Bucket: 'my-bucket', Key: 'file.pdf', }); await pipeline(obj.Body, fs.createWriteStream('./file.pdf')); - 05
Sharing: presigned URL for someone without AWS
Use Copy link in the row's ⋮ menu, or runaws s3 presign. Same primitive — works in any browser, expires when you say (15 minutes from S3 Viewer). Treat it as a bearer token.aws s3 presign s3://my-bucket/file.pdf --expires-in 3600
Under the hood
What's actually happening.
A download is a GetObject API call. The CLI streams the response body to a local file; SDKs return a readable stream you pipe wherever you want; S3 Viewer signs a 15-minute presigned URL server-side using your encrypted credentials, names the download after the last segment of the object key, and the browser fetches that URL directly from your bucket — so your AWS keys never reach the client and the bytes never pass through our servers. Sharing with a non-AWS user is the same primitive: a presigned URL is just a signed query-string version of GetObject that anyone with the link can fetch until it expires.
FAQ
Common questions.
How do I download a file from an S3 bucket?
How do I download an entire S3 prefix or folder?
How do I download a file from someone else's S3 bucket?
Why do my AWS keys never reach the client in S3 Viewer?
Can I download from Cloudflare R2 the same way?
Use S3 Viewer for this
Skip the CLI. Try it in the browser.
S3 Viewer turns the steps above into a single click. Open source, self-hostable, free.
Use case
Why teams pick this
Related guides
More how-tos
Fix Access Denied
A nine-point checklist: IAM actions and ARNs, bucket policy denies, Block Public Access, KMS keys, object ownership, and the 403-that-is-really-a-404.
Share an S3 file
Copy link for a 15-minute presigned URL, or an email invite for ongoing access — when each is the right call.
Upload large files
How large uploads work in S3 Viewer and from the CLI — streaming, retries, and the 5 GB single-PUT cap.