Would you like to learn how to configure the Windows firewall to log blocked packets? In this tutorial, we are going to show you how to enable the packet logging feature of the Windows firewall.

• Windows 2012 R2
• Windows 2016
• Windows 2019
• Windows 10
• Windows 7

Tutorial Windows firewall - Packet logging

Open the application named Windows Firewall with Advanced Security

Windows firewall with Advanced security

Access the properties of the Windows firewall.

Windows firewall properties

On the top of the firewall properties screen, we have 3 firewall profiles.

• Domain profile
• Private profile
• Public profile

Select the desired firewall profile tab.

Windows firewall logging

Locate the Logging area and click on the Customize button.

On the Logging settings screen, you need to select the desired configuration.

Windows firewall log

To log packets dropped by the firewall, select the option YES on the first box.

To log successful connections, select the option YES on the second box.

Optionally, you may also specify the Log file location.

The default Log file location is listed below.

Copy to Clipboard

As an example, here is the file content.

Windows - Firewall logging

Congratulations! You have configured the Windows firewall to log blocked connections.