Useful Windows Commands

en | de

The following Windows command line commands I find somehow interesting, special or just useful.
Warning be sure to know and understand what a command does before executing it!

NetworkFirewall reset!netsh firewall resetReset the Windows Firewall configuration to default.yesyesyesyesyes
FilesSystem file attributeattrib +s +h mydirSet the hidden and system file attribute for "mydir" (file or directory).yesyesyesyesyes
NetworkSet IPnetsh interface ip set address name="Ethernet" source=static addr= mask= gateway= gwmetric=0Set the IP address, subnet mask and the default gateway for the interface: "Local Area Connection".yesyesyesyesyes
NetworkSet DNSnetsh interface ip set dns name="Ethernet" source=static addr= register=PRIMARYSet a static DNS server address.yesyesyesyesyes
NetworkTelnet!RunDLL32 url.dll,TelnetProtocolHandler a telnet connection to
DesktopScreensaverRunDLL32 desk.cpl,InstallScreenSaver c:\windows\system32\ssText3d.scrOpen the screensaver properties dialog and select the "3D-Text" screensaver.yesyesyesyesyes
DesktopLock WindowsRunDLL32 user32.dll,LockWorkStationLock Windowsyesyesyesyesyes
SystemEnable hibernationpowercfg -H onEnable the hibernate feature (even after deleting Hiberfil.sys).yesyesyesyesyes
SystemSyskeySyskeyConfigure additional encryption for the Windows Account Database.yesyesyesyesyes
SystemPrinter managementRunDLL32 PRINTUI.DLL,PrintUIEntry /?List command line options for the printer User Interface.yesyesyesyesyes
SystemInstall INF fileRunDLL32 syssetup,SetupInfObjectInstallAction DefaultInstall 128 .\filename.infInstall a .INF file in Command lineyesyesyesyesyes
SystemExtend Windows trialslmgr -rearmReset the 30-day trial period. Can be run three times. yesyesyesyes
ToolDefault BrowserRunDLL32 url.dll,FileProtocolHandler www.svolpi.chOpen with the default browser.yesyesyesyesyes
Internet ExplorerClear IE historyRunDLL32 InetCpl.cpl,ClearMyTracksByProcess 1Delete the list of websites you have visited in Internet Explorer.yesyesyesyesyes
Internet ExplorerDelete IE CookiesRunDLL32 InetCpl.cpl,ClearMyTracksByProcess 2Delete stored Internet Explorer cookies.yesyesyesyesyes
Internet ExplorerDelete temporary internet filesRunDLL32 InetCpl.cpl,ClearMyTracksByProcess 8Delete saved copies of webpages, images, and media.yesyesyesyesyes
Internet ExplorerDelete Form dataRunDLL32 InetCpl.cpl,ClearMyTracksByProcess 16Delete saved information that you have typed into forms.yesyesyesyesyes
Internet ExplorerDelete PasswordsRunDLL32 InetCpl.cpl,ClearMyTracksByProcess 32Delete passwords automatically saved by Internet Explorer.yesyesyesyesyes
Internet ExplorerDelete all temporary dataRunDLL32 InetCpl.cpl,ClearMyTracksByProcess 255Delete Temporary Internet Files, Cookies, History, Form data, and Passwords stored by Internet Explorer.yesyesyesyesyes
SystemSwitch mouse buttonsRunDLL32 User32.dll,SwapMouseButtonSwitch primary and secondary mouse buttons (to reset use "main.cpl").yesyesyesyesyes
DesktopRefresh user settingsRunDLL32 user32.dll,UpdatePerUserSystemParameters ,1 ,TrueUpdate the desktop and other per user system settings.yes? yesyes
SystemBeepcmd /c @echo System Beep (ASCII 007)yesyesyesyesyes
NetworkReset TCP/IPnetsh interface ip reset c:\resetlog.txtReset the IP configuration and write the results to "c:\resetlog.txt".yesyesyesyesyes
ToolMultiple RegeditRegedit /mUse this command to open multiple instances of Regedit.yesyesyesyesyes
Shadow CopyShadow Copy Infosvssadmin list shadowstorageShow used storage and other Shadow Copy information. yesyesyesyes
Shadow CopyDelete oldest shadowsvssadmin delete shadows /for=c: /oldestDelete the oldest shadows on Drive C:\. yesyesyesyes
Shadow CopyMax Shadow sizevssadmin resize shadowstorage /For=C: /On=C: /MaxSize=1GBSet the max Shadow Copy size to 1GB. yesyesyesyes
OfficeRepair Word!winword.exe /rRepair file association and Registry keys used by Word.yesyesyesyesyes
NetworkOpen filesOpenFiles.exeShow files opened remotely via local share points.yesyesyesyesyes
FilesDummy filefsutil file createnew C:\testfile.txt 1048576Create a 1MB dummy file. yesyesyesyesyes
FilesSearch into through filesfindstr /ins "date" "*.vbs"List ".vbs" files containing the string "date".yesyesyesyesyes
SystemProcess idle tasksRunDLL32 advapi32.dll,ProcessIdleTasksManually start the built in optimization routine (Indexing, Boot Defrag ...).yesyesyesyesyes
NetworkDisable Firewallsc config SharedAccess start= disabledDisable the SharedAccess service which is used by the Windows Firewall.yesyesyesyesyes
NetworkShare Creation WizardShrpubw.exeStart the "Share Creation Wizard".yesyesyesyesyes
SystemShutdown GUIshutdown -iOpens the remote shutdown Dialog.yesyesyesyesyes
SystemDeactivate Guest accountnet user Guest /ACTIVE:NODisable Guest accountyesyesyesyesyes
NetworkFirewall resetnetsh advfirewall resetReset the Windows Firewall yesyesyesyes
SystemTouchscreen Calibration TooltabcalCalibrate your Tablet / Touchscreen. yesyesyesyes
SystemDriver Verifier ManagerverifierTool to detect and troubleshoot many driver issues.yesyesyesyesyes
PrinterPrinter MigrationprintbrmuiExports printer queues, printer ports, and printer drivers to a file. yesyesyesyes
WindowsLogofflogoffLog off from Windows.yesyesyesyesyes
MultimediaDVD PlayerdvdplayRuns Windows Media Player to play a DVD.yesyesyesyesyes
WindowsOn-Screen KeyboardoskShow the On-Screen Keyboardyesyesyesyesyes
SecuritySave domain credentialscmdkey /add:Server01 /user:MYDOMAIN\admin /pass:P@ssw0rdSave credentials to access Server01 as the domain user admin. yesyesyesyes
SecuritySave generic credentialscmdkey /generic:Server01 /user:Server01\admin /pass:P@ssw0rdSave generic credentials to access Server01 as the local user admin. yesyesyesyes
SecurityList stored credentialscmdkey /listDisplays the list of stored user names and credentials. yesyesyesyes
SecurityDelete stored credentials!cmdkey /delete:Server01Delete the credential that is stored for Server01. yesyesyesyes
SystemAvailable Windows Featuresdism.exe /Online /Get-Features /Format:TableList all available Windows features. ?yesyesyes
SystemEnable Windows Featuredism.exe /online /Enable-Feature /FeatureName:TFTPEnables a specified Windows feature; here the TFTP Client. ?yesyesyes
SystemDisable Windows Featuredism.exe /online /Disable-Feature /FeatureName:TFTPDisables a specified Windows feature; here the TFTP Client. ?yesyesyes
ToolWindows Malicious Software Removal Tool!mrt.exeRun "Windows Malicious Software Removal Tool".yesyesyesyes?
SystemHibernate / StandbyRunDLL32 powrprof.dll,SetSuspendStateIf hibernation is enabled in "Powercfg.cpl" the system hibernates else the system goes into Standby mode.yesyesyesyes?
NetworkBluetooth Transfer!fsquirtLaunches the BlueTooth File Transfer Wizard.yesyes???
WindowsSignaturcheck für Treiber abschalten!bcdedit.exe /set nocheckintegritys ONDisable Windows driver signing (integrity checks). yesyes??
SystemDisk CleanupcleanmgrClears unnecessary files from your computer's hard disk.yesyesyesyes?
SystemSystemsteuerung einrichtenRunDLL32 shell32.dll,Control_FillCache_RunDLLInitialize Control Panel Applets.yes    
DesktopNew BriefcaseRunDLL32 syncui.dll,Briefcase_CreateCreates a new briefcase on the desktop.yes    
VistaWindows Flip 3DRunDLL32 DwmApi #105Show the 3D window switching in Windows Vista / 7. yesyesyes 
ToolWindows UpdatewupdmgrOpen the Windows Update website.yes    
SystemDisable Zipregsvr32 /u zipfldr.dllDisable the built-in zip folder featureyes    
SystemDisable CABregsvr32 /u cabview.dllDisable the built-in CAB folder featureyes    
Internet ExplorerClear IE brandingRunDLL32 IEdkcs32.dll,ClearRemove brandings in Internet Explorer.yesyesyes  
DesktopShow Desktop iconregsvr32.exe /n /i:u shell32Re-create the Show desktop icon after reboot.yes    
DesktopEnable AeroRunDLL32 DwmApi #102Enable the Windows Aero user interface. yesyes  
DesktopDisable AeroRunDLL32 DwmApi #104Disable the Windows Aero user interface. yesyes  
SoftwareInstall HyperTerminalRunDLL32 ADVPACK.DLL,LaunchINFSection %windir%\INF\communic.inf,HypertrmInstall HyperTerminalyes    
SoftwareUninstall HyperTerminalRunDLL32 ADVPACK.DLL,LaunchINFSection %windir%\INF\communic.inf,HypertrmUninstallUninstall HyperTerminalyes    
NetworkUninstall IPv6netsh interface ipv6 uninstallUninstall IPv6.yes    
SoftwareUninstall Windows messengerRunDLL32 advpack.dll,LaunchINFSection %windir%\inf\msmsgs.inf,BLC.RemoveRemove Windows messenger from the computer.yes    

(69 entries)
Tested on: Windows XP SP3, Windows Vista SP2, Windows 7, Windows 8.1 and Windows 10