Windows Commands to Check System Information and Health – Complete Hardware Diagnostics Guide

Introduction

Windows provides comprehensive command-line tools to check system information, hardware details, and overall system health. Whether you're troubleshooting performance issues, checking hardware specifications, monitoring disk health, or verifying battery status on laptops, these commands provide detailed insights into your system's condition.

This guide covers essential commands for checking CPU, RAM, hard disk, battery, motherboard, and other hardware components, along with system health diagnostics and performance monitoring tools.

systeminfo - Comprehensive System Information

systeminfo displays detailed configuration information about the computer and its operating system.

Basic System Information

systeminfo
  

Displays comprehensive system information including:

  • OS Name and Version
  • System Manufacturer and Model
  • Processor Information
  • BIOS Version
  • Total Physical Memory
  • Available Memory
  • Virtual Memory
  • System Boot Time
  • Installed Hotfixes
  • Network Adapter Information

Find Specific Information

systeminfo | findstr /C:"Total Physical Memory"
  

Find total RAM installed

systeminfo | findstr /C:"System Manufacturer"
  

Find system manufacturer

systeminfo | findstr /C:"System Model"
  

Find system model

systeminfo | findstr /C:"Processor"
  

Find processor information

systeminfo | findstr /C:"System Boot Time"
  

Find last boot time

Save Output to File

systeminfo > C:\system_info.txt
  

wmic - Windows Management Instrumentation Command

wmic is a powerful command-line tool for querying detailed hardware and system information. Note: WMIC is deprecated in newer Windows versions but still functional.

CPU Information

wmic cpu get name, numberofcores, numberoflogicalprocessors, maxclockspeed
  

Displays CPU name, cores, threads, and clock speed

wmic cpu get caption, deviceid, name, numberofcores, maxclockspeed, status
  

Detailed CPU information

wmic cpu get loadpercentage
  

Current CPU usage percentage

Memory (RAM) Information

wmic memorychip get capacity, speed, manufacturer, devicelocator
  

Shows RAM capacity (in bytes), speed, manufacturer, and slot location

wmic memorychip get capacity
  

Shows RAM capacity for each module

wmic computersystem get totalphysicalmemory
  

Total installed RAM in bytes

Note: To convert bytes to GB, divide by 1073741824

Motherboard Information

wmic baseboard get product, manufacturer, version, serialnumber
  

Shows motherboard model, manufacturer, version, and serial number

BIOS Information

wmic bios get manufacturer, smbiosbiosversion, releasedate
  

Displays BIOS manufacturer, version, and release date

Hard Disk Information

wmic diskdrive get model, size, status, interfacetype
  

Shows disk model, size, status, and interface type (SATA, NVMe, etc.)

wmic diskdrive get caption, size, status
  

Disk name, size, and health status

Disk Partition Information

wmic partition get name, size, type
  

Logical Disk Information

wmic logicaldisk get caption, size, freespace, filesystem
  

Shows drive letter, total size, free space, and file system

Battery Information (Laptops)

wmic path Win32_Battery get BatteryStatus, EstimatedChargeRemaining, EstimatedRunTime
  

Shows battery status, charge percentage, and estimated runtime

wmic path Win32_Battery get DesignCapacity, FullChargeCapacity
  

Shows original design capacity vs current full charge capacity (battery health indicator)

Graphics Card Information

wmic path win32_videocontroller get name, adapterram, driverversion, status
  

Shows GPU name, VRAM, driver version, and status

Operating System Information

wmic os get caption, version, buildnumber, osarchitecture
  

Shows Windows version, build number, and architecture (32/64-bit)

wmic os get lastbootuptime
  

Shows last system boot time

Network Adapter Information

wmic nic get name, manufacturer, macaddress, speed
  

USB Devices

wmic path Win32_USBHub get deviceid, description
  

Monitor Information

wmic desktopmonitor get screenheight, screenwidth
  

PowerShell Hardware Information Commands

PowerShell provides modern cmdlets for hardware information retrieval with better formatting and filtering.

Computer System Information

Get-ComputerInfo
  

Comprehensive system information (similar to systeminfo but more detailed)

Get-ComputerInfo | Select-Object CsName, CsManufacturer, CsModel, OsName, OsVersion, OsArchitecture
  

Filtered computer information

CPU Information

Get-WmiObject Win32_Processor | Select-Object Name, NumberOfCores, NumberOfLogicalProcessors, MaxClockSpeed
  
Get-CimInstance Win32_Processor | Format-List *
  

Detailed CPU information

Memory Information

Get-WmiObject Win32_PhysicalMemory | Select-Object Capacity, Speed, Manufacturer, DeviceLocator
  
Get-CimInstance Win32_PhysicalMemory | Select-Object @{Name="Capacity(GB)";Expression={$_.Capacity/1GB}}, Speed, Manufacturer, DeviceLocator
  

Shows RAM in GB format

Total Physical Memory

Get-CimInstance Win32_ComputerSystem | Select-Object @{Name="TotalRAM(GB)";Expression={[math]::Round($_.TotalPhysicalMemory/1GB,2)}}
  

Disk Information

Get-PhysicalDisk | Select-Object DeviceID, FriendlyName, MediaType, Size, HealthStatus
  

Shows disk health status and type (SSD/HDD)

Get-Disk | Select-Object Number, FriendlyName, HealthStatus, OperationalStatus, @{Name="Size(GB)";Expression={[math]::Round($_.Size/1GB,2)}}
  

Partition and Volume Information

Get-Partition | Select-Object DiskNumber, PartitionNumber, DriveLetter, Size, Type
  
Get-Volume | Select-Object DriveLetter, FileSystem, HealthStatus, @{Name="Size(GB)";Expression={[math]::Round($_.Size/1GB,2)}}, @{Name="Free(GB)";Expression={[math]::Round($_.SizeRemaining/1GB,2)}}
  

Battery Information

Get-WmiObject Win32_Battery | Select-Object BatteryStatus, EstimatedChargeRemaining, EstimatedRunTime
  
Get-CimInstance Win32_Battery | Format-List *
  

Detailed battery information

BIOS Information

Get-WmiObject Win32_BIOS | Select-Object Manufacturer, SMBIOSBIOSVersion, ReleaseDate
  

Motherboard Information

Get-WmiObject Win32_BaseBoard | Select-Object Manufacturer, Product, Version, SerialNumber
  

Graphics Card Information

Get-WmiObject Win32_VideoController | Select-Object Name, AdapterRAM, DriverVersion, VideoModeDescription
  

Battery Health and Power Report (Laptops)

Generate Detailed Battery Report

powercfg /batteryreport
  

Generates an HTML battery report saved to C:\Windows\System32\battery-report.html

Report includes:

  • Battery specifications
  • Recent usage history
  • Battery capacity history
  • Battery life estimates
  • Design capacity vs full charge capacity (health indicator)

Specify Output Location

powercfg /batteryreport /output "C:\Users\YourName\Desktop\battery-report.html"
  

Quick Battery Status

powercfg /batteryreport /duration 7
  

Battery usage for last 7 days

Check Power Configuration

powercfg /list
  

Lists all power schemes

powercfg /query
  

Shows current power scheme settings

Energy Report (System Power Efficiency)

powercfg /energy
  

Analyzes system for 60 seconds and generates energy-report.html showing power efficiency issues

powercfg /energy /output "C:\Users\YourName\Desktop\energy-report.html"
  

Sleep Study Report

powercfg /sleepstudy
  

Analyzes Modern Standby (Connected Standby) performance

Hard Disk Health Check Commands

Check Disk Health with CHKDSK

chkdsk C:
  

Basic disk check (read-only)

chkdsk C: /f
  

Fixes errors on the disk (requires restart for system drive)

chkdsk C: /r
  

Locates bad sectors and recovers readable information (includes /f)

chkdsk C: /scan
  

Quick scan (Windows 8 and later)

SMART Status Check

wmic diskdrive get status
  

Shows disk status (OK, Pred Fail, Error, etc.)

Get-PhysicalDisk | Select-Object FriendlyName, HealthStatus, OperationalStatus
  

PowerShell command for disk health

Disk Performance Statistics

Get-StorageReliabilityCounter -PhysicalDisk (Get-PhysicalDisk -FriendlyName "Your Disk Name")
  

Shows read/write errors, temperature, power-on hours, etc.

Check Disk Space

Get-PSDrive -PSProvider FileSystem
  

Shows used and free space for all drives

Memory Diagnostics

Windows Memory Diagnostic Tool

mdsched
  

Opens Windows Memory Diagnostic tool. Requires restart to perform RAM test. The system will reboot and test RAM for errors.

Check Memory Usage

systeminfo | findstr /C:"Available Physical Memory"
  
wmic OS get FreePhysicalMemory, TotalVisibleMemorySize
  

Shows free and total memory in KB

Detailed Memory Information

Get-CimInstance Win32_PhysicalMemory | Format-Table Manufacturer, Capacity, Speed, DeviceLocator -AutoSize
  

System Performance Monitoring

Task Manager via Command Line

taskmgr
  

Opens Task Manager (GUI)

Performance Monitor

perfmon
  

Opens Performance Monitor for detailed performance analysis

perfmon /report
  

Generates system diagnostics report (takes 60 seconds)

Resource Monitor

resmon
  

Opens Resource Monitor showing real-time CPU, memory, disk, and network usage

System File Checker

sfc /scannow
  

Scans and repairs corrupted system files (requires admin privileges)

DISM - Deployment Image Servicing and Management

DISM /Online /Cleanup-Image /CheckHealth
  

Quick check for corruption

DISM /Online /Cleanup-Image /ScanHealth
  

Advanced scan for corruption

DISM /Online /Cleanup-Image /RestoreHealth
  

Repairs corruption using Windows Update

Driver Information

List All Drivers

driverquery
  

Lists all installed device drivers

driverquery /v
  

Verbose output with more details

driverquery /fo csv > C:\drivers.csv
  

Export driver list to CSV file

PowerShell Driver Information

Get-WindowsDriver -Online -All
  
Get-WmiObject Win32_PnPSignedDriver | Select-Object DeviceName, DriverVersion, Manufacturer | Format-Table -AutoSize
  

Temperature and Hardware Monitoring

Note: Windows doesn't provide native commands for temperature monitoring. Use third-party tools like HWiNFO, SpeedFan, or Core Temp for temperature monitoring.

Get Thermal Information (PowerShell - Limited)

Get-WmiObject MSAcpi_ThermalZoneTemperature -Namespace "root/wmi" | Select-Object CurrentTemperature
  

Shows temperature in tenths of Kelvin. Convert to Celsius: (Temperature/10) - 273.15
Note: Not all systems support this WMI class

System Uptime and Boot Information

Check System Uptime

systeminfo | findstr /C:"System Boot Time"
  
net statistics workstation
  

Shows statistics since last boot

PowerShell Uptime

Get-CimInstance Win32_OperatingSystem | Select-Object LastBootUpTime, @{Name="Uptime";Expression={(Get-Date) - $_.LastBootUpTime}}
  
(Get-Date) - (Get-CimInstance Win32_OperatingSystem).LastBootUpTime
  

Shows uptime in days, hours, minutes

DirectX Diagnostic Tool

Launch DirectX Diagnostics

dxdiag
  

Opens DirectX Diagnostic Tool showing:

  • System information
  • Display adapter details
  • Sound device information
  • Input devices
  • DirectX version and features

Save Report to File

dxdiag /t C:\dxdiag_report.txt
  

Generates a text report of DirectX diagnostics

Event Viewer Logs

Open Event Viewer

eventvwr
  

Opens Event Viewer GUI

Query Event Logs via Command Line

wevtutil qe System /c:10 /f:text
  

Shows last 10 System log entries

wevtutil qe Application /c:10 /f:text
  

Shows last 10 Application log entries

PowerShell Event Log Queries

Get-EventLog -LogName System -Newest 20
  

Shows last 20 system events

Get-EventLog -LogName System -EntryType Error -Newest 10
  

Shows last 10 system errors

Get-WinEvent -FilterHashtable @{LogName='System';Level=2} -MaxEvents 10
  

Shows last 10 critical errors in System log

Complete System Health Check Workflow

Step 1: Generate System Information Report

systeminfo > C:\system_report.txt
perfmon /report
  

Step 2: Check Disk Health

wmic diskdrive get status
Get-PhysicalDisk | Select-Object FriendlyName, HealthStatus
chkdsk C: /scan
  

Step 3: Check Memory

wmic memorychip get capacity, speed, manufacturer
Get-CimInstance Win32_PhysicalMemory
  

Optional: Run memory diagnostic (requires restart):

mdsched
  

Step 4: Check Battery Health (Laptops Only)

powercfg /batteryreport
  

Step 5: Check System Files

sfc /scannow
DISM /Online /Cleanup-Image /RestoreHealth
  

Step 6: Review Event Logs

Get-EventLog -LogName System -EntryType Error -Newest 20
Get-EventLog -LogName Application -EntryType Error -Newest 20
  

Step 7: Check CPU and Performance

wmic cpu get loadpercentage
resmon
  

Hardware Diagnostics Quick Reference

# System Information
systeminfo                              # Complete system info
Get-ComputerInfo                        # PowerShell system info

# CPU
wmic cpu get name, numberofcores, maxclockspeed

# RAM
wmic memorychip get capacity, speed, manufacturer
Get-CimInstance Win32_PhysicalMemory

# Disk Health
wmic diskdrive get model, size, status
Get-PhysicalDisk | Select-Object FriendlyName, HealthStatus
chkdsk C: /scan

# Battery (Laptop)
powercfg /batteryreport
wmic path Win32_Battery get EstimatedChargeRemaining

# Motherboard
wmic baseboard get product, manufacturer, version

# BIOS
wmic bios get manufacturer, smbiosbiosversion

# Graphics Card
wmic path win32_videocontroller get name, adapterram

# Drivers
driverquery

# System Health
sfc /scannow                            # System file check
DISM /Online /Cleanup-Image /RestoreHealth
perfmon /report                         # Performance report
mdsched                                 # Memory diagnostic

# Uptime
systeminfo | findstr /C:"System Boot Time"
(Get-Date) - (Get-CimInstance Win32_OperatingSystem).LastBootUpTime
  

Export System Information to Files

Create Complete System Report

systeminfo > C:\Reports\systeminfo.txt
wmic cpu get * > C:\Reports\cpu_info.txt
wmic memorychip get * > C:\Reports\ram_info.txt
wmic diskdrive get * > C:\Reports\disk_info.txt
wmic baseboard get * > C:\Reports\motherboard_info.txt
driverquery /v > C:\Reports\drivers.txt
  

PowerShell Comprehensive Report

Get-ComputerInfo | Out-File C:\Reports\computer_info.txt
Get-PhysicalDisk | Out-File C:\Reports\disk_health.txt
Get-CimInstance Win32_PhysicalMemory | Out-File C:\Reports\memory_info.txt
Get-WmiObject Win32_Processor | Out-File C:\Reports\cpu_info.txt
  

Common Issues and Diagnostic Commands

Issue 1: Slow Performance

# Check CPU usage
wmic cpu get loadpercentage

# Check memory usage
systeminfo | findstr /C:"Available Physical Memory"

# Check disk usage
Get-Volume

# Open Resource Monitor
resmon

# Generate performance report
perfmon /report
  

Issue 2: Frequent Crashes/Blue Screens

# Check system files
sfc /scannow

# Check RAM
mdsched

# Check disk health
wmic diskdrive get status
chkdsk C: /r

# Check recent critical errors
Get-EventLog -LogName System -EntryType Error -Newest 20
  

Issue 3: Battery Draining Fast (Laptop)

# Generate battery report
powercfg /batteryreport

# Check battery health
wmic path Win32_Battery get DesignCapacity, FullChargeCapacity

# Energy efficiency report
powercfg /energy
  

Issue 4: Overheating Concerns

# Check power settings
powercfg /list
powercfg /query

# Monitor with Resource Monitor
resmon

# Check for high CPU processes
tasklist /svc
  

Issue 5: Disk Errors

# Check disk status
wmic diskdrive get status

# Scan for errors
chkdsk C: /f /r

# Check SMART status
Get-PhysicalDisk | Select-Object FriendlyName, HealthStatus, OperationalStatus
  

Best Practices

  • Run Command Prompt or PowerShell as Administrator for full functionality
  • Generate regular system health reports and save them for comparison
  • Run SFC and DISM scans periodically to maintain system integrity
  • Check disk health monthly, especially for older drives
  • Generate battery reports quarterly on laptops to monitor battery degradation
  • Review Event Viewer logs regularly for hardware warnings
  • Keep drivers updated by checking manufacturer websites
  • Use Performance Monitor reports to establish baseline system performance
  • Document hardware specifications before and after upgrades
  • Schedule disk cleanup and defragmentation (HDDs only) regularly
  • Monitor system temperatures using third-party tools in addition to built-in commands
  • Create system restore points before major changes

Conclusion

Windows provides comprehensive command-line tools for checking system information and monitoring hardware health. From CPU and RAM diagnostics to battery reports and disk health checks, these commands enable IT professionals and power users to maintain optimal system performance and identify potential hardware issues before they become critical.

Regular use of these diagnostic tools, combined with proper system maintenance, ensures your Windows system runs smoothly and reliably. Whether you're troubleshooting performance issues, planning hardware upgrades, or performing routine maintenance, these commands provide the detailed information needed to make informed decisions about your system's health.

Remember to combine built-in Windows tools with third-party hardware monitoring software for comprehensive system diagnostics, especially for advanced metrics like temperature monitoring and detailed SMART data analysis.