# Restrict key destruction to disabled key versions

Facts read 10 Nov 2026. Page reviewed 16 Nov 2026.

Restrict key destruction to disabled key versions is a Google Cloud guardrail written in organization Policy Service. Allows destruction only of key versions that are already in the disabled state. What it breaks: google documents that the constraint applies to both new and existing key versions.

```text
constraints/cloudkms.disableBeforeDestroy
This boolean constraint, when enforced, only allows the destruction of key versions that are in the disabled state. By default, key versions that are in the enabled state and key versions that are in the disabled state can be destroyed. When this constraint is enforced, it applies to both new and existing key versions.
```

- **Blocks:** Allows destruction only of key versions that are already in the disabled state. (legacy managed constraint, boolean.)
- **Breaks:** Google documents that the constraint applies to both new and existing key versions. ([source](https://cloud.google.com/resource-manager/docs/organization-policy/org-policy-constraints))
- **Test before applying:** As for every Organization Policy Service guardrail: [how to test before enforcing](/mechanisms/org-policy/)
- **Mechanism:** [Organization Policy Service (managed and legacy constraints)](/mechanisms/org-policy/): Resources in the organization, folder or project where the policy is set and its descendants; Google says application of new policies is usually not retroactive.
- **Taken from:** [provider documentation](https://cloud.google.com/resource-manager/docs/organization-policy/org-policy-constraints), provider documentation

## What the source says

"This boolean constraint, when enforced, only allows the destruction of key versions that are in the disabled state." (read 10 Nov 2026).

On what it breaks: "When this constraint is enforced, it applies to both new and existing key versions."

## Related guardrails

- [Deny KMS key deletion](/guardrails/aws-scp-deny-kms-key-deletion/): AWS, Service control policies (SCPs), encryption and keys
- [Enforce a 30-day KMS key deletion window](/guardrails/aws-scp-kms-30-day-deletion-window/): AWS, Service control policies (SCPs), encryption and keys
- [Deny disabling default EBS encryption](/guardrails/aws-scp-deny-disable-ebs-default-encryption/): AWS, Service control policies (SCPs), encryption and keys
- [Restrict which services may create resources without CMEK](/guardrails/gcp-orgpolicy-restrict-non-cmek-services/): Google Cloud, Organization Policy Service (managed and legacy constraints), encryption and keys
- [Restrict unencrypted HTTP access to Cloud Storage](/guardrails/gcp-orgpolicy-storage-secure-http-transport/): Google Cloud, Organization Policy Service (managed and legacy constraints), encryption and keys

## Related pages

- [Resource location restriction (Google Cloud Organization Policy Service)](/guardrails/gcp-orgpolicy-resource-locations/)
- [Restrict resource service usage (Google Cloud Organization Policy Service)](/guardrails/gcp-orgpolicy-restrict-service-usage/)
- [Restrict Shared VPC host project lien removal (Google Cloud Organization Policy Service)](/guardrails/gcp-orgpolicy-restrict-xpn-lien-removal/)

## Sources

- Restrict key destruction to disabled key versions: https://cloud.google.com/resource-manager/docs/organization-policy/org-policy-constraints (read 10 Nov 2026)
- How to test it first: https://cloud.google.com/resource-manager/docs/organization-policy/dry-run-policy (read 10 Nov 2026)

Last reviewed 16 Nov 2026. Canonical: https://cloudgovernancetools.com/guardrails/gcp-orgpolicy-kms-disable-before-destroy/
