Automatic Shutdown Of Computers On Windows, Mac And Linux
Automatic Shutdown: Pcs Often Go Into Sleep Mode When Left Unused For A While. If, For Any Reason, You Prefer Your System To Shut Down After A Period Of Inactivity, Do Not Miss This Article.
The various operating systems are configured by default to reduce system resource consumption after a few minutes of inactivity or put your computer to sleep if set up.
Suppose you prefer your computer to shut down automatically when you are not using it for a long time. In that case, you can use several methods to schedule the system to shut down automatically.
This article will describe some methods for Windows, Mac, and Linux operating systems.
Automatic shutdown of the computer in Windows
There are three different ways to turn off the computer automatically in Windows, all of which will be explained below. You can use any of these three methods to turn off Windows automatically.
Schedule automatic shutdown of Windows with Task Scheduler
Task Scheduler is a programming tool in the Windows operating system that can create a scheduled task to turn off the PC at a specific time of day. To do this, follow these steps:
- Press the Win key to open the Windows search bar.
- Type Task Scheduler and click the program icon in the search results to open it.
- In the Task Scheduler window, click on Action and select Create Basic Task.
- In the Basic Task window, type a name for the task you want to create (turn off the computer). For example, type Shutdown as the name. You can also provide a job description in the Description section. Click Next.
- You must now select the trigger time. This Time can be set as Timely, Weekly (Monthly), Monthly (Monthly), and Only Once (OneTimee).
- In this example, we selected Daily to turn off the computer at a specific time of day. After selecting, click Next.
- Next, set the start date and Time for repeated Timedowns and click Next.
- In the Action tab, select Start a program and click Next.
- In the Program / Script field, type shutdown.exe and click Next.
- Check the changes and click Finish to create a new task and add it to the Windows application.
The Task Scheduler executes the shutdown action daily at your specified Time and shuts down the computer.
Schedule Windows shutdown with CMD or Run
While the Task Scheduler is a great tool, it may not seem easy to those who have not used it. You can also use the shutdown command on the Windows command line to turn off Windows automatically.
The shutdown command lets you automatically set the timer to turn off your Windows PC. To schedule Windows shutdown with CMD:
- Press Win + X to open the WinX menu.
- Click on Windows Terminal (Admin) to open the following terminal.
- In the Windows Terminal window, type the following command and press Enter:
Shutdown /s -t N seconds
- In the above command, replace N seconds with the number of seconds. For example, if you want to set a timer for 5 minutes (300 seconds), the complete command would be:
Shutdown /s -t 300
- If you want a scheduled restart, type the following command: replace N seconds with the number of seconds to set a timer to restart, and press Enter.
Shutdown -r -t N seconds
- Type the following command and press Enter to cancel, turn off, or restart the timer. You will then see a logoff is canceled message indicating that the shutdown has been canceled.
Shutdown -a
The exciting thing about this method is that you can also type and execute the commands using Run or the same Windows executable with the Win + R key combination. Therefore, this method can be another way to turn off the system automatically.
Automatically shut down Windows by creating desktop shortcuts
You can create a desktop shortcut with a timer to turn off your computer automatically. Creating shortcuts is helpful if you do not want to run Cmd every Time to set the Time. Follow the steps below to create a desktop timer blackout:
- Right-click on your Windows desktop and select New> Shortcut.
- Type the following command in the Type the location of item field, in which 300 seconds (5 minutes) indicates the number of timer seconds. You can change the seconds according to your needs.
Shutdown -s -t 300
- Click Next. —the Type of a name for your shortcut. Type ShutDownTimer, for example.
- Click the Finish button to add a shortcut to the desktop. To change the shortcut icon, right-click the ShutDownTimer desktop shortcut, select Properties, and click the Change icon in the shortcut tab.
- Choose the icon that best represents your blackout timer. In this example, we selected the power icon.
- Click OK to select the option. Then click Apply and OK to save the changes.
To start the shutdown timer, double-click the ShutDown Timer shortcut and use the shutdown -a command in CMD to cancel this Schedule.
Automatically turn off the PC on Mac.
A section called Energy Saver in Mac operating system settings is usually used to control screen shutdown when not in use, hard disk slip mode, system wake-up to access the network, and system shutdown after a power outage. You can also use the Schedule option to schedule the device to turn on or off in this section.
To access Energy Saver on Mac:
- Click the Apple logo in the menu bar and select System Preferences.
- Click on Energy Saver.
- Then click on Schedule.
- Check the box next to the second drop-down menu. This menu determines whether your Mac is turned off, restarted, or in sleep mode.
- Select Shut Down from the drop-down menu.
- Enter the Time and day. For Timeple, if you want the computer to shut down every night at 11:30 pm, select Every Day from the drop-down menu and enter 11:30 in the at box.
- Click OK to turn it off automatically at the specified Time when your systems are on.
Automatic shutdown of the computer in Linux
You must use a terminal to turn off Linux distributions automatically. In Ubuntu, the system is set to shut down as planned using the shutdown command, depending on the value you enter after P-.
Here are the steps to schedule a shutdown in Ubuntu using the shutdown command :
- Press Alt + Ctrl + T to open a terminal and type the command to shut down the system.
$ sudo shutdown -P +30
- In the example above, the 30+ parameter means the system shuts down after 30 minutes, so change the timeline from 30 minutes to 30.
You can also enter the exaTimeime in the system tuTime off instead of setting tTimeime. The following command can be used to do this:
$ sudo shutdown -P 14:00
- This command means the system shuts down at 2 pm, so you must specify the exTimeTime of shutdown iTime: MM format after P-to shut down the system at the Time and Time specified by you. You can also replace P- with h-.
- If you want to cancel the scheduled shutdown, use the c -option after the shutdown command.
sudo shutdown -c
***
We hope you find this helpful tutorial. If you have any questions about automatically shutting down your computer on Windows, Mac, and Linux, please let us and users know.