NirCmd - Windows command line tool
Main Page
Blog
Search
FAQ
TOP 10
Pad Files
Contact
About...
Donate
All Utilities
Password Tools
System Tools
Browser Tools
Programmer Tools
Network Tools
Outlook/Office
64-bit Download
Panel
Forensics
Pre-Release Tools
Articles
NirCmd v2.87
Copyright (c) 2003 - 2024 Nir Sofer
See Also
SoundVolumeView - Display, change, mute, unmute the volume level of sound components on Windows 10/7/8/2008 from command line or GUI .<br>NK2Edit - Edit, merge and fix the AutoComplete files (.NK2) of Microsoft Outlook.
Description
NirCmd is a small command-line utility that allows you to do some useful tasks without<br>displaying any user interface. By running NirCmd with simple command-line option, you can<br>write and delete values and keys in the Registry, write values into INI file, dial to your<br>internet account or connect to a VPN network, restart windows or shut down the computer,<br>create shortcut to a file, change the created/modified date of a file, change your display<br>settings, turn off your monitor, open the door of your CD-ROM drive, and more...
Examples of what you can do with NirCmd
Open the door of J: CD-ROM drive
nircmd.exe cdrom open j:
Close the door of Y: CD-ROM drive
nircmd.exe cdrom close y:
Speaks the text currently in the clipboard (For Windows XP/Vista/7/8).
speak text ~$clipboard$
Speaks the text stored inside speak.txt into speak.wav filename (For Windows XP/Vista/7/8).
speak file "c:\temp\speak.txt" 0 100 "c:\temp\speak.wav" 48kHz16BitStereo
Increase the system volume by 2000 units (out of 65535)
nircmd.exe changesysvolume 2000
Decrease the system volume by 5000 units (out of 65535)
nircmd.exe changesysvolume -5000
Set the volume to the highest value
nircmd.exe setsysvolume 65535
Mute the system volume
nircmd.exe mutesysvolume 1
Unmute the system volume
nircmd.exe mutesysvolume 0
Switch the system volume between the mute and normal state.
nircmd.exe mutesysvolume 2
Create a shortcut on your desktop that switch the system volume between the mute and normal state.
nircmd.exe cmdshortcut "~$folder.desktop$" "Switch Volume" mutesysvolume 2
Turn off the monitor
nircmd.exe monitor off
Start the default screen saver
nircmd.exe screensaver
Put your computer in 'standby' mode
nircmd.exe standby
log off the current user
nircmd.exe exitwin logoff
Ask if you want to reboot, and if you answer 'Yes', reboot the computer.
nircmd.exe qboxcom "Do you want to reboot ?" "question" exitwin reboot
Turn off your computer
nircmd.exe exitwin poweroff
Turn off all computers specified in computers.txt !
multiremote copy "c:\temp\computers.txt" exitwin poweroff force
Dial to "My Internet" connection
nircmd.exe rasdial "My Internet"
Disconnect the "My Internet" connection
nircmd.exe rashangup "My Internet"
Make your Internet Explorer windows 75% transparent ! (192 / 256)
nircmd.exe win trans ititle "internet explorer" 192
Minimize all your Internet Explorer windows
nircmd.exe win min class "IEFrame"
Close all your Internet Explorer windows
nircmd.exe win close class "IEFrame"
Close all your Explorer windows (My Computer, folders, and so on)
nircmd.exe win close class "CabinetWClass"
Hide all your Internet Explorer windows
nircmd.exe win hide class "IEFrame"
Show all your Internet Explorer windows (after you made them hidden with previous example)
nircmd.exe win show class "IEFrame"
Center all top-level windows
nircmd.exe win center alltop
Remove the title bar of My Computer window.
nircmd.exe win -style title "my computer" 0x00C00000
Return the title bar of My Computer window that we removed in the previous example.
nircmd.exe win +style title "my computer" 0x00C00000
Set the My Computer window to right-to-left order (For hebrew and arabic languages)
nircmd win +exstyle title "my computer" 0x00400000
Set all child windows of My Computer window to right-to-left order (For hebrew and arabic languages)
nircmd win child title "my computer" +exstyle all 0x00400000
Create a shortcut on your desktop that closes all your Internet Explorer windows
nircmd.exe cmdshortcut " "~$folder.desktop$ "Close All IE" win close class "IEFrame"
Create a shortcut on your desktop that hides all your Internet Explorer windows
nircmd.exe cmdshortcut " "~$folder.desktop$ "Hide All IE" win hide class "IEFrame"
Create a shortcut on your desktop that shows back all your Internet Explorer windows
nircmd.exe cmdshortcut " "~$folder.desktop$ "Show All IE" win show class "IEFrame"
Set the Windows Calculator as top-most window (above all other windows)
nircmd.exe win settopmost title "Calculator" 1
Set the Windows Calculator back to regular window (non top-most window)
nircmd.exe win settopmost title "Calculator" 0
Create a shortcut to Windows calculator under Start Menu->Programs->Calculators
nircmd.exe shortcut "f:\winnt\system32\calc.exe" "~$folder.programs$\Calculators" "Windows Calculator"
Hide the desktop window
nircmd.exe win...