Test-Win11Compatibility is a PowerShell script that evaluates a Windows system's readiness for Windows 11. It checks hardware (CPU, RAM, storage), firmware (TPM 2.0, Secure Boot), and software requirements, providing a detailed report with pass/fail indicators and remediation advice. Ideal for IT administrators and users planning a Windows 11 upgrade, this script is part of the Test-Win11Compatibility repository.
- Validates CPU (generation/cores), TPM 2.0, Secure Boot, RAM (≥4GB), and storage (≥64GB).
- Confirms UEFI firmware and DirectX 12/WDDM 2.0 graphics compatibility.
- Advises on Microsoft Account requirements (optional in some cases).
- Outputs a color-coded console report with detailed explanations.
- Optionally exports results to CSV, XML, or JSON files, or generates an HTML report.
- Non-invasive, read-only checks with no system modifications.
- PowerShell Version: 5.1 or later (PowerShell 7.x recommended).
- Operating System: Windows 10 (version 2004+) or Windows 11, x64 architecture.
- Modules: None; uses built-in cmdlets (
Get-CimInstance,Get-WmiObject,dism,Get-ComputerInfo). - Permissions: Standard user for most checks; Administrator for full TPM/Secure Boot access unless
-NoElevationis used. - Dependencies: .NET Framework 4.8 or later (included in supported Windows versions).
-
Clone the Repository:
git clone https://github.com/ndomako/Test-Win11Compatibility.git cd Test-Win11Compatibility -
Download the Script:
- Visit Test-Win11Compatibility.ps1.
- Click "Raw" and save as
Test-Win11Compatibility.ps1(e.g., toC:\Scripts\).
-
Set Execution Policy (if needed):
- Run as Administrator:
Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser
- Run as Administrator:
-
Console Report: Display compatibility results in PowerShell:
.\Test-Win11Compatibility.ps1- Shows a formatted report with ✅ Pass, ❌ Fail, or
⚠️ Warning for each requirement.
- Shows a formatted report with ✅ Pass, ❌ Fail, or
-
Export to JSON: Save results to a JSON file for analysis:
.\Test-Win11Compatibility.ps1 -ExportResults -ExportFormat JSON -ExportPath "C:\Reports\Win11Report.json"
- Generates a JSON file with requirement details and recommendations.
-
Generate HTML Report: Create an HTML report for sharing:
.\Test-Win11Compatibility.ps1 -ExportHTML -ExportPath "C:\Reports\Win11Report.html"
-
-DriveLetter(Optional, String):- Description: Specifies the drive letter to check for storage requirements (e.g., available disk space). Must be a single uppercase letter (A-Z).
- Expected Type: System.String (e.g.,
"C"). - Default:
"C". - Example:
-DriveLetter D.
-
-ExportResults(Optional, Switch):- Description: Enables exporting the compatibility results to a file in the format specified by
-ExportFormat. - Expected Type: SwitchParameter (no value needed).
- Default: False (no export).
- Example:
-ExportResults.
- Description: Enables exporting the compatibility results to a file in the format specified by
-
-ExportFormat(Optional, String):- Description: Specifies the file format for exported results when
-ExportResultsis used. Valid options areXML,JSON, orCSV. - Expected Type: System.String (must be
"XML","JSON", or"CSV"). - Default:
"XML". - Example:
-ExportFormat CSV.
- Description: Specifies the file format for exported results when
-
-ExportPath(Optional, String):- Description: Specifies the file path or directory to save the exported results. If a directory is provided, the script generates a filename with a timestamp (e.g.,
Win11Report_2025-10-20.xml). If a file path is provided, it uses the specified filename. - Expected Type: System.String (e.g.,
"C:\Reports\Win11Report.csv"or"C:\Reports\"). - Default:
".\"(current directory). - Example:
-ExportPath "C:\Reports\report.json".
- Description: Specifies the file path or directory to save the exported results. If a directory is provided, the script generates a filename with a timestamp (e.g.,
-
-ExportHTML(Optional, Switch):- Description: Generates an HTML report of the compatibility results, saved to the path specified by
-ExportPath. Overrides-ExportFormatif both are specified. - Expected Type: SwitchParameter (no value needed).
- Default: False (no HTML export).
- Example:
-ExportHTML.
- Description: Generates an HTML report of the compatibility results, saved to the path specified by
-
-NoElevation(Optional, Switch):- Description: Runs the script without requiring administrative privileges. Some checks (e.g., TPM, Secure Boot) may be limited or skipped if elevation is not available.
- Expected Type: SwitchParameter (no value needed).
- Default: False (attempts elevated checks).
- Example:
-NoElevation.
- Console: Color-coded report with:
- Requirement headers (e.g., "CPU Check", "TPM Check").
- Status indicators and details (e.g., "TPM: 2.0 - Compatible").
- Summary (e.g., "7/8 Requirements Met").
- File Export (with
-ExportResultsor-ExportHTML): Results in CSV, XML, JSON, or HTML format, with columns/fields for Requirement, Status, Details, and Recommendation. - Exit Code: 0 (fully compatible), 1 (issues detected).
No system changes are made.
-
Errors:
- Permission Denied (TPM/Secure Boot): Run as Administrator or use
-NoElevation:Start-Process powershell -Verb RunAs -ArgumentList "-File .\Test-Win11Compatibility.ps1"
- WMI/CIM Failure: Ensure WMI service is running:
Restart-Service Winmgmt - Old Windows Version: Update to Windows 10 2004+ if warnings appear.
- Permission Denied (TPM/Secure Boot): Run as Administrator or use
-
Issues:
- Virtual machines may misreport TPM/Secure Boot; verify in host BIOS/UEFI.
- ARM64 systems (e.g., Surface Pro X) may show false negatives.
- DirectX check failures? Confirm with
dxdiag.
-
Troubleshooting:
- Check execution policy:
Get-ExecutionPolicy. - Test cmdlets:
Get-Tpm,Get-CimInstance Win32_OperatingSystem. - Review Event Logs (Event Viewer > Windows Logs > System).
- Report issues at GitHub Issues.
- Check execution policy:
Contributions are welcome! To contribute:
- Fork the repository.
- Create a feature branch (
git checkout -b feature/new-check). - Commit changes (
git commit -m "Add new check"). - Push to the branch (
git push origin feature/new-check). - Open a pull request.
See CONTRIBUTING.md for details.
MIT License
Copyright (c) 2025 Ndomako
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
- Ndomako (GitHub) - Creator and maintainer.
For questions or feedback, open a discussion at GitHub Discussions.
Last Updated: October 20, 2025