Microsoft

Shut down Windows 8 from the keyboard

Shut down Windows 8 by just pressing a key on your keyboard, pressing a button on your computer, or closing the lid on your laptop.

After a recent discussion with a friend of mine about getting used to using the [Windows] key on the keyboard in Windows 8 instead of pining away for the Start button, my friend asked about shutting down Windows. As the discussion heated up in a friendly manner, he snarkily said, "There's no shut down key on the keyboard!" As a quick retort, I said "Well, there can be!"

This blog post is also available as a Screenshot Gallery.

I then told him that using a keyboard with programmable hot keys, one could easily configure a key on the keyboard to Shut down Windows 8. Even without such a keyboard, a plain old desktop shortcut can be configured to respond to a keyboard shortcut. As the discussion evolved, I also pointed out that you can shut down Windows 8 using the power button on your desktop PC or closing the lid on a laptop.

Later, I realized that while I had covered several ways to shut down Windows 8, I had not written an article about these techniques.

As you may remember, in How do I shut down Windows 8, Mark Kaelin showed you how to create shutdown shortcut that you can put on the desktop, the taskbar and on the Start screen. (While Mark's article was written during the Windows 8 Consumer Preview stage, the technique is still valid.) In Add a Shutdown menu to the Windows 8 desktop, I showed you how to recreate a reasonable facsimile of the Shut down pop-up menu on Windows 8's taskbar. Then, in Integrate a custom Shutdown menu into the Windows 8 Desktop context menu, I showed you how to how to add a very nice shut down menu to the desktop context menu.

However, shutting down Windows 8 can be simplified to just pressing a key on your keyboard, pressing a button on your computer, or closing the lid on your laptop. In this edition of the Windows Desktop Report, I'll show you how.

Using a shortcut

Since not everyone has a keyboard with programmable hot keys, I'll start with the shortcut method. In the article about integrating a Shut Down menu into the Desktop context menu, I showed you a table containing eight command lines that perform all the options typically associated with terminating an active session. For your convenience, these eight command lines are shown in Table A.

Table A: Command lines that perform all the options typically associated with terminating an active session

Command

Command line

Restart Shutdown -r -f -t 00
Shut Down Shutdown -s -f -t 00
Hybrid Shut Down Shutdown -s -f -t 00 -hybrid
Sleep Rundll32.exe powrprof.dll,SetSuspendState Sleep
Hibernate Shutdown -h
Lock Rundll32 User32.dll,LockWorkStation
Sign Off Shutdown -l
Switch Users Tsdiscon.exe
While you can use any or all of those command lines with this technique, I'll just stick with the Shut Down command for this example. So, if you right-click on the Desktop and select the New | Shortcut command, you can create a shortcut using Shut Down command line, as shown in Figure A.

Figure A

When the Create Shortcut wizard prompts you, enter the command line to shut down window.
Once you have created the shortcut, right-click on it and select the Properties command. When you see the Properties dialog box, select the Shortcut key text box and press the key(s) that you want to use to shut down your Windows 8 system. Of course, you'll want to use an odd keystroke combination that won't interfere with other existing keyboard shortcuts and will not be easy to accidentally press. As you can see in Figure B, I have used [Ctrl] + [F12].

Figure B

You'll want to use an odd keystroke combination that won't interfere with other keyboard shortcuts.

Using a keyboard with programmable hot keys

Lots of keyboards have programmable hot keys. For example, the Logitech Wireless Keyboard K350 and the Microsoft Natural Ergonomic Keyboard 4000 both provide you with programmable hot keys.

I have a Microsoft Natural Ergonomic Keyboard 4000, and have installed the Free Microsoft Mouse and Keyboard Center, which allows you to easily program the available hot keys on Microsoft keyboards and mice. While many of the keys on this particular keyboard are assigned specific actions, such as volume controls or launching Internet Explorer, there are five keys, called My Favorites, at the top center of the keyboard that aren't assigned to any special operations. Using the Microsoft Mouse and Keyboard Center, you can easily configure these keys to access Web sites, open files, launch programs, and even run command line tools.

Returning to eight command lines shown in Table A above, I chose five to assign to the customizable hot keys on my Microsoft keyboard: Shutdown, Restart, Hibernate, Sign off, and Switch.

After launching the Microsoft Mouse and Keyboard Center, I accessed the keyboard section's basic settings, located My Favorites, and typed in the command lines to initiate my chosen options, as shown in Figure C. Now, in addition to shutting down my Windows 8 system from the keyboard, I can restart it, put it into hibernation, sign off, or switch users. (I later affixed custom stickers to those keys to help me remember which key was which.)

Figure C

The Microsoft Mouse and Keyboard Center makes it easy to configure these keys to shut down Windows 8.

Using the PC's power button

Most folks don't associate pressing the power button on a PC with a controlled shut down procedure, because in the old days doing so would just turn off the power - akin to pulling the plug of a running PC. However, pressing the Power button on the front of your PC will initiate the exact same procedure as selecting Shut down from Windows 8's Power Charm, as illustrated in Figure D.

Figure D

Pressing the Power button is the same as selecting the Shut down command.
Now, if you would rather have the Power button perform another operation, such as put Windows 8 to sleep or into hibernation mode, you can do so from the Power Options tool. To immediately access the Power button settings in the Power Options tool, use the [Windows] + W keystroke to access the Search Settings page. Then, type Power button in the text box and click the Change what the power buttons do item, as shown in Figure E.

Figure E

You can quickly access the Power button configuration options from the Search Settings page.
Alternatively, you can move your mouse pointer to the lower left corner of the screen and when the Start Screen button pops up, right click to display the WinX menu. You can then select the Power Options command. When the Power Options window appears, select the Choose what the power button does command. This process is illustrated in Figure F.

Figure F

From the Power Options window, select Choose what the power buttons do.
When you get to the System Settings page, locate the Power button settings section and you'll see that the option is already configured for Shut down, as shown in Figure G.

Figure G

By default, the Power button settings should be configured as Shut down.
Now, if you don't want the Power button to shut down the system, you can click the drop down arrow in the Power button settings section and select one of the other options, such as Hibernate or Sleep, as shown in Figure H. Once you make a change, just click the Save changes button and then close the Power Options window.

Figure H

In addition to Shut down, you can configure the power button to put the system to sleep or into hibernation.

Using a Sleep button

There are actually quite a few keyboards out there that have a Sleep button on them, like the keyboard shown in Figure I. As you can imagine, the Sleep button is automatically configured to put your Windows 8 system into Sleep mode.

Figure I

Many keyboards have a Sleep button.
When you access the System Settings page on a system with such a keyboard, you'll find that the section is titled Power and sleep button settings. If you click the drop down menu, you can also choose Hibernate, as shown in Figure J.

Figure J

The System Settings page allows you to reconfigure the Sleep button.

Closing the lid

On a laptop, you have one more option for terminating an active session - closing the lid. When you access the System Settings page on a laptop, you'll find that the section is titled Power and sleep buttons and lid settings. As you can see in Figure K, on this particular laptop, I have configured the When I close the lid setting to be a Shut Down operation when on battery and a Hibernate operation when plugged into AC power.

Figure K

On a laptop, you can configure the various operations to occur when you close the lid.

What's your take?

As you can see, there are a number of different ways that you can shut down a Windows 8 system. What method do you currently use? Are you interested in employing one of the keyboard or power button techniques shown in this article? As always, if you have comments or information to share about this topic, please take a moment to drop by the TechRepublic Community Forums and let us hear from you.

Also read:

About

Greg Shultz is a freelance Technical Writer. Previously, he has worked as Documentation Specialist in the software industry, a Technical Support Specialist in educational industry, and a Technical Journalist in the computer publishing industry.

28 comments
RegexJoe
RegexJoe

Also this built-in keyboard shortcut will shutdown Windows 8.1: WinKey+X, U, U.
Modify the last key based on the displayed submenu items to restart, sleep, etc.

CharlieSpencer
CharlieSpencer

You're correct; I completely forgot that method.

mxw1990
mxw1990

Guys lets not forget things can be simple. Yes its crap I know, I am very annoyed by it as I used to do the following on windows 7. windows key right enter Now on windows 8 it can be on of the below: windows key + D Alt + F4 OR ctrl + alt + del OR Copy the below line shutdown.exe /s /t 00 Windows key ctrl + v right click shutdown.exe /s /t 00 pin to start menu shift + right click on newly pinned icon properties change icon... select power icon Boom

raghavnk
raghavnk

I fully agree with djo 165's comment. Why on earth do we have to look for all kinds devious ways to do everyday tasks like shutdown/hibernate/sleep? This is exactly where MS messed up in WIN 8, and why most people are not willingly switching to it.

Kenogami
Kenogami

What is the problem? All I do is click the Win icon bottom left corner and do what I want. Shut down, sleep or hibernate. You don't need to write code or anything. If that's not enough, go to power save and set that up. \\\\\to many minds thinking out of the box. Get back to real life. Randy

ccastro
ccastro

Just make sure you are on the Desktop when you do this, but Alt + F4 works even on my laptop. (You may need to use your function or fn key on your laptop)

phstacker
phstacker

We recently purchased a couple Gateway desktop computers which came with Windows 8. Having worked with computers for over 40 years, my first impression was that this was a dumbed down System 7 with a Shell for the Apps. Haven't a lot of us played with virtual desktops - seems same to me. If my assessment is correct, seems the simple addition to the system would be a user mode to set things back to how they are in System 7 but keep the Apps page the same. But I have heard the Start Menu is coming back in 8.1 - sorta - will the Shut Down be back there again ?

pbug56
pbug56

The whole thing about WIndoze 8 MUTRO classic VGA and toddler style block GUI; it's not usable as is for so many people, even worse in a business setting. My 23 inch screen non-touch monitor only usable for a couple windows at a time? Or my 2 smaller monitor equipped work laptop? I'd get nothing done. And beyond that, if we have to customize 8 to give it a reasonably easy way to shut it down, that is beyond absurd. It is sheer arrogance by Microsloth.

carlsf
carlsf

Ever put it on put it our computers. If we cant get Windows 7 with a PC system it will be Linux (Zorin 6). And unless the Update has the Start button and also the Start Menu we will stay where e are.

Sul52
Sul52

I've been using a Surface Pro for a little over a month now. And for the life of me in a business environment can't see any value in the Tiles. It is nearly impossible to work out of that menu and switching windows (yeah, I know there are keystrokes - but on a tablet there is no keyboard!!!!) is nearly impossible and was huge time suck. I've installed 3 utilities that "convert" back to Windows 7 style and add some additional organizational tools for my apps and multiple windows sessions. Without those, this Surface Pro would have been back to Microsoft. (BTW, as hardware goes, I am really starting to like the Surface Pro. It has become my primary work machine. I would have liked to seen the Samsung ATIV before buying this, but it is a really good solution for my use. Lots of limitations, but still a really good first try by MS.)

bonnarb
bonnarb

You have to make sure you're at the Desktop first. As long as you're in the desktop environment (not on the Start Screen), press Windows+D (the Widows logo key) to bring focus to the desktop, then press ALT+F4. This will present you with the option to shut down, restart, sign out, switch user and sleep. I've used this method with Windows 7 as well, since my old XP shortcut (Windows, U) doesn't work with Win 7's enhanced Start menu.

mrAverage
mrAverage

Sorry all I truly dislike window 8....WHY? As a business user and being a fossil as to the highest and best use of computers, I made it simple and Installed a very functional and satisfying Shell to make the system function very similar to windows 7 including default to desktop and the "old" start menu ....which includes an easy old fashion way to shut down the system SHUT DOWN, RESTART...etc. BORING...But Functional Someday I may become a "social butterfly" but until that day the shell is my favorite thing about windows 8....a way not to use a phone layout for business functions and still have both world available just in case I evolve from the pupa stage. There are several versions and suppliers so I will not recommend one. As it so happens the one I use was suggested by a VERY BRIGHT best buy tech/sales person ...thanks Eddie.

Rob C
Rob C

I was going to ask - Does repeated Alt F4 do what it did in every previous version of Windows ? Or is that another tried and true thingy, that MS has thrown out of the window with the bath water ? MS is really starting to annoy me.

Graham.Foster
Graham.Foster

Alt+F4 will bring up the shutdown list if the Desktop is selected.

TechIan16
TechIan16

well that is one way to do it! There are other options as others have noted but I can see how those may not have the exact functionality one might be looking for. However this does seem like an awful lot of work for someone who is less tech savvy.

eboyhan
eboyhan

It seems that in all these "shutdown" discussions a very simple alternative is ignored: the venerable "Ctrl-Alt-Del" key combination. This will work with any keyboard, requires no shortcuts or registry machinations; and it can be invoked either from the "Metro" or the "Desktop" side of things. What you get is a full screen "menu" which gives you access to Ease-of-Access (lower left of screen), Shutdown (lower right of screen), and in the center of the screen access to the Lock, Switch User, Logoff, and Task Manager selections. I find this to be a very handy way to interrupt whatever I'm doing in any W8 state, and quickly sleep, shutdown, check a stalled machine, or transition to some other run state.

The Former Moley
The Former Moley

Why oh why must things be so complicated and obtuse for simple every day tasks with Windows 8. We're not all technical nerds.

bd1235
bd1235

I always make a shortcut for Shutdown and pin it to the left hand end of the task bar. One click and it's gone. The only other one I use occasionally is Restart and I have a shortcut for that on the desktop. One of my friends used to use the case Power Button to power down. One day she called me and said "hey Bob, my machine keeps starting and then powering down almost immediately. Can you look at it". I had a look and the Power Button was binding in because it had too much use. Leave it for 5 minutes and it popped out again. It wasn't designed for a lot of use. A quick spray with a wax lubricant and it was OK again. Many cases are like that.

broozm
broozm

Does good old Alt-F4 no longer work? Can be a bit tricky showing laptop users this when the F keys have to have the Fn key pressed to make them work. Grabbing and throwing all the open apps down to close them first is also a little impractical. Perhaps just grab the laptop and close win8 forever by throwing it? :)

Mark W. Kaelin
Mark W. Kaelin

Okay, I think we have finally put this meme to bed - you can, indeed, shut down Windows 8. In fact you have many ways to accomplish this task. Have we missed any Windows 8 shut down techniques? Are you satisfied with your shut down choices now?

CharlieSpencer
CharlieSpencer

That W7 didn't have 'Shutdown from keyboard' capability either, without taking similar steps to those described in the article. Or Vista, or XP, or 2K...

djo165
djo165

Windows 7 could be shutdown with three keystrokes. Hit the Win key, then the right arrow, then Enter. It's appaling that users have to create a shortcut to do something so basic on Windows 8. This should be built in the GUI straight from MS.

Webminotaur
Webminotaur

This works from the Desktop if the focus is not on any program. It doesn't work on the Start Page, or if the focus is on another program (such as IE). In the latter case, the key combination only closes whatever program is showing.

Ndiaz.fuentes
Ndiaz.fuentes

I will concede that the shutdown in W8 is a bit hard to find for first time users. However, that should be fixed with the tutorial to be included in new W8 systems. As for steps needed to turn off the system, it's pretty similar in both OS's. There's only a one step difference. In W7: move mouse to start, click start, click shut down. In W8, move mouse to charms, click settings, click power, click shut down. In terms of key presses, the same two step proceadure works in both OS's: Alt-F4, then enter. Should the command be easier to find? Yes. But is it complicated? No.

Ndiaz.fuentes
Ndiaz.fuentes

Other than the start page (which is new to Win8) the functionality you describe is exactly as it was in Win7.

Editor's Picks