Instructions to enable / disable Windows Firewall with Command Prompt
A firewall is like a barrier between a local network (local network) and another network (such as the Internet), controlling incoming and outgoing data traffic.
In the previous article, the Network Administrator showed you how to enable / disable the Firewall through Control Panel. In the article below, Network Administrator will show you how to enable / disable Windows Firewall with Command Prompt.
Part 1: Enable / disable Windows Firewall
To enable / disable Windows Firewall with Command Prompt, follow the steps below:
Step 1:
First open the Command Prompt. To do this, enter cmd in the Search box on the Start Menu.
Step 2:
On the search results list, right-click Command Prompt and click Run as administrator to open the Command Prompt under Admin.
Step 3:
To turn off Windows Firewall, enter the following command into the Command Prompt window:
netsh advfirewall set allprofiles state off
Step 4:
If there are no errors, the Command Prompt window will display a message with an OK message.
Step 5:
If you want to activate (reopen) Windows Firewall, follow the same steps and enter the following command into the Command Prompt window:
netsh advfirewall set allprofiles state on
Step 6:
If there are no errors, the Command Prompt window will display a message with an OK message.
2. Some other commands
Alternatively, you can use some other commands to manipulate Windows Firewall:
1. Enable / disable Firewall for the current account
If you want to enable or disable Windows Firewall for the current user account, use the following commands:
- To disable Windows Firewall:
netsh advfirewall set currentprofile state off
- To activate Windows Firewall:
netsh advfirewall set currentprofile state on
2. Firewall on Domain Network
- To disable Firewall:
netsh advfirewall set domainprofile state off
- To activate the Firewall:
netsh advfirewall set domainprofile state on
3. Firewall on Public Network
- Disable Windows Firewall:
netsh advfirewall set publicprofile state off
- Enable Windows Firewall "
netsh advfirewall set publicprofile state on
4. Firewall on Private Network
- Disable Windows Firewall:
netsh advfirewall set privateprofile state off
- Activate Windows Firewall:
netsh advfirewall set privateprofile state on
Refer to some of the following articles:
- How to block or unblock programs on Windows Firewall?
- Instructions allow applications to communicate with each other via Windows Firewall
- How to disable / enable Windows Firewall in Windows 7, 8
Good luck!
You should read it
- 3 ways to turn off the Windows 10 firewall, steps to turn off the firewall on Windows 10
- How to turn firewall (Firewall) on Win 7
- How to turn on the router's built-in firewall
- How to turn on / off Windows Firewall in Windows 7, 8 / 8.1 and Windows 10
- How to turn firewall on and off in Windows 10
- How to use a firewall in Windows 10
- Instructions to enable and disable Firewall firewall in Windows
- 5 reasons why you should use a firewall
May be interested
- 6 Cool Tricks You Can Do in Windows Command Promptcommand prompt has a ton of capabilities, and many people doubt they know what a few lines of code can do. next time you're bored with your pc, try these cool command prompt tricks for yourself.
- How to Customize the Font in Windows Command Promptmany people work regularly with the windows command prompt. one of the main problems users encounter, however, is the difficulty of achieving the same look every time one works with the command prompt interface. this article is intended to...
- How to activate or add additional fonts in Command Promptwant to enable additional font options in the command prompt? follow these steps to add new fonts to the command prompt in windows 10.
- 6 Best Command Prompt Alternatives for Windowsdo you find the command prompt a bit complicated and feel you need a tool that is easier to use? this is where other terminal emulators come into play!
- How to Make Command Prompt Appear at Schoolthis wikihow teaches you how to access command prompt on a windows 10 school computer. although you may be able to open command prompt if only the file path to command prompt is blocked, there is no way to bypass an administrator lock on...
- Instructions to enable Hey Copilot command Windows 11on windows 11, you can invoke the copilot chatbot with the hey, copilot voice command to communicate with the ai assistant. however, this feature is disabled by default, so users are forced to enable it manually.
- Windows promptthe prompt command changes the command prompt cmd.exe file.
- Use Windows Defender with Command Prompt on Windows 10windows defender is a free antivirus software that microsoft has created to combat malware on computers. this security software is integrated on windows 10 and windows 8.1. windows defender will find and remove viruses, spyware, rootkits and bootkits and some other malicious code on your computer.
- How to Create a Custom Windows Command Promptthe windows command prompt (located at c:windowssystem32cmd.exe) is a useful tool to perform various administrative tasks. the prompt is a string of characters (special and non special) that are displayed whenever the command prompt is...
- What is a firewall? General knowledge about Firewallwhat is a firewall or what is a firewall? how does the firewall work? is it safe to use only the built-in firewall? you will get answers to all the firewall issues in this article.