Skip to content

Tutorials Troubleshooting & errors Beginner1 min read

How to Fix ERR_CONNECTION_REFUSED

The server actively refused the connection. Check whether the web server is running, the right ports are open, and the domain points to the right IP.

By ZSOLNET Editorial Team Updated

Key takeaways

  • Refused means the IP was reached but nothing accepted the connection.
  • Check the A record points to the current server, especially after a migration.
  • On a VPS, confirm the web server is running and ports 80/443 are open.

ERR_CONNECTION_REFUSED means the browser found an IP address for the site and contacted it, but nothing on that machine accepted the connection on the web port (80 for HTTP, 443 for HTTPS).

Quick checks

  1. Does the domain point to the right server? Look up the A record and compare it with the IP in your hosting account. Old records after a migration send visitors to a server that no longer hosts the site.
  2. Is it only HTTPS? If http:// works but https:// is refused, the server may not be listening on port 443 — no SSL is configured for the site.
  3. Is it only you? Try mobile data or a website status checker. A refused connection only for you can mean your IP was blocked by the server’s firewall after repeated failed logins.

On a VPS

Check the web server is running and listening:

sudo systemctl status nginx      # or apache2 / httpd
sudo ss -tlnp | grep -E ':80|:443'

Then check the firewall allows web traffic:

sudo ufw status
sudo ufw allow 'Nginx Full'

Also check any cloud firewall or security group in your provider’s control panel.

On shared hosting

If the site is refused for everyone, contact support — the web service or your account may be suspended. If it’s refused only for you, send support your public IP address so they can check whether it’s blocked.

Share X LinkedIn Facebook

Log in to your account

Manage your domains, hosting and invoices in one place.

Secure connection straight to the ZSOLNET client area.

No account yet?