DEV Community

Cover image for Checking TPM 2.0 and Secure Boot from PowerShell before a Windows 11 upgrade (read-only)
Dijital Lisans
Dijital Lisans

Posted on Edited on

Checking TPM 2.0 and Secure Boot from PowerShell before a Windows 11 upgrade (read-only)

Before a Windows 10 PC is upgraded to Windows 11, three firmware-level facts decide most failures: whether a TPM 2.0 is visible to the operating system, whether the machine can use Secure Boot, and how the boot disk is partitioned. All three can be read from PowerShell without changing anything.

A disclosure first. The script below was written from Microsoft's documentation and has not been run on Windows by the author; there was no Windows machine available while writing. Where an output is shown, it is labelled as Microsoft's documented example. Test it on one machine before rolling it out.

What Microsoft lists as the minimum

From Microsoft's Windows 11 specifications page, re-read on 2026-11-27:

Component Minimum
Processor 1 GHz or faster, at least two cores, on a compatible 64-bit CPU or SoC
RAM 4 GB
Storage 64 GB or more
System firmware "UEFI, Secure Boot capable."
TPM Version 2.0
Graphics DirectX 12 or later with a WDDM 2.0 driver
Display High definition (720p), "greater than 9" diagonally", 8 bits per colour channel
Account Home and Pro for personal use need internet and a Microsoft account at first setup

Two details worth knowing. The Learn requirements page words the display line differently ("9" or greater monitor"), and the two pages therefore disagree about a panel of exactly 9 inches; we do not assert which one applies. And to upgrade directly from Windows 10, the device must run version 2004 or later; the Learn page adds the 14 September 2021 security update or later.

TPM and Secure Boot check flow

TPM: presence versus version

Get-Tpm returns a TPM object. Microsoft's reference lists TpmPresent, TpmReady, ManagedAuthLevel, OwnerAuth, OwnerClearDisabled, AutoProvisioning, LockedOut, LockoutHealTime, LockoutCount, LockoutMax and SelfTest. It does not print the specification version, so it cannot tell a TPM 1.2 from a 2.0. Also note how Microsoft defines TpmReady: "whether a TPM complies with Windows Server 2012 standards", which is not a statement about Windows 11.

Microsoft's documented example, trimmed (an Intel system in their page, not output from our run):

TpmPresent                : True
TpmReady                  : True
ManufacturerVersion       : 402.1.0.0
Enter fullscreen mode Exit fullscreen mode

For the version, two documented routes exist. The GUI route: run tpm.msc and read Specification Version under TPM Manufacturer Information; Microsoft says it should be 2.0, and "Compatible TPM cannot be found" means the TPM may be disabled in firmware. The same support page names the Windows Security route: Device security > Security processor details. The script route is the Win32_Tpm WMI class (namespace Root\CIMV2\Security\MicrosoftTpm). Its SpecVersion string holds "the major and minor TCG specification version, the specification revision level, and the errata revision level"; Microsoft's example for a 1.2 device is "1.2, 2, 0", so a 2.0 device should begin with 2.0. If data is unavailable the property returns "Not Supported".

Secure Boot: three outcomes and an error

Confirm-SecureBootUEFI must run in an administrator PowerShell. Microsoft documents these results:

Result Meaning
True Supported and enabled
False Supported and disabled
Cmdlet not supported on this platform. The computer does not support Secure Boot, or is a BIOS (non-UEFI) computer
Unable to set proper privileges. Access was denied. PowerShell is not elevated

The Windows 11 requirement is worded "Secure Boot capable", which is a different thing from "currently enabled". False therefore does not disqualify a PC; the "not supported" message is the one to investigate. Microsoft's Secure Boot support page notes that some firmware boots in legacy mode (also called CSM) and that the boot mode may need to move to UEFI.

msinfo32 is a GUI cross-check. Microsoft's Secure Boot servicing page documents one label: press Windows + R, type msinfo32, press Enter, and in the System Information window look for Secure Boot State; Microsoft says that if it reads On, you are fine. Some guides also mention a "BIOS Mode" line there, but we found that label on no Microsoft page, so we do not rely on it. Two other documented cross-checks need no script: Windows Security > Device security, which has a "Secure boot" section next to "Security processor", and the cmdlet above.

GPT or MBR, and why it matters here

Microsoft's MBR2GPT page documents Get-Disk | ft -Auto, whose example output has a Partition Style column showing MBR or GPT. In the storage class reference, PartitionStyle is 0 Unknown, 1 MBR or 2 GPT. The reason to look: that page says that after a disk is converted to GPT "the firmware must be reconfigured to boot in UEFI mode", and the tool's own output warns that the disk "can only be booted in GPT mode" and "These changes cannot be undone!". Layout, firmware mode and Secure Boot are linked, so an MBR system disk is a signal to plan, not to flip a firmware switch. This article does not cover conversion.

One summary line per check

# Read-only. Written from Microsoft's documentation; not run on Windows by the author.
function Line($name, $text) { "{0,-18} {1}" -f $name, $text }

try { Line 'OS version' (Get-ComputerInfo -Property OsVersion -ErrorAction Stop).OsVersion }
catch { Line 'OS version' "unreadable: $($_.Exception.Message)" }

try { $t = Get-Tpm -ErrorAction Stop; Line 'TPM present/ready' "$($t.TpmPresent) / $($t.TpmReady)" }
catch { Line 'TPM present/ready' "Get-Tpm failed: $($_.Exception.Message)" }

try {
  $w = Get-CimInstance -Namespace 'root/cimv2/security/microsofttpm' -ClassName Win32_Tpm -ErrorAction Stop
  if ($w) { Line 'TPM SpecVersion' $w.SpecVersion } else { Line 'TPM SpecVersion' 'no TPM instance returned' }
} catch { Line 'TPM SpecVersion' "not readable: $($_.Exception.Message)" }

try {
  $sb = Confirm-SecureBootUEFI -ErrorAction Stop
  Line 'Secure Boot' $(if ($sb) { 'True (enabled)' } else { 'False (capable, disabled)' })
} catch {
  $m = $_.Exception.Message
  if     ($m -match 'not supported on this platform') { Line 'Secure Boot' 'not supported (BIOS/legacy mode or no support)' }
  elseif ($m -match 'privileges|denied')              { Line 'Secure Boot' 'needs an administrator PowerShell' }
  else                                                { Line 'Secure Boot' "error: $m" }
}

try { Get-Disk -ErrorAction Stop | ForEach-Object { Line "Disk $($_.Number)" "$($_.PartitionStyle), boot disk: $($_.IsBoot)" } }
catch { Line 'Disks' "Get-Disk failed: $($_.Exception.Message)" }
Enter fullscreen mode Exit fullscreen mode

The output is plain text, so a fleet tool can collect it. Nothing in the script writes, clears, initialises or enables anything. Get-Tpm also has siblings (Clear-Tpm, Initialize-Tpm) that are deliberately not used.

What these checks cannot tell you

  • CPU support. Processor compatibility is a list, not a feature flag. Microsoft's processor-requirements page tells customers to use PC Health Check to determine eligibility.
  • Everything else on the table. RAM, storage, DirectX 12 with WDDM 2.0 and the display are not covered here. Microsoft notes that PC Health Check itself does not check the graphics card or display.
  • Whether the upgrade is offered. PC Health Check runs an eligibility check against the minimum requirements; separately, Microsoft's page says it can delay an upgrade while a known compatibility issue is open.

A pass on all four lines means the firmware-level prerequisites look right. It does not mean the PC is eligible. For the firmware settings themselves, the steps differ by manufacturer; we keep a longer guide on enabling TPM 2.0 and Secure Boot.

Sources

All checked 2026-11-27.

If the checks pass and you are moving to Windows 11, we sell a Windows 11 Pro key; the installer side is in our guide to creating a Windows 11 installation USB.

Written by the Dijital Lisans team.
We run an online store that sells software licences; this article is not sponsored and links to our own longer guide where relevant.

About the author: Dijital Lisans sells software licence keys and subscriptions and buys its keys from licensed main-supplier wholesalers; we are not Microsoft and make no partner or authorised-reseller claim.

Top comments (0)