Windows CMD Commands: Your Swiss-Army Terminal in 2025
Windows CMD commands saved my bacon last month. Picture this: 2 a.m., production website wheezing, and all the fancy GUI tools refusing to launch. I cracked open cmd.exe, fired off ipconfig /flushdns, and—boom—traffic flowed again. Five lines later the on-call pager stopped screaming, and I grabbed a cold slice of pizza in victory. That night reminded me why these 100 time-tested commands still matter.

Why Windows CMD commands Still Rock in 2025
- Speed over clicks. Type, hit ↵, done. No spinning wheels, no “Not Responding” windows.
- Minimal overhead. CMD runs on fresh installs, Safe-Mode boots, even stripped-down Nano Server images.
- Scripting power. Batch and PowerShell coexist, letting you glue legacy scripts into modern DevOps pipelines.
- Universal tribal knowledge. Toss
ping,chkdsk, ortasklistinto any forum and every admin nods in recognition.
The Complete 100-Command Cheat Sheet
Below is the full list—curated, categorized, and battle-tested. Bookmark it, print it, tattoo it on your coffee mug.
System Management & Maintenance (30)
systeminfo— view system hardware / patch infosfc /scannow— scan & fix system fileschkdsk /f— repair disk errorscleanmgr— open Disk Cleanupdefrag C: /O— optimize defragmsinfo32— system information panelwinver— Windows versionservices.msc— Service Managercompmgmt.msc— Computer Managementdiskmgmt.msc— Disk Managementdevmgmt.msc— Device Managereventvwr— Event Viewerperfmon— Performance Monitortaskschd.msc— Task Schedulerlusrmgr.msc— Local Users & Groupscontrol— Control Panelappwiz.cpl— Programs & Featuressysdm.cpl— System Propertiessecpol.msc— Local Security Policyrsop.msc— Resultant Set of Policyslmgr.vbs -xpr— activation statewmic qfe list— installed patcheswmic bios get serialnumber— BIOS serialpowercfg /energy— power efficiency reportver— show OS versionhostname— computer nametime— view / set timedate— view / set dateshutdown /r /t 0— reboot nowshutdown /s /t 0— shut down now
Network Diagnosis & Configuration (25)
ipconfig /all— full network configping 8.8.8.8 -t— continuous pingtracert example.com— route tracenetstat -ano— ports & PIDsnslookup example.com— DNS lookuparp -a— ARP cachenetsh interface ip show config— adapter confignetsh interface ip set dns "Ethernet" static 8.8.8.8— set DNSnetsh winsock reset— reset stacknetsh advfirewall set allprofiles state off— disable firewallroute print— routing tablenet use K: \\192.168.1.100\share— map drivenetsh wlan show profiles— saved Wi-Finetsh wlan show profile name="Home" key=clear— Wi-Fi passwordnetsh wlan connect ssid="Office"— connect Wi-Fipathping example.com— loss & latencygetmac /v— MAC addressnet view— LAN sharesnet share— manage sharesftp— FTP clienttelnet— Telnet clientnetsh trace start capture=yes— start packet tracenetsh trace stop— stop traceipconfig /flushdns— clear DNS cacheipconfig /registerdns— renew DNS registration
File & Disk Operations (20)
dir /s /ah— list hidden filescd /d D:\logs— change drive & dirrobocopy C:\src D:\backup /MIR /MT:8— multithread backupdel /F /Q *.tmp— delete temp filesrd /S /Q "D:\old"— delete folderfsutil file createnew test.txt 1048576— 1 MB filetype filename.txt— show textcopy file1+file2 merged.txt— merge filesxcopy C:\data D:\backup /E /H /C— copy treemove file.txt D:\new— move fileren old.txt new.txt— renameattrib +h secret.txt— hide filefc file1 file2— compare filesfind "error" log.txt— search texttree /F— directory treemd newfolder— make dircipher /W:D:— wipe free spacecompact /c /s— NTFS compressdiskpart— partition toolformat E: /FS:NTFS /Q— quick format
Process & User Control (15)
tasklist /svc— process & service listtaskkill /F /IM chrome.exe— kill processtaskkill /PID 1234 /T— kill treestart notepad— launch programnet user Tech P@ssw0rd /add— add usernet localgroup administrators Tech /add— elevate usernet user Tech /delete— remove userquery session— RDP sessionswhoami— current userrunas /user:admin cmd— run as other userqwinsta— session infosc query— service statussc stop WinDefend— stop servicesc config DiagTrack start= disabled— disable servicewmic process get name,processid— list processes
Ops-Side Power Plays (10)
for /L %i in (1,1,100) do ping -n 1 192.168.1.%i— subnet sweepforfiles /p "C:\logs" /s /m *.log /d -7 /c "cmd /c del @path"— prune logs > 7 daysauditpol /set /category:"Account Logon" /success:enable— enable logon auditingwmic product get name,version > software.csv— export software listwmic memorychip get capacity,speed— view RAMwmic diskdrive get model,size— view disksreg query "HKLM\Software\Microsoft\Windows\CurrentVersion\Run"— startup itemsschtasks /query /fo LIST /v— task scheduler detailsvssadmin list shadows— shadow copiespowercfg /batteryreport— battery health
Before you script anything destructive, skim our Server Maintenance Checklist and test backups with this Active Directory security deep-dive. Your future self will thank you.
Need the official docs? Microsoft’s Windows Commands Index keeps everything in one tidy place.
Automation: Glue Them All Together
Batch still rules for tiny jobs. Here’s a snack-size example bundling three Windows CMD commands into a nightly health check:
@echo off
:: Nightly Health Check
set LOG=C:\Scripts\Nightly_%date:~-4%-%date:~4,2%-%date:~7,2%.log
echo ==== Nightly Check %date% %time% ==== >> %LOG%
systeminfo | find "System Boot Time" >> %LOG%
ipconfig /flushdns >> %LOG%
chkdsk C: /scan >> %LOG%
echo ==== Done ==== >> %LOG%
Golden Safety Rules
- Test first. Run risky Windows CMD commands on a VM or lab box.
- Least privilege. Stay out of elevated shells unless absolutely required.
- Two-step confirmation. Before
formatorrd /S /Q, reread the path—then reread again. - Log everything. Pipe critical runs to
> audit.logfor forensic sanity.

Final Take
I’ve packed these 100 Windows CMD commands into my muscle memory over a decade of graveyard shifts and caffeine crashes. Master even a quarter of them and you’ll slice mean-time-to-repair in half. Master them all and you’ll wield the terminal like a lightsaber—elegant, agile, and just a little dangerous. Now fire up cmd.exe, flex those fingers, and make the blue-screen gremlins run for cover.

FoxDoo Technology







