Self-hosted S3 server · plain PHP 8.1+ · zero runtime dependencies
S3 object storage on the hosting you already pay for.
php-s3 speaks the real S3 API: SigV4 auth, multipart uploads, presigned URLs, range requests, and streaming in constant memory. Upload it, run the browser installer, point any S3 client at it. No daemons, no Docker, no root, and no Composer on the server.
- PHP 8.1+
- MySQL 5.7+ / MariaDB 10.3+
- 0 runtime dependencies
- 223 tests · 386 assertions
- Apache · LiteSpeed · nginx · Caddy
What is in the box
- 01
Signature verification with no bypass flags
Header mode, presigned query URLs from 1 second to 7 days, and aws-chunked streams with a per-chunk signature chain. Every request is verified with constant-time comparisons. There is no simple-auth mode to forget to turn off.
- 02
Streaming in constant memory
Uploads and downloads run as a 64 KiB loop while MD5 and SHA-256 are computed on the way through. A multi-gigabyte object never sits in RAM, which matters when your PHP memory limit is 256 MB.
- 03
Listings that stay fast
MySQL is the index. Objects live at sha256-sharded paths, so one directory never holds millions of entries and pagination does not degrade into a full disk scan.
- 04
Storage that cannot be traversed
Object keys never touch the filesystem path. Paths are derived from a hash and a UUID, the data root lives outside the web root, and containment is checked with realpath on every read and delete.
- 05
A panel you can actually run
Browser installer, session login with throttling, access keys with per-bucket scoping, usage statistics, and a CLI for migrations, garbage collection, doctor checks, and key creation.
The honest comparison
Summary of the four open-source PHP projects studied in full source before php-s3 existed. Yes, partial, and no are read straight from that audit, not from marketing pages.
| Capability | php-s3 | opsfour/s3-server | simple-php-s3-server | lite-s3 | buckie-php |
|---|---|---|---|---|---|
| Real S3 XML API with SigV4 | yes | yes | yes | partial | no |
| Signature verified on every request | yes | yes | partial | no | no |
| Runs on shared hosting, no daemon or root | yes | no | yes | yes | yes |
| Streaming uploads and downloads | yes | yes | no | partial | yes |
| Database-indexed listings | yes | yes | no | yes | no |
| Multipart with AWS-format ETags | yes | yes | yes | partial | no |
| Presigned URLs with expiry | yes | yes | partial | partial | no |
| aws-chunked with per-chunk signatures | yes | yes | no | no | no |
| Web installer and admin panel | yes | no | no | yes | no |
| Automated tests in repo | 223 | 745 | none | none | 56 |
opsfour/s3-server is the best-in-class PHP S3 server and we openly credit it as the quality bar. php-s3 targets the same correctness without PHP 8.4, fibers, or a long-running worker. Full source audit in the research notes.
From upload to endpoint in three steps
Upload the files
Clone the repository or drop the release into your document root. No build step on the server.
# extract the release, then
composer install --no-devRun the installer
One form: database credentials, your admin account, and the data directory outside the web root.
# open on your domain
/_admin/installPoint your client
Create a bucket and an access key in the panel, then connect any S3 tool with path-style addressing. Replace DOMAIN with your endpoint.
# real request, real signature
aws --endpoint-url https://DOMAIN s3 lsAPI coverage
Buckets
- ListBuckets
- CreateBucket
- HeadBucket
- DeleteBucket
Objects
- PutObject
- GetObject + Range
- HeadObject
- DeleteObject
- CopyObject
Listing
- ListObjectsV1
- ListObjectsV2
- Prefix + delimiter
- Continuation tokens
Batch
- DeleteObjects
- 1000 keys per call
- Quiet mode
Multipart
- Create
- UploadPart
- Complete
- Abort
- ListParts
- ListUploads
Auth and transport
- SigV4 header mode
- Presigned URLs
- aws-chunked signed chain
- Unsigned trailers
Not yet: versioning, ACLs and policies, checksum trailers, public access. Evidence for every operation lives in the compatibility matrix.
What php-s3 is not
- Backups
- It is storage, not a backup service. The disk is yours, so the backup plan is yours.
- Multi-tenancy
- One owner, many scoped access keys. There are no client accounts and no sign-up.
- Public access
- Every request is signed. There is no anonymous mode and no public-read bucket flag.
- Performance
- As fast as your host's disk and PHP worker limit, and honest about both.
- Finished
- Versioning, ACLs, and checksum trailers are on the roadmap, not in a release note.