Stay organized with collectionsSave and categorize content based on your preferences.
Updates the metadata of a bucket. Changes to the bucket are readable immediately after
writing, but configuration changes may take time to propagate.
Required permissions
To use this method,the authenticated user must have thestorage.buckets.updateIAM
permission. Additionally, to perform specific actions on a bucket, the authenticated user must have the following permissions:
To update public access prevention policies or access control lists
(ACLs):storage.buckets.setIamPolicy
To return ACLs on a bucket:storage.buckets.getIamPolicy
To update bucket IP filtering rules:storage.buckets.setIpFilter
To return bucket IP filtering rules as part of the response:storage.buckets.getIpFilter
Request
HTTP request
PUT https://storage.googleapis.com/storage/v1/b/bucket
In the request body, supply abucket
resourcewith the following properties:
Property name
Value
Description
Notes
Required Properties
acl[]
list
Access controls on the bucket. If empty, this parameter is ignored. Can contain one or morebucketAccessControls Resources.
writable
Optional Properties
autoclass
object
Thebucket's Autoclass
configuration, which, when enabled, controls the storage class of objects based on how
and when the objects are accessed. For more information, seeAutoclass.
Whether or not to automatically apply aneventBasedHoldto new
objects added to the bucket.
writable
defaultObjectAcl[]
list
Default access controls to apply to new objects when no ACL is provided. This list
defines anentityandrolefor one or moredefaultObjectAccessControls
Resources. IfiamConfiguration.uniformBucketLevelAccess.enabledis set
totrue, this field is omitted in responses, and requests that specify this
field fail with a400 Bad Requestresponse.
The recovery point objective for cross-region replication of the bucket. Applicable only
for dual- and multi-region buckets."DEFAULT"uses default replication."ASYNC_TURBO"enables turbo replication, valid for dual-region buckets only.
For more information, seeredundancy across regions.
The bucket's default storage class, used whenever nostorageClassis
specified for a newly-created object. For available storage classes,
seeStorage classes.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-09-04 UTC."],[],[],null,["# Buckets: update\n\nUpdates the metadata of a bucket. Changes to the bucket are readable immediately after\nwriting, but configuration changes may take time to propagate.\n| **Caution:** You should generally use the [PATCH](/storage/docs/json_api/v1/buckets/patch) method, which changes only metadata you define in the request. The UPDATE method might change certain metadata for the bucket even if that metadata is not specified in the request.\n\nRequired permissions\n--------------------\n\nTo use this method,the authenticated user must have the `storage.buckets.update` IAM\npermission. Additionally, to perform specific actions on a bucket, the authenticated user must have the following permissions:\n\n- To update public access prevention policies or access control lists (ACLs): `storage.buckets.setIamPolicy`\n- To return ACLs on a bucket: `storage.buckets.getIamPolicy`\n- To update bucket IP filtering rules: `storage.buckets.setIpFilter`\n- To return bucket IP filtering rules as part of the response: `storage.buckets.getIpFilter`\n\nRequest\n-------\n\n### HTTP request\n\n```\nPUT https://storage.googleapis.com/storage/v1/b/bucket\n```\n\nIn addition to [standard query parameters](/storage/docs/json_api/v1/parameters#query),\nthe following query parameters apply to this method.\n\nTo see an example of how to include query parameters in a request, see the\n[JSON API Overview](/storage/docs/json_api#query_parameters) page.\n\n### Parameters\n\n### Request body\n\nIn the request body, supply a [bucket\nresource](/storage/docs/json_api/v1/buckets#resource) with the following properties:\n\nResponse\n--------\n\nIf successful, this method returns a [bucket\nresource](/storage/docs/json_api/v1/buckets#resource) in the response body.\n\nFor information about status and error codes returned by this API, see the\n[reference page](/storage/docs/json_api/v1/status-codes).\n\nTry it!\n-------\n\n\nUse the APIs Explorer below to call this method on live data and see the response."]]