Follow
Windows

How to Enable or Disable Closing Warnings in Windows Terminal

Richard
Written by
Richard
Mar 11, 2023 Updated Apr 30, 2026 3 min read
How to Enable or Disable Closing Warnings in Windows Terminal

Windows Terminal is a powerful tool for running command-line programs like Command Prompt, PowerShell, and WSL. It supports multiple tabs, custom themes, and fast text rendering. A common question is how to manage the confirmation prompt when closing the window.

Why do this? By default, Windows Terminal warns you if you try to close the window while several tabs are open. This prevents accidental closure and data loss. You might want to turn this off for a faster exit or keep it on to protect your active sessions.

What happens when done? Once you change this setting, Windows Terminal will either stop asking for confirmation before closing or start prompting you every time you close multiple tabs at once.

Single-Tab vs. Multi-Tab Warning Distinction

It is important to clarify a common point of confusion. Windows Terminal currently does not support a native warning for closing a single tab. The confirmCloseAllTabs setting only triggers when you attempt to close a window that contains multiple active tabs. If you have only one tab open, the terminal will close immediately without a prompt.

Method 1: Using the Settings Menu

  1. Open the Windows Terminal app. Search for “Terminal” in your Start menu.
windows 11 open terminal app
  1. Click the down arrow at the top of the window and choose Settings.
Windows Terminal Settings button updated
  1. Click on the Interaction tab on the left.
  2. Find the option labeled “Warn when closing more than one tab.”
  3. Toggle the switch to On to enable the warning, or Off to disable it.
Windows Terminal warn when closing more than one tab
  1. Click the Save button to apply your changes.

Method 2: Using the JSON Configuration File

Advanced users can modify the settings.json file directly. This file controls the configuration schema for the entire application.

  1. Open the Windows Terminal settings.
  2. Click the Open JSON file button in the bottom left corner.
Windows Terminal open json file
  1. Locate the "confirmCloseAllTabs" property within the file.
Windows Terminal open json file configuration section
💻Code
"confirmCloseAllTabs": true
  1. To disable the warning, set the value to false. To enable it, set it to true.
  2. Save the file to apply your changes.
Windows Terminal with warning window

Troubleshooting and Configuration Context

If your settings are not saving, ensure you are not running an older version of Windows Terminal. If you encounter issues, you can reset your settings by deleting the settings.json file located at %LOCALAPPDATA%\Packages\Microsoft.WindowsTerminal_8wekyb3d8bbwe\LocalState\settings.json. The application will regenerate a default file upon the next launch. Note that Group Policy settings managed by an administrator may override your local configuration.

For further technical documentation, visit the official Microsoft Windows Terminal documentation or check the GitHub repository for known issues.

Summary

Windows Terminal helps you stay organized with a tabbed interface. While you cannot enable a warning for closing a single tab, you can easily toggle the confirmation prompt for multi-tab windows via the Interaction settings or the settings.json file. This ensures your terminal session remains secure from accidental closure while maintaining your preferred workflow optimization.

Why does Windows Terminal not warn me when closing one tab?

Windows Terminal is designed for efficiency. The warning system is specifically built to prevent the accidental loss of multiple active sessions or background processes. Closing a single tab is considered an intentional action, so the application does not interrupt your workflow with a confirmation prompt for a single tab closure.

Does the warning apply to all profiles?

Yes, the confirmCloseAllTabs setting is a global configuration. It applies to all profiles, including PowerShell, Command Prompt, and WSL. When enabled, it triggers a confirmation prompt regardless of which shell or SSH session is currently active in the tabs being closed.

Was this guide helpful?

Tags: #Windows 11
Was this helpful?
Richard

About the Author

Richard

Tech Writer, IT Professional

Richard, a writer for Geek Rewind, is a tech enthusiast who loves breaking down complex IT topics into simple, easy-to-understand ideas. With years of hands-on experience in system administration and enterprise IT operations, he’s developed a knack for offering practical tips and solutions. Richard aims to make technology more accessible and actionable. He's deeply committed to the Geek Rewind community, always ready to answer questions and engage in discussions.

📚 Related Tutorials

How to Set Default Profile in Windows Terminal
Windows How to Set Default Profile in Windows Terminal
How to Open Windows Terminal as Admin Automatically
Windows How to Open Windows Terminal as Admin Automatically
How to Change Windows Terminal Launch Size
Windows How to Change Windows Terminal Launch Size
How to Change Windows Terminal Launch Mode in Windows 11
Windows How to Change Windows Terminal Launch Mode in Windows 11

No comments yet — be the first to share your thoughts!

Leave a Comment

Your email address will not be published. Required fields are marked *