Windows preview pane stopped working with 10/15/2025 update -preview could harm computer

fleming 100 Reputation points
2025-10-15T14:12:18.86+00:00

Essentially, opening files takes a long time and the preview page allowed to me to check files without opening them, for moving files to/from an appraisal workfile etc. Windows update just broke this. The error message I get is "The file you are attempting to preview could harm your computer. If you trust the file and the source you received it from, open it to view its contents". This pattern is common, Windows update routinely introduces user devastating bugs and efficiency downgrades, and I wish I could permanently remove Windows update functionality from my computer. Is there a fix for this windows preview bug on the horizon?

Windows for home | Windows 11 | Windows update
{count} votes

9 answers

Sort by: Most helpful
  1. poiu qwerty 5 Reputation points
    2025-10-21T21:23:02.3333333+00:00

    I uninstalled the recent update KB5066835 and the preview pane now works.

    Hope this helps

    1 person found this answer helpful.
    0 comments No comments

  2. Dave mettetal 5 Reputation points
    2025-10-23T15:26:29.9533333+00:00

    This fix only works on a per folder basis. If you are working with multiple folders on a given drive is there a way to input a global fix for all folders?

    :

    Unblock-File -Path "C:\Users\admin\Downloads*.pdf"

    1 person found this answer helpful.
    0 comments No comments

  3. ANFAS RAWSDEEN 0 Reputation points
    2025-10-16T10:39:20.09+00:00

    then how to preview word file

    0 comments No comments

  4. tatsu ikeda 0 Reputation points
    2025-10-22T20:06:42.33+00:00

    =========================================================

    Fix Windows 11 PDF Preview Issue (KB5066835)

    =========================================================

    This script fixes the "file you are attempting to preview

    could harm your computer" error in Windows File Explorer

    Caused by: October 2025 Windows Update KB5066835

    =========================================================

    Write-Host "=====================================================" -ForegroundColor Cyan

    Write-Host " Windows 11 PDF Preview Fix Script" -ForegroundColor Cyan

    Write-Host "=====================================================" -ForegroundColor Cyan

    Write-Host ""

    Check if running as Administrator

    $isAdmin = ([Security.Principal.WindowsPrincipal] [Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole]::Administrator)

    if (-not $isAdmin) {

    Write-Host "ERROR: This script must be run as Administrator!" -ForegroundColor Red
    
    Write-Host "Right-click on PowerShell and select 'Run as Administrator'" -ForegroundColor Yellow
    
    Write-Host ""
    
    Read-Host "Press Enter to exit"
    
    exit
    

    }

    Write-Host "Running as Administrator - OK" -ForegroundColor Green

    Write-Host ""

    =========================================================

    STEP 1: Prevent future files from being blocked

    =========================================================

    Write-Host "[STEP 1] Configuring registry to prevent future file blocking..." -ForegroundColor Yellow

    try {

    # Create the registry key if it doesn't exist
    
    $regPath = "HKCU:\Software\Microsoft\Windows\CurrentVersion\Policies\Attachments"
    
    
    
    if (-not (Test-Path $regPath)) {
    
        New-Item -Path $regPath -Force | Out-Null
    
        Write-Host "  - Created registry key" -ForegroundColor Green
    
    }
    
    
    
    # Set the SaveZoneInformation value
    
    New-ItemProperty -Path $regPath -Name "SaveZoneInformation" -PropertyType DWord -Value 1 -Force | Out-Null
    
    Write-Host "  - Set SaveZoneInformation = 1" -ForegroundColor Green
    
    Write-Host "  - Future downloads will no longer be blocked!" -ForegroundColor Green
    

    } catch {

    Write-Host "  - ERROR: Failed to modify registry" -ForegroundColor Red
    
    Write-Host "  - $($_.Exception.Message)" -ForegroundColor Red
    

    }

    Write-Host ""

    =========================================================

    STEP 2: Unblock existing files

    =========================================================

    Write-Host "[STEP 2] Choose which files to unblock:" -ForegroundColor Yellow

    Write-Host ""

    Write-Host " 1. Downloads folder only (Quick - Recommended)" -ForegroundColor White

    Write-Host " 2. Documents folder only" -ForegroundColor White

    Write-Host " 3. Desktop folder only" -ForegroundColor White

    Write-Host " 4. All three folders (Downloads, Documents, Desktop)" -ForegroundColor White

    Write-Host " 5. Entire C: drive (Slow - may take several minutes)" -ForegroundColor White

    Write-Host " 6. Entire D: drive (Slow - may take several minutes)" -ForegroundColor White

    Write-Host " 7. Both C: and D: drives (Very slow - may take 10+ minutes)" -ForegroundColor White

    Write-Host " 8. Custom folder path" -ForegroundColor White

    Write-Host " 9. Skip this step" -ForegroundColor White

    Write-Host ""

    $choice = Read-Host "Enter your choice (1-9)"

    $foldersToUnblock = @()

    switch ($choice) {

    "1" { 
    
        $foldersToUnblock += "$env:USERPROFILE\Downloads"
    
    }
    
    "2" { 
    
        $foldersToUnblock += "$env:USERPROFILE\Documents"
    
    }
    
    "3" { 
    
        $foldersToUnblock += "$env:USERPROFILE\Desktop"
    
    }
    
    "4" { 
    
        $foldersToUnblock += "$env:USERPROFILE\Downloads"
    
        $foldersToUnblock += "$env:USERPROFILE\Documents"
    
        $foldersToUnblock += "$env:USERPROFILE\Desktop"
    
    }
    
    "5" { 
    
        $foldersToUnblock += "C:\"
    
    }
    
    "6" {
    
        if (Test-Path "D:\") {
    
            $foldersToUnblock += "D:\"
    
        } else {
    
            Write-Host "  - ERROR: D: drive not found" -ForegroundColor Red
    
        }
    
    }
    
    "7" {
    
        $foldersToUnblock += "C:\"
    
        if (Test-Path "D:\") {
    
            $foldersToUnblock += "D:\"
    
        } else {
    
            Write-Host "  - WARNING: D: drive not found, will only scan C:" -ForegroundColor Yellow
    
        }
    
    }
    
    "8" {
    
        $customPath = Read-Host "Enter the full path to the folder (e.g., D:\MyFolder)"
    
        if (Test-Path $customPath) {
    
            $foldersToUnblock += $customPath
    
        } else {
    
            Write-Host "  - ERROR: Path not found: $customPath" -ForegroundColor Red
    
        }
    
    }
    
    "9" {
    
        Write-Host "  - Skipping file unblocking" -ForegroundColor Yellow
    
    }
    
    default {
    
        Write-Host "  - Invalid choice. Skipping file unblocking." -ForegroundColor Red
    
    }
    

    }

    Write-Host ""

    foreach ($folder in $foldersToUnblock) {

    Write-Host "  - Unblocking files in: $folder" -ForegroundColor Cyan
    
    
    
    try {
    
        $files = Get-ChildItem -Path $folder -Recurse -ErrorAction SilentlyContinue
    
        $totalFiles = $files.Count
    
        $unblocked = 0
    
        
    
        Write-Host "    Found $totalFiles files to check..." -ForegroundColor White
    
        
    
        foreach ($file in $files) {
    
            try {
    
                Unblock-File -Path $file.FullName -ErrorAction SilentlyContinue
    
                $unblocked++
    
            } catch {
    
                # Silently continue on errors (files in use, permission issues, etc.)
    
            }
    
        }
    
        
    
        Write-Host "    Processed $unblocked files successfully!" -ForegroundColor Green
    
    } catch {
    
        Write-Host "    ERROR: $($_.Exception.Message)" -ForegroundColor Red
    
    }
    

    }

    =========================================================

    STEP 3: Restart File Explorer

    =========================================================

    Write-Host ""

    Write-Host "[STEP 3] Restart Windows Explorer to apply changes?" -ForegroundColor Yellow

    $restart = Read-Host "Restart Explorer now? (Y/N)"

    if ($restart -eq "Y" -or $restart -eq "y") {

    Write-Host "  - Restarting Windows Explorer..." -ForegroundColor Cyan
    
    Stop-Process -Name explorer -Force
    
    Start-Sleep -Seconds 2
    
    Start-Process explorer
    
    Write-Host "  - Windows Explorer restarted!" -ForegroundColor Green
    

    } else {

    Write-Host "  - Skipped. Please restart Explorer manually or reboot your PC." -ForegroundColor Yellow
    

    }

    =========================================================

    COMPLETION

    =========================================================

    Write-Host ""

    Write-Host "=====================================================" -ForegroundColor Cyan

    Write-Host " Script completed!" -ForegroundColor Green

    Write-Host "=====================================================" -ForegroundColor Cyan

    Write-Host ""

    Write-Host "What was done:" -ForegroundColor White

    Write-Host " ✓ Registry updated to prevent future file blocking" -ForegroundColor Green

    Write-Host " ✓ Existing files unblocked (if selected)" -ForegroundColor Green

    Write-Host ""

    Write-Host "If you still see the preview warning:" -ForegroundColor Yellow

    Write-Host " 1. Restart your computer" -ForegroundColor White

    Write-Host " 2. Or consider uninstalling update KB5066835:" -ForegroundColor White

    Write-Host " Settings > Windows Update > Update History > Uninstall Updates" -ForegroundColor White

    Write-Host ""

    Read-Host "Press Enter to exit"


Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.