Open a port windows: How To Open Firewall Ports In Windows 10

How to open ports in Windows Firewall

When dealing with certain apps and processes on your Windows 10 PC, you might run issues if you aren’t connecting properly to the internet. If you’ve come across a potential fix that involves opening a certain port in your firewall, you might be wondering what exactly that process entails. This is a problem that can arise in plenty of situations, but especially when attempting to set up a VPN. If you suspect Windows Firewall is part of your connectivity issue, here’s how to open ports.

How to open a port for incoming traffic in Windows Firewall

Windows Firewall is designed as a security measure for your PC. To put it simply, a firewall analyzes incoming and outgoing connections to determine whether or not they’re threats. If you suspect that your Windows Firewall is causing connectivity issues, you can open a port for incoming traffic. Here’s how:

  1. Right-click the Start button.
  2. Click Search.
  3. Type Windows Firewall.
  1. Click Windows Firewall.
  2. Click Advanced settings.
  1. Click Inbound Rules in the left frame of the window.
  2. Click New Rule… in the right frame of the window.
  1. Click Port.
  2. Click Next.
  1. Click either TCP or UDP.
  2. Click Specific local ports.
  1. Type a port number. (In this case, we will open port 1707.)
  2. Click Next.
  1. Click Allow the connection.
  2. Click Next.
  1. Click any network types you’d like to allow the connection over.
  2. Click Next.
  1. Type a name for the rule.
  2. Click Finish.

How to open a port for outgoing traffic in Windows Firewall

The same set of steps listed above can be used to create a rule for outgoing traffic. In step No. 6, instead of clicking Inbound Rules, you’ll want to click Outgoing Rules. The rest of the steps are the same, and you can disable the rule in the same manner by using the steps in the next section.

How to close a port in Windows Firewall

Want to disable the rule you created to open a port in the Windows Firewall? Here’s how:

  1. Right-click the Start button.
  2. Click Search.
  1. Type Windows Firewall.
  2. Click Windows Firewall.
  1. Click Advanced settings.
  2. Click Inbound Rules or Outbound Rules in the left frame of the window, depending on what type of rule you created.
  1. Click the rule you created.
  2. Click the name of the rule in the right frame of the window.
  1. Click Disable Rule.
  2. Click Delete if you want to completely delete the rule.

More resources

Need a bit more help with Windows Firewall and Windows 10? We have plenty of resources covering a wide range of topics.

  • How to troubleshoot and fix Windows Firewall problems
  • What you need to know about the new Windows Defender Security Center in the Creators Update
  • Windows 10 help, tips, and tricks

Get the best of Windows Central in in your inbox, every day!

Contact me with news and offers from other Future brandsReceive email from us on behalf of our trusted partners or sponsors

Cale Hunt is formerly a Senior Editor at Windows Central. He focuses mainly on laptop reviews, news, and accessory coverage. He’s been reviewing laptops and accessories full-time since 2016, with hundreds of reviews published for Windows Central. He is an avid PC gamer and multi-platform user, and spends most of his time either tinkering with or writing about tech.

How to Open a Port in the Windows 7 Firewall

By: Woody Leonhard and

Updated: 08-02-2022

From The Book: Windows 7 All-in-One For Dummies

Windows 7 All-in-One For Dummies

Explore Book Buy On Amazon

When you use a firewall — and you should — you change the way your computer communicates with other computers on the Internet. The firewall blocks all incoming communications unless you open a port in the Windows firewall to let a specific IP communicate with your computer. For example, if you want to play many online games.

Most first-time firewallers are overwhelmed by the idea of opening a port. Although open ports are a security threat, sometimes you truly need to open one. Still, you may need to open a port to enable a specific application. For example, when you select the check box to allow Remote Desktop, you’re opening port 3389. That’s the security price you pay for enabling programs to talk to each other.In general, if you need to open a specific port, the documentation for the program (game, torrent downloader, file sharer) will tell you . . . assuming you read the program’s manual.

Choose Start→Control Panel. Click the System and Security link and then click Windows Firewall.

You see the main Windows Firewall control window.

On the left, click the Advanced Settings link.

You see the Windows Firewall sanctum sanctorum.

On the left, click Inbound Rules.

Then, on the right, under Actions, click the New Rule link.

Windows Firewall shows you the New Inbound Rule Wizard.

Select the option marked Port and click Next.

The wizard asks you to specify which ports.

In the Specific Local Ports box, type the ports you want to open, separated by commas, and then click Next.

For example, in this case, the TCP ports that need to be opened are 418, 419, 420, and 421. The wizard takes action and opens those ports to receive data.

Choose Allow the Connection and click Next.

The New Inbound Rule Wizard wants to know whether it should apply this rule if you’re connected to a domain network, a private network, or a public network. The safest option is to make it only open on your home network.

Check the boxes for Private or any other desired network type, and then click Next.

The wizard asks that you give the rule a name and, optionally, a description.

Type a name (usually the name of whatever program required the opening). Click Finish.

Your new rule appears in the Inbound Rules list. It takes effect immediately.

About This Article

This article is from the book:

  • Windows 7 All-in-One For Dummies ,

About the book author:

Woody Leonhard describes himself as a «Windows victim.» Since 1992, he’s been sharing the solutions to his own tech problems with millions of readers. In addition to writing several books in the For Dummies series, Woody is a Contributing Editor for Windows Secrets newsletter. He also runs his own blog at

This article can be found in the category:

  • Windows 10 ,

Opening a port in Windows Firewall



Windows/Linux virtual server

In this article I will talk about such a thing as opening ports in Windows Server 2012 R2 . This instruction is relevant only for a regular firewall. Most of the time it’s enough.

These actions are relevant only if the «Virtual Server» service is ordered. By default, all ports are open on it. To set up a firewall on Linux, use ISP Manager Lite. nine0003

For the VDC service, it is better to use the Firewall feature available in vCloud Director, as well as NAT.

The process of opening ports

To do this, perform the following sequence of steps:

  1. Open the start menu and click on the Control Panel square;
  2. Select the «Large icons» view option to make it easier to get to the desired menu;
  3. Open Windows Firewall and then Advanced Options;
  1. The Windows Firewall with Advanced Security window should open. In this window, select «Rules for incoming connections» in the list on the left.
  1. Then, in the list on the right, click on Create Rule to open the New Inbound Rule Wizard.
  2. In the first step, this wizard will ask you what type of rule you want to create. Select «For Port» and click the «Next» button.
  1. At the «Protocol and Pots» step, the wizard will ask you for the number of the port you want to open or a range of these ports. You must enter the port number in the «Defined local ports» field. If you need to open more than one port, then specify their range using a hyphen, for example, «27015-27019». If you need not a range of ports, but several different ones, then put a comma instead of a hyphen, for example: «80.443». After that, click the «Next» button.
  1. In the next step, you will be asked for an action to be taken for this port. Since you are opening a port, make sure that «Allow the connection» is selected, then click «Next».
  1. Next, you will be able to select a profile. If you do not quite understand what it is, then leave all 3 items checked.
  1. Then enter a name for the rule you are creating, such that it makes it clear what it was created for. Click the «Finish» button, after which you will see the newly created rule should be at the very top of the list. nine0024
  1. To edit a rule, select it in the list, and then click on the «Properties» item on the right.


If you have installed another program that performs the functions of a firewall, then configure the opening of ports in it, according to the instructions attached to it. Some antiviruses can also act as a firewall.

If the firewall is installed separately, then the settings for opening ports must be made in it. nine0003

You can check the result on this site, as well as by accessing the port that you opened from your computer. To do this, use the Nmap program. Installer for Windows.

These steps make sense if you plan to enable the firewall afterwards and use it as a server security system.

How to open ports on Windows 10

For some network applications, online games and applications to work, you need to open a port in the Windows 10 firewall settings. , but for some reason they completely forget about the computer security system. There are two ways to open ports in Windows 10 — we will look at each of them. nine0003

How to add a port in Windows Firewall

The easiest way for most users to set up port forwarding is through the Windows GUI. Press the key combination Win + R and enter the command firewall.cpl . Press the key Enter .

After that, the «Windows Defender Firewall» window should open:

In the menu on the left, find the item «Advanced options» and click on it with the left mouse button. After that, the following firewall monitor window should appear:

In order to open a port in Windows, you need to select the «Rules for incoming connections» section in the left part of the window, then the «Create rule» item in the menu on the right. Thus, you will launch the Rule Creation Wizard for a new incoming connection:

The first step is to select the creation of the rule For port . Click on «Next».

The second step is to select the protocol for which we want to open the port in the Windows firewall — TCP or UDP. Below, check the box «Specific local ports» and enter the port number in the field. In my example, this is 12345. You enter your number here — port 80, 443, 8080, 25565, 27015 or any other that you need to open. Let’s move on. nine0003

The third step is to specify the action. In our case, it is «Allow connection».

The fourth step is to select networks for which the created port forwarding rule will apply. Leave all three checkboxes checked — Domain, Private and Public. Let’s move on.

At the final step, we only have to enter a name for the rule and click on the button Done . With this name, the new rule will appear in the general list located in the center of the window. nine0003

Now you can check the availability of an open port from the outside. For these purposes, the 2ip Internet service is perfect.

The only note is that during the check you must be running the application, game or server for which you wanted to open a port in Windows. Otherwise, the check will always fail, because when accessed from an external network, a connection to this port cannot be established, even if it is opened in the firewall. nine0003

How to open the port through the command line

For more advanced users and system administrators, there is a second way that allows you to open the port through the Windows 10 command line. The procedure is as follows:

First, run the command line with Administrator rights: To do this, you need to right-click on the Start button and select Command Prompt (Administrator) . If you are using an extended version of the command line, then select Windows PowerShell (Administrator).