Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

How can I change the shortcut for closing windows from Alt+F4 to Ctrl+W in windows.

share|improve this question
Which version of Windows? –  Jeff F. Jan 14 '11 at 14:06
Tell the developers of the application you're using to support this with Ctrl-W. Some applications (even Windows Explorer, if I'm not mistaken) support this. –  Daniel Beck Jan 14 '11 at 14:12
Maybe an Autohotkey expert can give you a hand with this. –  Mehper C. Palavuzlar Jan 14 '11 at 14:30

2 Answers 2

  1. Download and install AutoHotkey
  2. Create an empty file called shortcuts.ahk
  3. Create a shortcut to that file and put it in the Startup folder
  4. Edit shortcuts.ahk and put this in it:

    ^w::Send ^{F4}

  5. Double click on shortcuts.ahk

Keep in mind that Ctrl+W is used for other things, e.g. in Notepad², it enables word wrap.

See also:

share|improve this answer

I think that even an AutoHotkey beginner can do this. The script is as follows:

Alt & F4::
Ctrl & w::
    WinClose, A

But what if you just wanted to close a Word document or a Firefox tab (when Ctrl+W is used as a hotkey), not the whole application?

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.