The fastest way to close a window depends on what device you're using
On Windows, press Alt + F4 while the window is active — that's the quickest method on any screen. On Mac, press Command + W to close the current window, or Command + Q to close the entire application. On phones and tablets, the method varies: swipe up from the bottom on iPhone, swipe down from the top on Android, or tap the X button if one appears on screen. If a window won't close using these methods, it may be frozen, and you'll need to force it shut instead.
Every operating system also lets you close a window by clicking or tapping a button. On Windows and most Linux systems, look for an X in the top-right corner of the window. On Mac, the close button is in the top-left corner and is usually red. On phones, the close button location depends on the app — some put it at the bottom, others at the top.
Key Takeaways
- On Windows, Alt + F4 closes the active window instantly; on Mac, use Command + W for the current window or Command + Q to close the whole application.
- The close button appears in the top-right corner on Windows and top-left on Mac, and is usually marked with an X or a colored circle.
- On iPhones, swipe up from the bottom of the screen; on Android phones, swipe down from the top or use the back button.
- If a window won't respond to these methods, it is likely frozen and you may need to force it closed through your system settings or task manager.
Closing a window on Windows
The X button sits in the top-right corner of almost every window on Windows. Click it once and the window closes. If you prefer keyboard shortcuts, Alt + F4 does the same thing without moving your mouse — hold Alt, press F4, and release both.
Some windows ask you to save changes before closing. A dialog box will appear asking whether you want to save, discard, or cancel. Click the button that matches what you want to do. If you click Cancel, the window stays open.
If a window is frozen and won't respond to the X button or Alt + F4, you'll need to force it closed. Press Ctrl + Alt + Delete, then click Task Manager. Find the frozen program in the list, click it once to select it, then click End Task at the bottom right. The window will close immediately.
Closing a window on Mac
The close button on Mac is a red circle in the top-left corner of the window. Click it once and the window closes. You can also press Command + W to close the current window without using the mouse.
If you want to close the entire application rather than just one window, press Command + Q. This shuts down the program completely. Command + W closes only the active window, so if the application has multiple windows open, the others stay running.
A frozen window on Mac can be closed by pressing Command + Option + Escape. This opens the Force Quit dialog. Find the frozen application in the list, click it, then click Force Quit. The application closes immediately.
Closing a window on iPhone
Most apps on iPhone close when you swipe up from the bottom of the screen. Place your finger at the very bottom edge, then swipe upward in one smooth motion. The app will slide off the screen and close.
Some older apps or web browsers may have an X button or close button visible on screen. If you see one, tap it to close that window or tab. In Safari, for example, you can tap the X on a tab to close just that tab while keeping the browser open.
If an app is frozen and won't respond to swiping, restart your iPhone. Press and hold the side button and either volume button until the power-off slider appears, then drag it to turn off the phone. Wait a few seconds, then press the side button again to turn it back on.
Closing a window on Android
On most Android phones, swipe down from the top of the screen to open the notification panel, then look for the app you want to close. Swipe it to the left or right to remove it from the recent apps list. This closes the window.
Alternatively, press the back button (usually at the bottom of the screen or on the side). This closes the current window and returns you to the previous screen. Some apps also have an X button or menu option to close.
If an app is frozen, open your phone's Settings, go to Apps or Application Manager, find the frozen app in the list, and tap Force Stop. This closes the app immediately. You can then open it again if needed.
Closing multiple windows at once
On Windows, you can close all open windows from one application by pressing Alt + F4 repeatedly, or by using Task Manager to end the entire process. Right-click the application in the taskbar at the bottom and select Close all windows if that option appears.
On Mac, press Command + Q to close the entire application and all its windows at once. If you only want to close some windows, use Command + W on each one individually.
On phones, closing one app window usually closes that app entirely since phones typically run one app at a time in the foreground. To close multiple apps, repeat the swipe or back-button method for each one.
What to do if a window won't close
If clicking the close button or using keyboard shortcuts doesn't work, the window is likely frozen. On Windows, use Ctrl + Alt + Delete and Task Manager. On Mac, use Command + Option + Escape and Force Quit. On phones, restart the device or use the Settings menu to force stop the app.
Before force-closing, try waiting a few seconds — sometimes a window is just slow to respond. If you have unsaved work in that window, force-closing will lose it. Save your work in other windows first if you can.
If a window keeps freezing every time you open it, the application itself may have a problem. Try restarting your device, updating the application, or reinstalling it. If the problem continues, the application may not be compatible with your system.
Frequently Asked Questions
Does closing a window the same as shutting down my computer?
No. Closing a window closes only that program or tab. Shutting down your computer closes everything and turns off the machine. To shut down Windows, click the Start menu and select Shut down. On Mac, click the Apple menu and select Shut Down.
Will I lose my work if I close a window?
Only if you haven't saved it. Most programs ask you to save before closing. If you click Discard or Don't Save, any unsaved changes are lost. If you click Cancel, the window stays open so you can save first.
What's the difference between closing and minimizing a window?
Closing a window shuts it down completely. Minimizing hides it from view but keeps it running in the background. On Windows, the minimize button is next to the close button in the top-right corner. On Mac, it's the yellow circle in the top-left.
Can I close a window without saving my work?
Yes, but you'll lose any changes you haven't saved. The program will usually warn you with a dialog box asking if you want to save before closing. Choose Discard or Don't Save only if you're sure you don't need those changes.
Why does my window keep freezing when I try to close it?
A frozen window usually means the application has stopped responding. Use force quit or Task Manager to close it. If it happens repeatedly, restart your device or reinstall the application. Outdated software or low system memory can also cause freezing.