If you are using a Windows operating system for a while, then you might be well aware of the Command Prompt. It is a command-line interpreter that interacts with the user through a command-line interface.
Command Prompt could be very useful if you know the commands. We have shared a detailed guide on 200+ CMD commands for Windows 10 to carry out different things. In this article, we will be discussing a trick that would help you to shut down your PC using the command prompt.
Shut Down Windows 10 Using Command Prompt
The great thing is that turning off the computer through Command Prompt provides you more options and flexibility. So, let’s check out how to shut down Windows 10 computers using the Command Prompt.
Step 1. First of all, press Windows Key + R to open the RUN dialog box.
Step 2. On the RUN dialog box, enter ‘CMD’ and press the enter button.
Step 3. Now on the command prompt, you need to enter
'shutdown /s'. This will shut down your PC in a minute.
Step 4. To restart your PC, you need to enter the command
Step 5. To access the full list of shutting down options, type in
'shutdown /?' and Hit enter. This will list out all options.
List of Shut Down Options Available through Command Prompt
Below, we have listed all of the shutdown options that were available via Command Prompt. Depending on your needs, you can execute the commands on the command prompt. Just add the codes after the prefix ‘shutdown’ like ‘shutdown /sg’, ‘shutdown /g’, etc.
/? – Display help.
/i – Display the graphical user interface (GUI).
/l – Log off. This cannot be used with /m or /d options.
/s – Shutdown the computer.
/sg – Shutdown the computer. On the next boot, if Automatic Restart Sign-On is enabled, automatically sign in and lock the last interactive user. After sign in, restart any registered applications.
/r – Full shutdown and restart the computer.
/g – Full shutdown and restart the computer. After the system is rebooted, if Automatic Restart Sign-On is enabled, automatically sign in and lock the last interactive user. After sign in, restart any registered applications.
/a – Abort a system shutdown. This can only be used during the time-out period. Combine with /fw to clear any pending boots to the firmware.
/p – Turn off the local computer with no time-out or warning. It can be used with /d and /f options.
/h – Hibernate the local computer. It can be used with the /f option.
/hybrid – Performs a shutdown of the computer and prepares it for a fast startup. Must be used with /s option.
/fw – Combine with a shutdown option to cause the next boot to go to the firmware user interface.
/e – Document the reason for an unexpected shutdown of a computer.
/o – Go to the advanced boot options menu and restart the computer. Must be used with /r option.
/m \\computer – Specify the target computer
/t xxx – Set the time-out period before shutdown to xxx seconds. The valid range is 0-315360000 (10 years), with a default of 30. If the time-out period is greater than 0, the /f parameter is implied.
/c “comment” – Comment on the reason for the restart or shutdown. A maximum of 512 characters allowed.
/f – Force running applications to close without forewarning users. The /f parameter is implied when a value greater than 0 is specified for the /t parameter.
/d [p|u]xx:yy – Provide the reason for the restart or shutdown. p indicates that the restart or shutdown is planned. u indicates that the reason is user-defined. xx is the major reason number (positive integer less than 256). yy is the minor reason number (positive integer less than 65536)
So, this is all about how to shut down your Windows 10 computer using the Command Prompt. If you have any doubts related to this, let us know in the comment box below. I hope this article helped you! Share it with your friends also.