
cmd commands
💻 100 CMD Commands for Daily Use in Windows (2025 Complete Guide)
This article is structured and SEO-optimized for a tech website that covers Windows, computers, and software topics — perfect for audiences in India and globally.
🧠 Introduction
The Command Prompt (CMD) in Windows is one of the most powerful yet underrated tools. It allows users to perform tasks quickly, troubleshoot system issues, manage files, check network connections, and much more — all using simple text-based commands.
Whether you’re a beginner, a tech enthusiast, or a system administrator, learning CMD commands can save time and make you more efficient.
In this article, we’ll cover 100 CMD commands for daily use, divided into categories like system info, network tools, file operations, security, and troubleshooting.
⚙️ 1. Basic CMD Commands for Beginners
These commands help you navigate and manage files or folders from the command line.
| Command | Description |
|---|---|
dir | Lists files and folders in the current directory |
cd | Changes the directory (folder) |
cd.. | Moves one step back in the directory path |
cls | Clears the Command Prompt screen |
exit | Closes the Command Prompt window |
echo | Displays messages or turns command echoing on/off |
date | Displays or sets the system date |
time | Displays or sets the system time |
ver | Shows the Windows version |
help | Displays a list of available commands |
These are the foundation commands for getting started in CMD.
📂 2. File and Folder Management Commands
CMD can help you manage files quickly without using File Explorer.
| Command | Description |
|---|---|
mkdir or md | Creates a new folder |
rmdir | Removes a directory |
del | Deletes one or more files |
copy | Copies files from one location to another |
xcopy | Copies entire folders including subfolders |
move | Moves files or folders to another location |
rename | Renames a file or folder |
attrib | Changes file attributes (hidden, read-only, etc.) |
tree | Displays directory structure in tree format |
fc | Compares two text files and shows differences |
Example:
xcopy D:\Projects C:\Backup\Projects /E
Copies all folders and files from one drive to another, including subdirectories.
🧩 3. System Information and Diagnostics Commands
Use these commands to check your system’s details, performance, and health.
| Command | Description |
|---|---|
systeminfo | Displays detailed system configuration |
hostname | Shows the computer’s network name |
wmic cpu get name | Displays your CPU model |
wmic bios get serialnumber | Displays BIOS serial number |
tasklist | Lists all running processes |
taskkill /im processname.exe /f | Forces a program to close |
driverquery | Lists all installed drivers |
sfc /scannow | Scans and repairs corrupted system files |
chkdsk | Checks disk for errors |
powercfg /energy | Generates a detailed power efficiency report |
Example:
systeminfo | find "OS"
Shows only the Windows OS version.
🌐 4. Network and Internet Commands
CMD is powerful for checking and fixing network problems.
| Command | Description |
|---|---|
ping website.com | Checks network connection to a website or IP |
ipconfig | Displays IP address and network details |
ipconfig /all | Shows full IP configuration details |
ipconfig /release | Releases current IP address |
ipconfig /renew | Renews IP address from DHCP |
netstat | Displays active connections and ports |
tracert website.com | Traces route taken by packets to a destination |
nslookup website.com | Checks DNS details for a website |
getmac | Displays MAC address of your system |
arp -a | Shows ARP cache table of connected devices |
Example:
ping google.com
Used to test if your internet or network connection is working.
🔐 5. User Account and Security Commands
Useful for managing users and protecting your system.
| Command | Description |
|---|---|
net user | Lists all user accounts |
net user username password /add | Creates a new user |
net user username /delete | Deletes a user account |
net localgroup administrators username /add | Adds a user to the admin group |
net accounts | Displays password and logon settings |
runas /user:administrator cmd | Runs Command Prompt as administrator |
cipher /w:C: | Securely wipes deleted files from a drive |
gpupdate /force | Forces Group Policy update |
secedit /analyze | Analyzes system security settings |
net session | Displays active network sessions |
Example:
net user NewAdmin P@ssword123 /add
Creates a new user account with admin rights.
🧱 6. Disk Management and Storage Commands
Control and monitor your drives using CMD.
| Command | Description |
|---|---|
diskpart | Opens disk management tool |
list disk | Lists all disks connected |
list volume | Displays all partitions and volumes |
select disk 0 | Selects a specific disk |
clean | Wipes all data from the selected disk |
format | Formats a drive or partition |
label | Changes the name of a drive |
vol | Displays volume label and serial number |
defrag C: | Defragments drive C |
wmic logicaldisk get size,freespace,caption | Displays drive space and free space |
Example:
defrag D: /A /V
Analyzes and reports fragmentation on drive D.
🖧 7. Network Sharing and Connectivity
For managing networks, shared drives, and remote access.
| Command | Description |
|---|---|
net share | Displays shared folders |
net share FolderName=C:\Path | Shares a specific folder |
net use | Connects or disconnects shared network drives |
net view | Lists all computers on your network |
netstat -an | Displays all open ports and listening connections |
pathping website.com | Combines ping and traceroute data |
netsh wlan show profiles | Shows saved Wi-Fi networks |
netsh wlan show profile "WiFiName" key=clear | Reveals Wi-Fi password |
net use Z: \\computer\folder | Maps a shared folder as drive Z |
net file | Lists files opened remotely on your system |
Example:
netsh wlan show profile “HomeWiFi” key=clear
Displays the saved Wi-Fi password for your home network.
⚡ 8. Power and Performance Commands
Monitor and optimize your system performance.
| Command | Description |
|---|---|
powercfg /a | Shows available power modes |
powercfg /hibernate on | Enables hibernation |
powercfg /hibernate off | Disables hibernation |
powercfg /batteryreport | Generates battery health report |
powercfg /energy | Analyzes power efficiency |
shutdown /s /t 0 | Shuts down computer immediately |
shutdown /r /t 0 | Restarts computer immediately |
shutdown /l | Logs out current user |
taskmgr | Opens Task Manager |
perfmon | Opens Performance Monitor |
Example:
powercfg /batteryreport /output "C:\battery.html"
Creates a detailed battery usage report for laptops.

🧮 9. Advanced System and Administrative Commands
For troubleshooting and advanced Windows operations.
| Command | Description |
|---|---|
msconfig | Opens System Configuration utility |
regedit | Opens Windows Registry Editor |
eventvwr | Opens Event Viewer |
services.msc | Opens Services Manager |
compmgmt.msc | Opens Computer Management console |
devmgmt.msc | Opens Device Manager |
control | Opens Control Panel |
appwiz.cpl | Opens “Programs and Features” |
taskschd.msc | Opens Task Scheduler |
wmic product get name,version | Lists installed software |
Example:
wmic product get name,version
Lists all installed applications with their versions.
🧰 10. Maintenance and Repair Commands
Keep your Windows system healthy and efficient.
| Command | Description |
|---|---|
dism /online /cleanup-image /scanhealth | Checks for system image corruption |
dism /online /cleanup-image /restorehealth | Repairs system image |
sfc /scannow | Scans and fixes system files |
cleanmgr | Opens Disk Cleanup tool |
chkdsk /f | Fixes disk file system errors |
rstrui | Opens System Restore |
control update | Opens Windows Update settings |
setx PATH | Adds a directory to the system path |
shutdown /a | Aborts a scheduled shutdown |
taskkill /f /im explorer.exe | Kills Windows Explorer process (restart with start explorer.exe) |
Example:
dism /online /cleanup-image /restorehealth
Repairs corrupted Windows files using system resources.
📡 11. Internet and IP Tools
Useful for diagnosing internet problems.
| Command | Description |
|---|---|
netsh int ip reset | Resets TCP/IP settings |
netsh winsock reset | Resets network socket configuration |
tracert | Traces route packets take to a host |
pathping | Combines ping and trace with detailed results |
curl | Transfers data from URLs |
ftp | Opens FTP file transfer session |
telnet | Connects to remote systems (if enabled) |
nslookup | Checks DNS and IP mapping |
route print | Displays current routing table |
netsh interface ipv4 show config | Shows IPv4 configuration details |
🧾 12. System Monitoring and Logs
Track what’s happening in your system.
| Command | Description |
|---|---|
tasklist | Lists running applications and services |
taskkill /im program.exe /f | Ends specific process |
type filename.txt | Displays contents of a file |
echo %username% | Displays current username |
echo %computername% | Displays computer name |
set | Displays environment variables |
whoami | Shows current logged-in user |
logoff | Logs off user session |
msg * "Your Message" | Sends a message to other users on the network |
systeminfo > report.txt | Saves system info to a text file |
🔍 13. File Search and Management Shortcuts
| Command | Description |
|---|---|
find | Searches for text in files |
findstr | Advanced search for text patterns |
where | Locates executable files |
replace | Replaces text within files |
sort | Sorts text data in a file |
type | Displays file contents |
more | Displays one screen at a time |
comp | Compares file contents |
attrib +h filename | Hides a file |
attrib -h filename | Unhides a file |
🧩 14. Fun or Miscellaneous Commands
| Command | Description |
|---|---|
color a | Changes CMD text color |
title MyCMD | Changes CMD window title |
prompt | Customizes CMD prompt display |
tree | Displays folder structure graphically |
calc | Opens Calculator |
notepad | Opens Notepad |
write | Opens WordPad |
explorer . | Opens current folder in File Explorer |
shutdown /i | Opens shutdown interface |
cmd /k | Opens a new CMD window and runs a command |
🧠 15. Pro-Level Tips
- Always run CMD as Administrator for system-level tasks.
- Use arrow keys to repeat past commands.
- Use the Tab key for auto-completing folder names.
- Redirect outputs using:
systeminfo > info.txt(This saves system info to a text file.) - Chain multiple commands using
&&:ipconfig && ping google.com
🧾 Conclusion
CMD remains one of the most powerful and versatile tools in Windows — even in 2025. While many users rely on graphical interfaces, CMD offers speed, flexibility, and control that no GUI can match.
By mastering these 100 CMD commands, you can:
- Fix Windows errors
- Speed up troubleshooting
- Manage networks
- Control users and drives
- Monitor system performance
Whether you’re a student, IT professional, or casual user, these commands are invaluable for daily Windows maintenance and productivity.
FAQs
1. What is CMD in Windows?
CMD (Command Prompt) is a built-in command-line interpreter in Windows that allows users to execute text-based commands to perform various tasks such as managing files, checking network settings, or troubleshooting the system.
2. How do I open CMD in Windows 10 or Windows 11?
You can open CMD by pressing Windows + R, typing cmd, and pressing Enter.
For administrator access, search “Command Prompt” in the Start menu, right-click it, and select Run as Administrator.
3. What is the difference between CMD and PowerShell?
CMD is the older command-line interface with simple commands, while PowerShell is an advanced shell with scripting capabilities and access to system APIs. PowerShell supports CMD commands too.
4. Can CMD commands damage my PC?
Most basic CMD commands are safe, but administrative or system-level commands (like diskpart, format, or del) can cause data loss if used incorrectly. Always double-check before executing.
5. What are the most commonly used CMD commands?
Commonly used commands include:ipconfig, ping, systeminfo, dir, cd, copy, tasklist, sfc /scannow, and chkdsk.
6. How do CMD commands help in daily computer use?
CMD commands let you quickly fix issues, check network connectivity, view system information, manage files, or automate repetitive tasks without using Windows’ graphical interface.
7. What does the “ipconfig” command do?
ipconfig displays your computer’s IP address, subnet mask, and default gateway — useful for checking internet and network connections.
8. What does “ping” mean in CMD?
The ping command checks if your system can connect to another device or website. For example, ping google.com tests your internet connection and shows response time.
9. How can I check my Windows version using CMD?
Use the command:
ver
or
systeminfo | find "OS"
to display your Windows version and build details.
10. How do I find my computer’s serial number using CMD?
Run:
wmic bios get serialnumber
It will show your computer’s unique serial number — useful for support or warranty claims.
11. Which CMD command shows running processes?
Use:
tasklist
This displays all active programs and background processes running on your system.
12. How can I close a running program through CMD?
Use:
taskkill /im programname.exe /f
For example, taskkill /im notepad.exe /f will close Notepad immediately.
13. What does “sfc /scannow” do in CMD?
sfc /scannow stands for System File Checker. It scans your system for corrupted Windows files and automatically repairs them.
14. How do I check hard drive health with CMD?
Run:
chkdsk C:
This checks the C drive for disk errors or bad sectors and attempts to repair them.
15. What is the difference between “copy” and “xcopy”?
copytransfers individual files.xcopycan copy entire directories, subfolders, and multiple files at once — useful for backups.
16. How can CMD help with internet issues?
Commands like ipconfig /flushdns, netsh int ip reset, and ping help fix DNS problems, reset IP configurations, and test internet connectivity.
17. What does “netstat” show?
netstat displays all active network connections, open ports, and listening addresses — helpful for diagnosing network or security issues.
18. How can I find my Wi-Fi password using CMD?
Run:
netsh wlan show profile "WiFiName" key=clear
Replace WiFiName with your actual network name to view the saved Wi-Fi password.
19. What is the “diskpart” command used for?
diskpart is a powerful disk management tool in CMD used to partition, format, or clean drives. Be careful — it can permanently erase data if misused.
20. How do I check battery health on a laptop with CMD?
Run:
powercfg /batteryreport
This generates a detailed HTML battery report saved in your user folder.
21. Can CMD be used to automate tasks?
Yes. You can write CMD batch scripts (.bat) to automate repetitive actions such as backups, software launches, or cleanup routines.
22. How do I restart my PC using CMD?
Use:
shutdown /r /t 0
This command restarts your PC immediately.
23. How can I speed up my PC using CMD?
Commands like:
cleanmgr
sfc /scannow
dism /online /cleanup-image /restorehealth
help remove junk files and repair Windows performance issues.
24. Can CMD be used without an internet connection?
Yes, most commands (like file management or system info commands) work offline. However, network commands (ping, ipconfig, nslookup) require internet or LAN access.
25. What are some advanced CMD commands professionals use?
Advanced users often use:
dism /online /cleanup-image /restorehealthfor repairing Windows.netsh wlanfor Wi-Fi troubleshooting.driverqueryfor listing all drivers.taskschd.mscto open Task Scheduler.wmicfor system and hardware control.
🧩 Bonus Tip: Combine Commands for Efficiency
You can chain multiple commands using &&.
Example:
ipconfig && ping google.com
This will display your IP configuration and then test your internet connection automatically.
🧾 Conclusion
CMD remains a powerful and essential tool in every version of Windows, from Windows 7 to Windows 11.
By learning and using these 100 CMD commands regularly, users can manage files faster, fix problems instantly, and take full control of their PC without relying solely on graphical tools.
For beginners, start with basic commands like dir, cd, and ipconfig.
For advanced users, explore dism, netsh, and taskkill to master system maintenance and automation.






