Commands › SharePoint Online
Update-SPODataEncryptionPolicy
Updates customer encryption status for a geo tenant.
Quick start script
# Update-SPODataEncryptionPolicy — quick start (serv365.ai)
# 1. Connect (app-only shown; interactive: omit the certificate parameters)
Connect-SPOService -Url https://$org-admin.sharepoint.com
# 2. Capture the current state first — you cannot roll back what you never recorded
$before = Get-SPODataEncryptionPolicy
$before | Format-List
# 3. Make the change (dry run first)
Update-SPODataEncryptionPolicy -KeyName <String> -KeyType <CustomerKeyVaultKeyType> -KeyVaultName <String> -WhatIf
Update-SPODataEncryptionPolicy -KeyName <String> -KeyType <CustomerKeyVaultKeyType> -KeyVaultName <String>
# 4. Verify and diff
$after = Get-SPODataEncryptionPolicy
Compare-Object ($before | Out-String) ($after | Out-String)
Syntax — 2 parameter sets
BYOK_MultipleParameters (Default)
Update-SPODataEncryptionPolicy -KeyVaultName <String> -KeyName <String> -KeyVersion <Guid>
-KeyType <CustomerKeyVaultKeyType> [-WhatIf] [-Confirm] [<CommonParameters>]
BYOK_Uri
Update-SPODataEncryptionPolicy -KeyVaultUri <Uri> -KeyType <CustomerKeyVaultKeyType> [-WhatIf] [-Confirm]
[<CommonParameters>]
Parameters (7)
Reference facts derived from Microsoft documentation, © Microsoft, licensed CC BY 4.0; restructured with original guidance by serv365.ai.