A firewall can help prevent hackers or malicious software (such as worms) from gaining access to your computer through a network or the Internet. A firewall can also help stop your computer from sending malicious software to other computers.
Allow a program to communicate through Windows Firewall
Turn Windows Firewall on or off
Understanding Windows Firewall settings
Open a port in Windows Firewall