Port 445, commonly used by the Server Message Block (SMB) protocol, facilitates network file sharing and access between devices. While convenient, port 445 can expose networks to cybersecurity threats, including ransomware and unauthorized access. Disabling this port can significantly enhance your network’s security, especially if file sharing between devices is not required. Here’s a step-by-step guide on how to disable port 445 on your Windows network. Moreover, we also give alternatives for your consideration to enhance network security.

Steps to Disable Port 445 for Improved Security
Follow these methods to effectively disable port 445 and protect your network.
Disable SMBv1 to Reduce Security Risks
SMBv1 is an outdated version of the SMB protocol and a known vulnerability exploited in several high-profile cyberattacks. Disabling SMBv1 reduces the risk of these exploits. To disable SMBv1 on Windows, follow these steps:
- Open Control Panel and go to Programs.
- Select Turn Windows features on or off.
- Scroll down and uncheck SMB 1.0/CIFS File Sharing Support.
- Click OK and restart your computer to apply the changes.
Use Windows Firewall to Block Port 445
Blocking port 445 through the Windows Firewall is an effective way to prevent external connections from accessing this port. Here’s how to configure your firewall settings:
- Open Windows Defender Firewall with Advanced Security.
- Click on Inbound Rules and then New Rule.
- Select Port and click Next.
- Choose TCP and specify 445 as the port to block.
- Select Block the Connection and apply the rule to all network profiles.
- Name the rule (e.g., “Block Port 445”) and save it.
Disable Port 445 Using Registry Editor
Advanced users can disable port 445 by modifying the Windows registry. This method provides a more permanent solution but requires caution, as incorrect changes to the registry can impact system functionality. Follow these steps:
- Press Win + R, type regedit, and hit Enter to open the Registry Editor.
- Navigate to: HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\NetBT\Parameters.
- Locate the value named SMBDeviceEnabled and set it to 0 to disable SMB services on port 445.
- Close the Registry Editor and restart your computer to apply the change.

Disable SMB Direct on Windows Features
For additional security, you can disable SMB Direct under Windows Features. This feature enhances SMB communication but can expose your network to security risks. Here’s how to disable it:
- Go to Control Panel and select Programs.
- Click Turn Windows features on or off.
- Find and uncheck SMB Direct.
- Click OK and restart your computer to save changes.
This step closes another avenue for port 445 access, adding a layer of protection to your network.
Test Your Configuration to Confirm Port 445 is Disabled
After disabling port 445, it’s essential to verify the configuration to ensure the port is no longer active. You can use the Command Prompt or third-party tools to check for open ports:
- Open Command Prompt as an administrator.
- Type netstat -an | find “445” and press Enter.
- If no results appear, port 445 is successfully disabled.
Regularly testing your configuration can help you identify any unexpected activity, keeping your network secure.
Consider Alternative Secure File-Sharing Methods
Disabling port 445 might restrict SMB-based file sharing, so consider alternative methods if you still need to transfer files within your network. Options such as cloud storage services or FTP/SFTP connections offer secure file-sharing alternatives without relying on SMB, ensuring both functionality and enhanced security.
Conclusion
Disabling the 445 port is a proactive step in protecting your network from cyber threats. By using methods like blocking through Windows Firewall, disabling SMBv1, and configuring registry settings, you can secure this vulnerable port effectively. Confirming your settings and exploring secure file-sharing alternatives can further enhance your network’s safety, reducing the risk of unauthorized access and ensuring a secure environment for your business or personal data.
Leave a Reply