If you're still using WMIC commands in your automation scripts, I've got some news that might ruin your coffee break.

Microsoft officially deprecated WMIC in 2016, and starting January 2024, it's "disabled by default" on Windows 11 insider builds. Translation? Your legacy scripts are living on borrowed time, and it's time to face the music.

What's WMIC Again?

Windows Management Instrumentation Command line—the trusty tool that's been helping IT pros query system info, manage processes, and automate tasks since the early 2000s. If you've ever run wmic process list or wmic logicaldisk get size,freespace, this affects you directly.

For those of us who've been in IT for a while, WMIC has been like that reliable old car that just keeps running. Sure, it's not pretty, and it makes weird noises sometimes, but it gets the job done.

Why the Sudden Change?

Microsoft isn't being cruel here—they're pushing everyone toward PowerShell. And honestly? It's about time we listened.

The reality is that WMIC was showing its age. PowerShell offers better error handling, more robust scripting capabilities, native integration with modern Windows features, and—here's the kicker—actual ongoing development and support.

Think of it this way: Microsoft has been investing heavily in PowerShell for years while WMIC has been gathering digital dust. The writing's been on the wall since 2016, but most of us (myself included) have been pretending not to see it.

The Migration Timeline

Here's where we stand:

  • 2016: WMIC officially deprecated (yeah, we all ignored this)

  • 2024: Disabled by default on new Windows 11 builds

  • Soon: Complete removal from future Windows releases

If you're thinking "I'll deal with this later," later just became now.

Your Complete WMIC to PowerShell Conversion Guide

Let me walk you through the 20 most commonly used WMIC commands and their PowerShell equivalents. I've organized these based on what I see IT pros using most often in the real world.

System Information Commands

1. Get System Information

# WMIC
wmic computersystem get model,name,manufacturer,systemtype
# PowerShell
Get-CimInstance -ClassName Win32_ComputerSystem | Select-Object Model, Name, Manufacturer, SystemType

2. Check System Uptime

# WMIC
wmic os get lastbootuptime
# PowerShell
Get-CimInstance -ClassName Win32_OperatingSystem | Select-Object @{Name="LastBootTime";Expression={$_.LastBootUpTime}}, @{Name="Uptime";Expression={(Get-Date) - $_.LastBootUpTime}}

3. Get BIOS Information

# WMIC
wmic bios get serialnumber,manufacturer,version
# PowerShell
Get-CimInstance -ClassName Win32_BIOS | Select-Object SerialNumber, Manufacturer, Version

Process and Service Management

4. List Running Processes

# WMIC
wmic process list brief
# PowerShell
Get-CimInstance -ClassName Win32_Process | Select-Object Name, ProcessId, PageFileUsage | Format-Table

5. Kill a Process by Name

# WMIC
wmic process where name="notepad.exe" delete
# PowerShell
Get-CimInstance -ClassName Win32_Process | Where-Object {$_.Name -eq "notepad.exe"} | Remove-CimInstance

6. Check Windows Services

# WMIC
wmic service get name,startmode,state
# PowerShell
Get-CimInstance -ClassName Win32_Service | Select-Object Name, StartMode, State

Hardware Information

7. Get CPU Information

# WMIC
wmic cpu get name,manufacturer,maxclockspeed
# PowerShell
Get-CimInstance -ClassName Win32_Processor | Select-Object Name, Manufacturer, MaxClockSpeed

8. Check Memory Information

# WMIC
wmic memorychip get capacity,manufacturer,speed
# PowerShell
Get-CimInstance -ClassName Win32_PhysicalMemory | Select-Object @{Name="Capacity(GB)";Expression={[math]::Round($_.Capacity/1GB,2)}}, Manufacturer, Speed

9. Get Hard Drive Information

# WMIC
wmic diskdrive get model,size,status
# PowerShell
Get-CimInstance -ClassName Win32_DiskDrive | Select-Object Model, @{Name="Size(GB)";Expression={[math]::Round($_.Size/1GB,2)}}, Status

Storage and Disk Management

10. Check Disk Space

# WMIC
wmic logicaldisk get size,freespace,caption
# PowerShell
Get-CimInstance -ClassName Win32_LogicalDisk | Select-Object DeviceID, @{Name="Size(GB)";Expression={[math]::Round($_.Size/1GB,2)}}, @{Name="FreeSpace(GB)";Expression={[math]::Round($_.FreeSpace/1GB,2)}}

Network Configuration

11. Get Network Adapter Info

# WMIC
wmic nic get name,speed,netconnectionstatus
# PowerShell
Get-CimInstance -ClassName Win32_NetworkAdapter | Where-Object {$_.NetConnectionStatus -ne $null} | Select-Object Name, Speed, NetConnectionStatus

12. Get Network Configuration

# WMIC
wmic nicconfig get ipaddress,subnetmask,defaultipgateway
# PowerShell
Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration | Where-Object {$_.IPAddress -ne $null} | Select-Object IPAddress, SubnetMask, DefaultIPGateway

Software and Updates

13. Get Installed Software

# WMIC
wmic product get name,version
# PowerShell
Get-CimInstance -ClassName Win32_Product | Select-Object Name, Version

14. Check Windows Updates/Hotfixes

# WMIC
wmic qfe get hotfixid,installedon,description
# PowerShell
Get-CimInstance -ClassName Win32_QuickFixEngineering | Select-Object HotFixID, InstalledOn, Description | Sort-Object InstalledOn -Descending

15. List Startup Programs

# WMIC
wmic startup get name,command,location
# PowerShell
Get-CimInstance -ClassName Win32_StartupCommand | Select-Object Name, Command, Location

User and Security Management

16. Get User Account Information

# WMIC
wmic useraccount get name,fullname,disabled
# PowerShell
Get-CimInstance -ClassName Win32_UserAccount | Select-Object Name, FullName, Disabled

17. Check Shared Folders

# WMIC
wmic share get name,path,description
# PowerShell
Get-CimInstance -ClassName Win32_Share | Select-Object Name, Path, Description

System Monitoring and Logs

18. Get Event Logs (System Errors)

# WMIC
wmic nteventlog where filename="system" get numberofrecords
# PowerShell
Get-CimInstance -ClassName Win32_NTEventlogFile | Where-Object {$_.LogfileName -eq "System"} | Select-Object LogfileName, NumberOfRecords, MaxFileSize

19. Check Print Queue

# WMIC
wmic printjob get document,jobstatus,owner
# PowerShell
Get-CimInstance -ClassName Win32_PrintJob | Select-Object Document, JobStatus, Owner

20. Check Scheduled Tasks

# WMIC
wmic job get name,status,starttime
# PowerShell
Get-ScheduledTask | Select-Object TaskName, State, @{Name="NextRunTime";Expression={$_.NextRunTime}}

Making the Transition Smoother

I know what you're thinking—those PowerShell commands look intimidating compared to the simple WMIC syntax. But here's the thing: once you get comfortable with the pattern, PowerShell becomes much more powerful and flexible.

Use Get-CimInstance Instead of Get-WmiObject

Always use Get-CimInstance instead of the older Get-WmiObject. It's faster, more reliable, and works better with modern Windows versions.

Format Your Output for Readability

Add | Format-Table or | Format-List to make output more readable:

Get-CimInstance -ClassName Win32_Process | Format-Table Name, ProcessId -AutoSize

Filter Results Like a Pro

Use Where-Object to filter results exactly how you need them:

Get-CimInstance -ClassName Win32_Service | Where-Object {$_.State -eq "Running"}

Export Data Easily

PowerShell makes it incredibly easy to export results to different formats:

Get-CimInstance -ClassName Win32_Process | Export-Csv -Path "processes.csv" -NoTypeInformation

Handle Remote Queries Better

PowerShell handles remote queries more elegantly than WMIC ever did:

Get-CimInstance -ClassName Win32_Process -ComputerName "RemotePC"

Advanced PowerShell Techniques

Once you're comfortable with the basics, these techniques will make your life much easier:

Create Custom Functions

Wrap complex commands in functions for easier reuse:

function Get-SystemInfo {
    Get-CimInstance -ClassName Win32_ComputerSystem | Select-Object Name, Manufacturer, Model, TotalPhysicalMemory
}

Use Calculated Properties

Convert bytes to more readable formats:

@{Name="Size(GB)";Expression={[math]::Round($_.Size/1GB,2)}}

Combine Multiple Classes

PowerShell makes it easier to join data from different WMI classes:

$OS = Get-CimInstance Win32_OperatingSystem
$CS = Get-CimInstance Win32_ComputerSystem
[PSCustomObject]@{
    ComputerName = $CS.Name
    OS = $OS.Caption
    Version = $OS.Version
    Memory = [math]::Round($CS.TotalPhysicalMemory/1GB,2)
}

Your Action Plan

Here's what you need to do right now:

Audit your scripts - Find every WMIC command hiding in your automation. Trust me, there are more than you think.

Start the migration - Convert your most critical scripts to PowerShell equivalents first. Don't try to do everything at once.

Test everything - PowerShell syntax isn't always 1:1 with WMIC. Test thoroughly before deploying to production.

Upskill your team - Make sure everyone on your team understands these new commands. PowerShell is the future of Windows automation.

The Silver Lining

I'll be honest—this forced migration is actually going to make your automation better. PowerShell offers better error handling, more robust scripting capabilities, and native integration with modern Windows features that WMIC never had.

Plus, let's face it: how many of us have been putting off learning PowerShell properly? Microsoft just gave us the motivation we needed.

Looking Forward

The PowerShell equivalents might be more verbose, but they're also more powerful and flexible. Take time to learn the syntax properly—it'll make your Windows administration much more robust in the long run.

And hey, if you're already PowerShell-native, this is your moment to feel superior. Enjoy it.

The bottom line? WMIC served us well for two decades, but it's time to move on. PowerShell isn't just a replacement—it's an upgrade. Once you make the transition, you'll wonder why you waited so long.

What's your biggest WMIC dependency? How painful is your migration going to be? I'd love to hear your war stories and help you through this transition.

Keep Reading

No posts found