Docs Ordnary Web Services Ordnary R2
Bucket lock rules
Keeping objects from being deleted or overwritten for a retention period, for records that must stay unchanged.
A lock rule makes objects immutable for a number of days after they are written: they cannot be deleted or overwritten by anyone, not with the access key, not from the console, not by a lifecycle rule. Use it for records that must be kept unchanged, such as invoices or audit logs.
A rule
Prefixtext- Only objects whose key starts with it, such as
records/. Leave empty for the whole bucket. Retention (days)numberRequired- How long each object stays locked, counted from its upload.
Enabledtoggle- Switching a rule off stops it applying to new objects; objects already locked keep their retention.
Can I still read locked objects?
Yes. Only deleting and overwriting are blocked.
What happens to a new version of a locked key?
An upload to a locked key is refused; write the new version under a new key.