This article explains what the Firewall blocking connections message means and how to resolve it on Windows, macOS and Linux.
You may see the following message in RealVNC Connect/RealVNC Server:
"A firewall or security policy on this device is blocking remote connections. No one will be able to connect until RealVNC Connect/RealVNC Server is allowed through. Allow RealVNC Connect/RealVNC Server in your firewall or security policy settings."
What this means
When using direct connections, RealVNC Connect/RealVNC Server needs to accept incoming connections so that a RealVNC Viewer can connect to it. This message appears when the operating system's firewall is blocking that inbound traffic. Until the block is removed, no one will be able to connect.
The default port used is 5900 (TCP/UDP). If you have configured a different port, check your deployment settings if 5900 has been changed.
Common causes
- The built in operating system firewall (Windows Defender Firewall, macOS Firewall, or a Linux firewall service) has not been configured to allow the application.
- A corporate security policy, such as a Group Policy Object or an MDM/EDR profile, is enforcing firewall rules that were not updated to include RealVNC.
Resolving the issue on Windows
Click the Resolve button next to the error message in RealVNC Connect/RealVNC Server. If this does not resolve the error:
- Open Windows Security from the Start menu.
- Go to Firewall & network protection.
- Select Allow an app through firewall.
- Click Change settings, then Allow another app.
- Browse to the RealVNC Connect/RealVNC Server installation folder (typically
C:\Program Files\RealVNC) and add the application. - Tick Domain, Private or Public, depending on the networks you need to connect from.
- Click OK and restart RealVNC Connect/RealVNC Server..
If your device is managed by Group Policy or Intune, the firewall rule may need to be added centrally rather than on the device itself. See your organization's IT administrator or the Deploying RealVNC Connect/RealVNC Server for Windows using Microsoft Intune article for guidance on centrally managed deployments.
Resolving the issue on macOS
- Open System Settings.
- Go to Network, then Firewall.
- Click Options (or the info button next to Firewall).
- Click the + button and add RealVNC Connect/RealVNC Server from the Applications folder.
- Set the application to Allow incoming connections.
- Click OK and restart RealVNC Connect/RealVNC Server.
Resolving the issue on Linux
The exact steps depend on which firewall service your distribution uses.
ufw (Ubuntu and similar):
sudo ufw allow 5900/tcp
sudo ufw allow 5900/udp
firewalld (RHEL and Rocky Linux):
sudo firewall-cmd --permanent --add-port=5900/tcp
sudo firewall-cmd --permanent --add-port=5900/udp sudo firewall-cmd --reload
iptables:
sudo iptables -A INPUT -p tcp --dport 5900 -j ACCEPT
sudo iptables -A INPUT -p tcp --dport 5900 -j ACCEPT
Replace 5900 with the port configured for RealVNC Connect/RealVNC Server if it has been changed from the default.
Still need help?
If you have followed the steps above and the message persists, submit a request to our support team with details of your operating system, RealVNC product version, and any security software installed on the device.
Comments
Article is closed for comments.