Recognized Social Butterfly

Shutdown or Restart Computer with One Click

I figured out how to do it in Windows 10.


1. Use Notepad to create two BAT files that can be named Off.bat and Restart.bat .  Do not name the file "Shutdown.bat", for reasons too long to explain.


In Off.bat, put this line:


shutdown /s /t 0


In Restart.bat put this line:


shutdown /r /t 0


2. Using File Explorer, while holding the right mouse button down, drag the files to the desktop and select Create Shortcuts from the context menu.  At this stage, you can shutdown or restart by double clicking these icons.


3. To use one click, you need to put the icons on the taskbar but this can't be done as is.  Right click on the icons and select Properties.


On Target, you will see the full path to the file, e.g.,




Change that to, e.g.,


cmd /c "D:\Documents\Off.bat"


Click Apply and close the dialog box.  The icon's appearance should change.


4. Right click on the two icons and select Pin to Taskbar.  Now, one click on the respective Taskbar icon will shutdown or restart your computer.


There is a program for putting your computer to sleep but I can't get it to work properly.  See


It seems to work properly with hibernation but I don't know much about hibernation.


0 Kudos
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Put on your boogie shoes for the Daybreaker Live: Saturday Morning Fever: A Disco Dance with AARP! Shake your groove thing to live performances featuring Sister Sledge and Indigo Girls on June 26, 2021 at 11 a.m. ET. Register Here AARP Daybreaker Live: Saturday Morning Fever

Members Can Earn Cash Back

Earn 3% cash back rewards at gas stations and drug stores with AARP Membership. Join today for just $12 per year with Automatic Renewal.

AARP Membership

AARP Rewards

Activate AARP Rewards to earn points for games, quizzes and videos. Redeem for deals and discounts. Get started with AARP Rewards now!

AARP Rewards Badge

Join Us For a Concert!

Celebrate Black Music Month and learn more about the powerful connections between music and health during an AARP virtual performance featuring R&B singer Raheem DeVaughn on June 28, 2021 at 8:00 p.m. EST. Register Here.

AARP Concert Series