Quickly Turn ON/OFF Windows Firewall Using Command Line

6 Apr

Quickly Turn ON/OFF Windows Firewall Using Command Line

by 

This article explains how you can quickly Turn Windows Firewall On or Off. This tips applies to Windows Vista, Windows 7 and Windows Server 2008 only!

Windows Firewall on computers running Windows Vista, Windows 7 and Windows Server 2008 is enabled by default. You may need turn it off for various reasons.

This is how you do it using a command prompt:

  • To Turn Off:
  • NetSh Advfirewall set allprofiles state off
  • To Turn On:
  • NetSh Advfirewall set allrprofiles state on
  • To check the status of Windows Firewall:
  • Netsh Advfirewall show allprofiles