Skip to main content
HWID Checker
hwidwindowswmictutorial

HWID .bat Alternative for Windows 11 24H2

Replace legacy wmic-based HWID batch commands with PowerShell CIM queries or a portable Windows utility that creates a composite SHA-256 hardware ID.

HWID Checker Β· August 24, 2026 Β· 5 min read

If you have used an hwidChecker.bat script that runs wmic diskdrive get serialnumber, wmic cpu get serialnumber, wmic bios get serialnumber, wmic baseboard get serialnumber, and wmic csproduct get uuid, it may fail on a fresh Windows 11 installation. wmic.exe is deprecated and the WMIC Feature on Demand is disabled by default on Windows 11 24H2. PowerShell CIM cmdlets are the supported replacement.

This article explains what changed, shows the supported PowerShell equivalents, and introduces a local Windows utility that creates a composite report without wmic.

What the .bat script does

The script is simple and does its job well β€” on older Windows:

@ECHO OFF
wmic diskdrive get model, serialnumber
wmic cpu get serialnumber
wmic bios get serialnumber
wmic baseboard get serialnumber
wmic path win32_computersystemproduct get uuid
getmac

It attempts to print several hardware-related values and a MAC address without a network request. Its main limitation is now compatibility: the script depends on a deprecated command that may not be installed.

Why it is breaking

wmic.exe (Windows Management Instrumentation Command-line) has been deprecated since Windows 10 21H1. On Windows 11 24H2, WMIC is a disabled-by-default optional Feature on Demand. Microsoft's migration guidance is to use PowerShell CIM cmdlets or programmatic WMI APIs instead.

If you run the script on a fresh 24H2 install, you will see:

'wmic' is not recognized as an internal or external command,
operable program or batch file.

You can still install wmic manually via Optional Features, but that is a workaround, not a fix β€” Microsoft has stated it will be removed entirely in a future release.

The PowerShell replacement (no download needed)

If you just want the same output as the .bat script, replace each wmic line with the equivalent PowerShell CIM cmdlet. Open PowerShell and paste:

# Disk serials (replaces: wmic diskdrive get model, serialnumber)
Get-CimInstance Win32_DiskDrive | Select-Object Model, SerialNumber

# CPU (replaces: wmic cpu get serialnumber)
Get-CimInstance Win32_Processor | Select-Object Name, ProcessorId

# BIOS serial (replaces: wmic bios get serialnumber)
Get-CimInstance Win32_BIOS | Select-Object SerialNumber

# Motherboard serial (replaces: wmic baseboard get serialnumber)
Get-CimInstance Win32_BaseBoard | Select-Object SerialNumber

# SMBIOS UUID (replaces: wmic csproduct get uuid)
Get-CimInstance Win32_ComputerSystemProduct | Select-Object UUID

# MAC addresses (replaces: getmac)
Get-NetAdapter | Select-Object Name, MacAddress

These commands work on every Windows version from 10 through 11 24H2 and later. They use the same WMI data under the hood, just through the modern PowerShell API instead of the deprecated wmic.exe wrapper.

Save it as a .ps1 file if you want a one-click script like the old .bat:

# hwid-checker.ps1 β€” modern replacement for hwidChecker.bat
Clear-Host
Write-Host "=== HWID Checker ===" -ForegroundColor Cyan
Write-Host ""
Write-Host "Disk drives:" -ForegroundColor Yellow
Get-CimInstance Win32_DiskDrive | Format-Table Model, SerialNumber -AutoSize
Write-Host "CPU:" -ForegroundColor Yellow
Get-CimInstance Win32_Processor | Format-Table Name, ProcessorId -AutoSize
Write-Host "BIOS:" -ForegroundColor Yellow
Get-CimInstance Win32_BIOS | Format-Table SerialNumber -AutoSize
Write-Host "Motherboard:" -ForegroundColor Yellow
Get-CimInstance Win32_BaseBoard | Format-Table SerialNumber -AutoSize
Write-Host "SMBIOS UUID:" -ForegroundColor Yellow
Get-CimInstance Win32_ComputerSystemProduct | Format-Table UUID -AutoSize
Write-Host "Network adapters:" -ForegroundColor Yellow
Get-NetAdapter | Format-Table Name, MacAddress -AutoSize
Write-Host ""
Write-Host "Press any key to exit..." -ForegroundColor Gray
$null = $Host.UI.RawUI.ReadKey('NoEcho,IncludeKeyDown')

Right-click the .ps1 file and choose Run with PowerShell.

The .bat script's other limitation: no hash

Even when the .bat script worked, it only printed raw serials. If someone asked you for "your HWID", you still had to figure out what to do with five separate values. Most licensing and anti-cheat systems combine multiple serials into a single hash β€” the .bat script does not do that step for you.

A free tool that does everything the .bat did (and more)

If you want the same one-click simplicity as the old .bat β€” plus a SHA-256 hash, export to file, and no wmic dependency β€” download HWID Checker for Windows. It is an approximately 2.4 MB portable .exe with no installer.

# Double-click hwid-checker.exe β€” same as the old .bat, but:
# - Works on Windows 11 24H2 (no wmic needed)
# - Reads 10+ identifiers, not just 5
# - Combines them into a single SHA-256 HWID
# - Export to .txt or JSON with -save / -json

What it reads that the .bat script does not:

| Identifier | .bat script | HWID Checker | | --- | --- | --- | | Disk serials | βœ“ | βœ“ | | BIOS serial | βœ“ | βœ“ | | Motherboard serial | βœ“ | βœ“ | | SMBIOS UUID | βœ“ | βœ“ | | MAC addresses | βœ“ (via getmac) | βœ“ | | CPU ProcessorId | βœ— (cpu get serialnumber is not ProcessorId) | βœ“ | | Windows MachineGuid | βœ— | βœ“ | | Volume serials | βœ— | βœ“ | | RAM serials | βœ— | βœ“ | | Chassis serial | βœ— | βœ“ | | Windows product ID | βœ— | βœ“ | | SHA-256 combined hash | βœ— | βœ“ | | Export to file | βœ— | βœ“ | | No wmic dependency | βœ— | βœ“ |

The Windows utility is read-only: it queries local identifiers, prints the result, and writes a report only when you request an export.

Which should you use?

| Your situation | Recommendation | | --- | --- | | You just need to see serials once, right now | PowerShell one-liners above β€” no download | | You need a HWID hash (for licensing, support, etc.) | Download the tool β€” it hashes for you | | You are on Windows 11 24H2 and the .bat broke | PowerShell one-liners, or the tool | | You want a reusable script like the old .bat | Save the .ps1 script above | | You need to export or automate | The tool's -json flag |

The bottom line

The hwidChecker.bat approach depends on a deprecated optional component that is disabled by default on Windows 11 24H2, and the sample script has no composite hash or export workflow. Use the PowerShell commands above for individual values or the Windows utility for a local report and JSON or text export.

Want to check an HWID string someone sent you, without downloading anything? Paste it into our online HWID checker β€” it runs entirely in your browser.