Here is a PowerShell script that sets the pause duration for Windows Updates to 100 years from today.
It calculates the current date, adds 100 years (36,525 days), and updates the Windows Update registry parameters directly.
PowerShell Script (Applies Immediately)
Run this script in an Elevated PowerShell Window (Run as Administrator):
# Requires Administrator Privileges
# Calculate timestamps for today and 100 years into the future
$startDate = (Get-Date).ToUniversalTime().ToString("yyyy-MM-ddTHH:mm:ssZ")
$endDate = (Get-Date).AddYears(100).ToUniversalTime().ToString("yyyy-MM-ddTHH:mm:ssZ")
$regPath = "HKLM:\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings"
# Ensure the registry path exists
if (-not (Test-Path $regPath)) {
New-Item -Path $regPath -Force | Out-Null
}
# Update pause timestamps in registry
Set-ItemProperty -Path $regPath -Name "PauseUpdatesStartTime" -Value $startDate -Force
Set-ItemProperty -Path $regPath -Name "PauseUpdatesExpiryTime" -Value $endDate -Force
Set-ItemProperty -Path $regPath -Name "PauseFeatureUpdatesStartTime" -Value $startDate -Force
Set-ItemProperty -Path $regPath -Name "PauseFeatureUpdatesEndTime" -Value $endDate -Force
Set-ItemProperty -Path $regPath -Name "PauseQualityUpdatesStartTime" -Value $startDate -Force
Set-ItemProperty -Path $regPath -Name "PauseQualityUpdatesEndTime" -Value $endDate -Force
Write-Host "Windows Updates successfully paused until $((Get-Date).AddYears(100).ToString('yyyy-MM-dd'))!" -ForegroundColor Green
Check the result at Windows Update:

How to Revert / Resume Updates
To unpause Windows Updates at any time, open PowerShell as Administrator and run:
$regPath = "HKLM:\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings"
Remove-ItemProperty -Path $regPath -Name "PauseUpdatesStartTime" -ErrorAction SilentlyContinue
Remove-ItemProperty -Path $regPath -Name "PauseUpdatesExpiryTime" -ErrorAction SilentlyContinue
Remove-ItemProperty -Path $regPath -Name "PauseFeatureUpdatesStartTime" -ErrorAction SilentlyContinue
Remove-ItemProperty -Path $regPath -Name "PauseFeatureUpdatesEndTime" -ErrorAction SilentlyContinue
Remove-ItemProperty -Path $regPath -Name "PauseQualityUpdatesStartTime" -ErrorAction SilentlyContinue
Remove-ItemProperty -Path $regPath -Name "PauseQualityUpdatesEndTime" -ErrorAction SilentlyContinue
Write-Host "Windows Updates resumed!" -ForegroundColor Cyan